diff -ru mysql-workbench-community-6.3.4-src/CMakeLists.txt mysql-workbench-community-6.3.4-orig/CMakeLists.txt --- mysql-workbench-community-6.3.4-src/CMakeLists.txt 2015-06-08 04:30:54.000000000 -0700 +++ mysql-workbench-community-6.3.4-orig/CMakeLists.txt 2015-10-20 20:32:03.081595784 -0700 @@ -18,6 +18,16 @@ string(STRIP ${WB_RELEASE_VERSION} WB_RELEASE_VERSION) string(STRIP ${WB_VERSION} WB_VERSION) +include(CheckCXXCompilerFlag) +CHECK_CXX_COMPILER_FLAG("-std=c++11" COMPILER_SUPPORTS_CXX11) +CHECK_CXX_COMPILER_FLAG("-std=c++0x" COMPILER_SUPPORTS_CXX0X) +if(COMPILER_SUPPORTS_CXX11) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") +elseif(COMPILER_SUPPORTS_CXX0X) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++0x") +else() + message(STATUS "The compiler ${CMAKE_CXX_COMPILER} has no C++11 support. Please use a different C++ compiler.") +endif() # About MySQL and CMake # http://dev.mysql.com/doc/internals/en/autotools-to-cmake.html