added cmake mode