Files
swift-mirror/include/swift/Runtime/CMakeLists.txt
Mike Ash fbe990481b [Runtime] Dynamically select the is-Swift bit at runtime on Apple platforms.
Recent Swift uses 2 as the is-Swift bit when running on newer versions, and 1 on older versions. Since it's difficult or impossible to know what we'll be running on at build time, make the selection at runtime.
2019-03-07 10:12:27 -05:00

14 lines
371 B
CMake

# Detect B&I builds.
set(SWIFT_BNI_OS_BUILD FALSE)
set(SWIFT_BNI_XCODE_BUILD FALSE)
if(DEFINED ENV{RC_XBS})
if(NOT DEFINED ENV{RC_XCODE} OR NOT "$ENV{RC_XCODE}")
set(SWIFT_BNI_OS_BUILD TRUE)
else()
set(SWIFT_BNI_XCODE_BUILD TRUE)
endif()
endif()
configure_file(CMakeConfig.h.in ${CMAKE_CURRENT_BINARY_DIR}/CMakeConfig.h
ESCAPE_QUOTES @ONLY)