Skip to content

Commit 9c71a4a

Browse files
authored
[android] don't enable WMO as the old driver fails to build with WMO … (#851)
* [android] don't enable WMO as the old driver fails to build with WMO on windows * Switch to host system name check
1 parent 2966e02 commit 9c71a4a

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

CMakeLists.txt

+3-2
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,9 @@ if(NOT SWIFT_SYSTEM_NAME)
3535
endif()
3636
endif()
3737

38-
# Don't enable WMO on Windows due to linker failures
39-
if(NOT CMAKE_SYSTEM_NAME STREQUAL Windows)
38+
# Don't enable WMO on Windows hosts due to linker failures, and the use of swift's
39+
# old driver from build.ps1 when building for windows/android on a windows host.
40+
if(NOT CMAKE_HOST_SYSTEM_NAME STREQUAL Windows)
4041
# Enable whole module optimization for release builds & incremental for debug builds
4142
if(POLICY CMP0157)
4243
set(CMAKE_Swift_COMPILATION_MODE "$<IF:$<CONFIG:Release>,wholemodule,incremental>")

0 commit comments

Comments
 (0)