Skip to content

Commit

Permalink
Move setting CMAKE_OSX_SYSROOT line
Browse files Browse the repository at this point in the history
  • Loading branch information
kateinoigakukun committed Oct 15, 2019
1 parent 023e952 commit 00801dd
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions stdlib/public/runtime/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -197,15 +197,15 @@ add_swift_target_library(swiftImageRegistrationObjectCOFF
TARGET_SDKS ${COFF_SDKS}
INSTALL_IN_COMPONENT none)

if(WASM IN_LIST SWIFT_CONFIGURED_SDKS)
set(CMAKE_OSX_SYSROOT "${SWIFT_WASM_WASI_SDK_PATH}")
endif()

foreach(sdk ${SWIFT_CONFIGURED_SDKS})
foreach(arch ${SWIFT_SDK_${sdk}_ARCHITECTURES})
set(arch_subdir "${SWIFT_SDK_${sdk}_LIB_SUBDIR}/${arch}")
set(arch_suffix "${SWIFT_SDK_${sdk}_LIB_SUBDIR}-${arch}")

if(sdk STREQUAL WASM)
set(CMAKE_OSX_SYSROOT "${SWIFT_WASM_WASI_SDK_PATH}")
endif()

if("${SWIFT_SDK_${sdk}_OBJECT_FORMAT}" STREQUAL "ELF" OR
"${SWIFT_SDK_${sdk}_OBJECT_FORMAT}" STREQUAL "COFF")
# TODO(compnerd) switch to the generator expression when cmake is upgraded
Expand Down

0 comments on commit 00801dd

Please sign in to comment.