From c8608f268f6461c421055ff3df1fd72d616cb646 Mon Sep 17 00:00:00 2001 From: Alexandru Croitor Date: Wed, 11 May 2016 11:37:16 +0200 Subject: Add option to link with libc++ on older OSX versions. Change-Id: I0e5b0486a03010386195e09702fbff72843ef28e Reviewed-by: Christian Tismer --- CMakeLists.txt | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 2fad8e5..7be3488 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -14,6 +14,13 @@ configure_file("pyside2uic/__init__.py.in" "${CMAKE_CURRENT_BINARY_DIR}/pyside2u option(BUILD_TESTS "Build tests." TRUE) +if(CMAKE_HOST_APPLE) + set(OSX_USE_LIBCPP "OFF" CACHE BOOL "Explicitly link the libc++ standard library (useful for osx deployment targets lower than 10.9.") + if(OSX_USE_LIBCPP) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++") + endif() +endif() + # UIC stuff if (NOT SITE_PACKAGE) execute_process( -- cgit v1.2.3