diff options
author | Gregor Jasny <gjasny@googlemail.com> | 2018-01-15 21:21:10 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2019-02-04 14:03:35 (GMT) |
commit | 11da882a1293b39ddd054342b1e6f2f3bd1bc934 (patch) | |
tree | 187dc31245841919d54a28a566b5e0e8550c6980 /Modules/Platform/Darwin.cmake | |
parent | 36cf44a7a3a8931c97790db6df61439d4dd86ea3 (diff) | |
download | CMake-11da882a1293b39ddd054342b1e6f2f3bd1bc934.zip CMake-11da882a1293b39ddd054342b1e6f2f3bd1bc934.tar.gz CMake-11da882a1293b39ddd054342b1e6f2f3bd1bc934.tar.bz2 |
Apple: Introduce separate system name for iOS, tvOS, and watchOS
- Remove code signing requirements for non-macOS
- Do not set deployment target for non-macOS
- Build static library for compiler feature detection for non-macOS
- Use framework to run CompilerId tests for watchOS
- Port tests to new SDK handling
- Add new Apple cross-compiling section to toolchain documentation
Closes: #17870
Diffstat (limited to 'Modules/Platform/Darwin.cmake')
-rw-r--r-- | Modules/Platform/Darwin.cmake | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Modules/Platform/Darwin.cmake b/Modules/Platform/Darwin.cmake index 727baa6..a73ffba 100644 --- a/Modules/Platform/Darwin.cmake +++ b/Modules/Platform/Darwin.cmake @@ -1,5 +1,13 @@ set(APPLE 1) +if(CMAKE_SYSTEM_NAME STREQUAL "iOS" OR CMAKE_SYSTEM_NAME STREQUAL "tvOS" OR CMAKE_SYSTEM_NAME STREQUAL "watchOS") + set(CMAKE_MACOSX_BUNDLE ON) + + set(CMAKE_FIND_ROOT_PATH "${_CMAKE_OSX_SYSROOT_PATH}") + set(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY) + set(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY) +endif() + # Darwin versions: # 6.x == Mac OSX 10.2 (Jaguar) # 7.x == Mac OSX 10.3 (Panther) |