From 93d20668f6b30dac0e70598703e58d600903f333 Mon Sep 17 00:00:00 2001 From: Stanislaw Halik Date: Mon, 22 Sep 2014 10:08:18 +0200 Subject: nix warnings for C translation units --- CMakeLists.txt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 024f67f5..b1bbf4ba 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -37,7 +37,6 @@ if(APPLE) set(CMAKE_STATIC_LINKER_FLAGS " ${apple-frameworks} ${CMAKE_STATIC_LINKER_FLAGS}") set(CMAKE_EXE_LINKER_FLAGS " ${apple-frameworks} ${CMAKE_EXE_LINKER_FLAGS}") set(CMAKE_MODULE_LINKER_FLAGS " ${apple-frameworks} ${CMAKE_MODULE_LINKER_FLAGS}") - set(CMAKE_CXX_FLAGS " -stdlib=libc++ ${CMAKE_CXX_FLAGS} ") endif() SET(CMAKE_BUILD_WITH_INSTALL_RPATH TRUE) @@ -51,8 +50,8 @@ set(CMAKE_POSITION_INDEPENDENT_CODE ON) add_definitions(-DOPENTRACK_API -DIN_OPENTRACK) -if(CMAKE_COMPILER_IS_GNUCXX AND NOT APPLE) - add_definitions(-std=c++11) +if(CMAKE_COMPILER_IS_GNUCXX OR APPLE) + set(CMAKE_CXX_FLAGS " -std=c++11 ${CMAKE_CXX_FLAGS} ") endif() -- cgit v1.2.3