diff --git a/CMakeLists.txt b/CMakeLists.txt index 3b90f840..2f0014ca 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -43,14 +43,13 @@ if(WIN32) endif() if(CMAKE_CXX_COMPILER_ID STREQUAL GNU OR CMAKE_CXX_COMPILER_ID STREQUAL Clang) - set(WARNING_FLAGS - -Wunused-variable) - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${WARNING_FLAGS}") - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${WARNING_FLAGS}") + set(WARNING_FLAGS "-Wunused-variable") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${WARNING_FLAGS}") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 ${WARNING_FLAGS}") endif() if(MINGW) - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -static-libgcc") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -static-libgcc") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -static-libgcc -static-libstdc++") endif()