Skip to content

Commit cb41353

Browse files
committed
build: repair the windows cross-compilation
The SIMDOperators module was being added prior to SwiftOnoneSupport, which resulted in the import library target for Windows not being setup prior to use. As a result, we would link against the DLL rather than the import library which is not supported (except as a MinGW hack in the binutils linker). Re-order the registration to ensure that the target is setup already.
1 parent 80699b8 commit cb41353

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

stdlib/public/CMakeLists.txt

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,8 +55,12 @@ if(SWIFT_BUILD_STDLIB)
5555
add_subdirectory(runtime)
5656
add_subdirectory(stubs)
5757
add_subdirectory(core)
58-
add_subdirectory(SIMDOperators)
5958
add_subdirectory(SwiftOnoneSupport)
59+
60+
# NOTE(compnerd) this must come after the SwiftOnoneSupport as the current
61+
# cross-compilation support has to hand roll the import library setup which
62+
# requires that the target is setup prior to use.
63+
add_subdirectory(SIMDOperators)
6064
endif()
6165

6266
if(SWIFT_BUILD_STDLIB OR SWIFT_BUILD_REMOTE_MIRROR)

0 commit comments

Comments
 (0)