enable c++11 in cmake and fix stupid error