summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Dirk Hohndel <dirk@hohndel.org>2016-12-31 21:17:02 -0800
committerGravatar Dirk Hohndel <dirk@hohndel.org>2016-12-31 21:17:02 -0800
commit76dfcdc14c0e3abf540d556ea1cf3b19add66a5f (patch)
treec212ff0ed5e8299e377aec2892134b517477214f
parent004f68083877dc4a49e7322610e08111d6b859b1 (diff)
downloadsubsurface-76dfcdc14c0e3abf540d556ea1cf3b19add66a5f.tar.gz
Mac build: hack to get the correct std C++ lib on Lion
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
-rw-r--r--CMakeLists.txt6
1 files changed, 5 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 991eabaf5..cfeee5b74 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -69,7 +69,11 @@ set(CMAKE_MODULE_PATH
#
if ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99 ")
- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
+ if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin" AND ${CMAKE_SYSTEM_VERSION} MATCHES "11.4.")
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11 -stdlib=libc++")
+ else()
+ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
+ endif()
elseif ("${CMAKE_CXX_COMPILER_ID}" STREQUAL "AppleClang")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99 ")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")