1
当我创建一个项目,我CMakeLists.txt
文件看起来像这样:更改由KDevelop创建的默认CMakeLists.txt?
cmake_minimum_required(VERSION 2.6)
project(testttt)
add_executable(testttt main.cpp)
install(TARGETS testttt RUNTIME DESTINATION bin)
但我希望它看起来像这样:
cmake_minimum_required(VERSION 2.6)
project(testttt)
add_executable(testttt main.cpp)
install(TARGETS testttt RUNTIME DESTINATION bin)
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
让我有C++ 11的默认支持。我该怎么做?