fix msys2 build failure in 34e408cc

cmake automatically passes -std=gnu++11 in some cases, while we were
passing -std=c++11, and this was causing incompatibilites in name
mangling between different objects.

Fix this by using -std=gnu++11 for gcc.
This commit is contained in:
Rafael Kitover 2017-01-30 19:12:04 -08:00
parent f21178f6f7
commit cb0bcfae6b
1 changed files with 1 additions and 2 deletions

View File

@ -312,9 +312,8 @@ IF(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
ENDIF()
ENDIF()
# clang doesn't like -std=c++11 for non-C++ sources
IF(CMAKE_COMPILER_IS_GNUCXX)
SET(MY_C_FLAGS ${MY_C_FLAGS} -std=c++11)
SET(MY_C_FLAGS ${MY_C_FLAGS} -std=gnu++11)
ENDIF()
IF(MINGW)