diff --git a/wrapper/CMakeLists.txt b/wrapper/CMakeLists.txt index 6264f5a27..5f5adf8db 100644 --- a/wrapper/CMakeLists.txt +++ b/wrapper/CMakeLists.txt @@ -247,6 +247,11 @@ message( STATUS "Compiling the python wrappers using a SMALL build." ) set( CMAKE_C_FLAGS ${SIRE_C_FLAGS_SMALL} ) set( CMAKE_CXX_FLAGS ${SIRE_CXX_FLAGS_SMALL} ) +if (SIRE_HAS_CPP_LIB) + message(STATUS "Using libc++ in place of libstdc++") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -stdlib=libc++") +endif() + set( CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} ${SIRE_SHARE_LINK_FLAGS}" ) set( CMAKE_STATIC_LINKER_FLAGS "${CMAKE_STATIC_LINKER_FLAGS} ${SIRE_STATIC_LINK_FLAGS}" ) set( CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} ${SIRE_EXE_LINK_FLAGS}" )