Make the simulator compile out of the box. Patch by xingz@andrew.cmu.edu.