Skip to content

Commit 13468cf

Browse files
authored
Merge pull request #19418 from compnerd/icu-vars
build: use the target variables for the ICU check
2 parents c3f117c + 2f9498a commit 13468cf

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

CMakeLists.txt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -860,15 +860,14 @@ function(swift_icu_variables_set sdk arch result)
860860
endif()
861861
endfunction()
862862

863-
# ICU is provided through CoreFoundation on Darwin. On other hosts, assume that
864-
# we are compiling for the build as the host. In such a case, if the ICU
863+
# ICU is provided through CoreFoundation on Darwin. On other hosts, if the ICU
865864
# unicode and i18n include and library paths are not defined, perform a standard
866865
# package lookup. Otherwise, rely on the paths specified by the user. These
867866
# need to be defined when cross-compiling.
868867
if(NOT CMAKE_SYSTEM_NAME STREQUAL "Darwin")
869868
if(SWIFT_BUILD_STDLIB OR SWIFT_BUILD_SDK_OVERLAY)
870-
swift_icu_variables_set("${SWIFT_HOST_VARIANT_SDK_default}"
871-
"${SWIFT_HOST_VARIANT_ARCH_default}"
869+
swift_icu_variables_set("${SWIFT_PRIMARY_VARIANT_SDK}"
870+
"${SWIFT_PRIMARY_VARIANT_ARCH}"
872871
ICU_CONFIGURED)
873872
if("${SWIFT_PATH_TO_LIBICU_BUILD}" STREQUAL "" AND NOT ${ICU_CONFIGURED})
874873
find_package(ICU REQUIRED COMPONENTS uc i18n)

0 commit comments

Comments
 (0)