summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Modules/Platform/Darwin-Initialize.cmake6
1 files changed, 2 insertions, 4 deletions
diff --git a/Modules/Platform/Darwin-Initialize.cmake b/Modules/Platform/Darwin-Initialize.cmake
index 39374e1..3606144 100644
--- a/Modules/Platform/Darwin-Initialize.cmake
+++ b/Modules/Platform/Darwin-Initialize.cmake
@@ -125,10 +125,8 @@ if(CMAKE_OSX_SYSROOT)
set(_CMAKE_OSX_SYSROOT_ORIG "")
endif()
set(_CMAKE_OSX_SYSROOT_PATH "${CMAKE_OSX_SYSROOT}")
- endif()
-
- if(CMAKE_OSX_SYSROOT)
- # Transform the (maybe unversioned) sysroot into a versioned path.
+ else()
+ # Transform the sdk name into a path.
execute_process(
COMMAND xcodebuild -sdk ${CMAKE_OSX_SYSROOT} -version Path
OUTPUT_VARIABLE _stdout