well as c++0x and c++11. This can be especially useful when building
with GCC in C++11 mode.
llvm-svn: 172897
if ("${CMAKE_CXX_COMPILER_ID}" MATCHES "GNU" OR
"${CMAKE_CXX_COMPILER_ID}" MATCHES "Clang")
if (NOT ("${CMAKE_CXX_FLAGS}" MATCHES "-std=c\\+\\+0x" OR
- "${CMAKE_CXX_FLAGS}" MATCHES "-std=c\\+\\+11"))
+ "${CMAKE_CXX_FLAGS}" MATCHES "-std=gnu\\+\\+0x" OR
+ "${CMAKE_CXX_FLAGS}" MATCHES "-std=c\\+\\+11" OR
+ "${CMAKE_CXX_FLAGS}" MATCHES "-std=gnu\\+\\+11"))
message(FATAL_ERROR
"lld requires c++11. Clang and gcc require -std=c++0x or -std=c++11 to "
"enter this mode. Please set CMAKE_CXX_FLAGS accordingly.")