diff --git a/CMakeLists.txt b/CMakeLists.txt index 01fdec934c8..2add6703159 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -149,6 +149,9 @@ if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang") endif() if("${CMAKE_CXX_FLAGS}" STREQUAL "") SET(CMAKE_CXX_FLAGS "-ftemplate-depth=1024 -Qunused-arguments -Wno-invalid-offsetof ${SSE_FLAGS}") # Unfortunately older Clang versions do not have this: -Wno-unnamed-type-template-args + if(APPLE) + SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libstdc++") + endif(APPLE) endif() SET(CLANG_LIBRARIES "stdc++") endif()