diff options
author | Brad King <brad.king@kitware.com> | 2015-02-24 14:12:45 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2015-02-24 14:12:45 (GMT) |
commit | 41a16f07c3b57e05927ba7706a4e3cebd7768ddf (patch) | |
tree | 821d5deabff95e004b9feccaec12ad49461ab2ac | |
parent | 13f9f848defa75f7d728050b4d99d44b194642b2 (diff) | |
parent | 0ee2a004e70e2d49423f5b4b393896258e8ab688 (diff) | |
download | CMake-41a16f07c3b57e05927ba7706a4e3cebd7768ddf.zip CMake-41a16f07c3b57e05927ba7706a4e3cebd7768ddf.tar.gz CMake-41a16f07c3b57e05927ba7706a4e3cebd7768ddf.tar.bz2 |
Merge topic 'osx-framework-search-platform-SDKs'
0ee2a004 OS X: Add platform-specific Frameworks search path
-rw-r--r-- | Modules/Platform/Darwin.cmake | 7 | ||||
-rw-r--r-- | Tests/RunCMake/CMakeLists.txt | 2 | ||||
-rw-r--r-- | Tests/RunCMake/XcodeProject/RunCMakeTest.cmake | 3 | ||||
-rw-r--r-- | Tests/RunCMake/XcodeProject/XcodePlatformFrameworks.cmake | 6 |
4 files changed, 17 insertions, 1 deletions
diff --git a/Modules/Platform/Darwin.cmake b/Modules/Platform/Darwin.cmake index e5c5f36..b912d98 100644 --- a/Modules/Platform/Darwin.cmake +++ b/Modules/Platform/Darwin.cmake @@ -166,6 +166,13 @@ if(_CMAKE_OSX_SYSROOT_PATH) ${_CMAKE_OSX_SYSROOT_PATH}/Network/Library/Frameworks ${_CMAKE_OSX_SYSROOT_PATH}/System/Library/Frameworks ) + # add platform developer framework path if exists + get_filename_component(_CMAKE_OSX_PLATFORM_FRAMEWORK_PATH + ${_CMAKE_OSX_SYSROOT_PATH}/../../Library/Frameworks ABSOLUTE) + if(IS_DIRECTORY ${_CMAKE_OSX_PLATFORM_FRAMEWORK_PATH}) + list(APPEND CMAKE_SYSTEM_FRAMEWORK_PATH + ${_CMAKE_OSX_PLATFORM_FRAMEWORK_PATH}) + endif() endif() list(APPEND CMAKE_SYSTEM_FRAMEWORK_PATH /Library/Frameworks diff --git a/Tests/RunCMake/CMakeLists.txt b/Tests/RunCMake/CMakeLists.txt index bd5b036..eb42057 100644 --- a/Tests/RunCMake/CMakeLists.txt +++ b/Tests/RunCMake/CMakeLists.txt @@ -184,7 +184,7 @@ if("${CMAKE_GENERATOR}" MATCHES "Visual Studio [^6]") endif() if(XCODE_VERSION AND NOT "${XCODE_VERSION}" VERSION_LESS 3) - add_RunCMake_test(XcodeProject) + add_RunCMake_test(XcodeProject -DXCODE_VERSION=${XCODE_VERSION}) endif() add_RunCMake_test(File_Generate) diff --git a/Tests/RunCMake/XcodeProject/RunCMakeTest.cmake b/Tests/RunCMake/XcodeProject/RunCMakeTest.cmake index 792f40e..03d3cd3 100644 --- a/Tests/RunCMake/XcodeProject/RunCMakeTest.cmake +++ b/Tests/RunCMake/XcodeProject/RunCMakeTest.cmake @@ -3,3 +3,6 @@ include(RunCMake) run_cmake(XcodeFileType) run_cmake(XcodeAttributeGenex) run_cmake(XcodeAttributeGenexError) +if (NOT XCODE_VERSION VERSION_LESS 6) + run_cmake(XcodePlatformFrameworks) +endif() diff --git a/Tests/RunCMake/XcodeProject/XcodePlatformFrameworks.cmake b/Tests/RunCMake/XcodeProject/XcodePlatformFrameworks.cmake new file mode 100644 index 0000000..74dc978 --- /dev/null +++ b/Tests/RunCMake/XcodeProject/XcodePlatformFrameworks.cmake @@ -0,0 +1,6 @@ +enable_language(C) + +find_library(XCTEST_LIBRARY XCTest) +if(NOT XCTEST_LIBRARY) + message(FATAL_ERROR "XCTest Framework not found.") +endif() |