summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2014-05-07 13:13:37 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2014-05-07 13:13:37 (GMT)
commit2e095099ece5bb50a6c8db91f0cb5ac9162f3e8f (patch)
treeee5276eef94495420f68e222d9dfae268f5407ff /Modules
parent3e2e15eead24ae5cdfefff60cdda9d145948718d (diff)
parent1bed75a590707c311de6feddafdfb32cbb9e4afb (diff)
downloadCMake-2e095099ece5bb50a6c8db91f0cb5ac9162f3e8f.zip
CMake-2e095099ece5bb50a6c8db91f0cb5ac9162f3e8f.tar.gz
CMake-2e095099ece5bb50a6c8db91f0cb5ac9162f3e8f.tar.bz2
Merge topic 'osx-iframework'
1bed75a5 OS X: Use -iframework for system framework directories
Diffstat (limited to 'Modules')
-rw-r--r--Modules/Platform/Darwin-Clang.cmake3
-rw-r--r--Modules/Platform/Darwin-GNU.cmake4
2 files changed, 7 insertions, 0 deletions
diff --git a/Modules/Platform/Darwin-Clang.cmake b/Modules/Platform/Darwin-Clang.cmake
index 528873c..4cded47 100644
--- a/Modules/Platform/Darwin-Clang.cmake
+++ b/Modules/Platform/Darwin-Clang.cmake
@@ -24,4 +24,7 @@ macro(__darwin_compiler_clang lang)
set(CMAKE_SHARED_MODULE_CREATE_${lang}_FLAGS "-bundle -Wl,-headerpad_max_install_names")
set(CMAKE_${lang}_SYSROOT_FLAG "-isysroot")
set(CMAKE_${lang}_OSX_DEPLOYMENT_TARGET_FLAG "-mmacosx-version-min=")
+ if(NOT CMAKE_${lang}_COMPILER_VERSION VERSION_LESS 3.1)
+ set(CMAKE_${lang}_SYSTEM_FRAMEWORK_SEARCH_FLAG "-iframework ")
+ endif()
endmacro()
diff --git a/Modules/Platform/Darwin-GNU.cmake b/Modules/Platform/Darwin-GNU.cmake
index 5fee7e3..87d1d23 100644
--- a/Modules/Platform/Darwin-GNU.cmake
+++ b/Modules/Platform/Darwin-GNU.cmake
@@ -23,6 +23,10 @@ macro(__darwin_compiler_gnu lang)
# GNU does not have -shared on OS X
set(CMAKE_SHARED_LIBRARY_CREATE_${lang}_FLAGS "-dynamiclib -Wl,-headerpad_max_install_names")
set(CMAKE_SHARED_MODULE_CREATE_${lang}_FLAGS "-bundle -Wl,-headerpad_max_install_names")
+
+ if(NOT CMAKE_${lang}_COMPILER_VERSION VERSION_LESS 4.3)
+ set(CMAKE_${lang}_SYSTEM_FRAMEWORK_SEARCH_FLAG "-iframework ")
+ endif()
endmacro()
macro(cmake_gnu_set_sysroot_flag lang)