Skip to content

Commit b18e1fe

Browse files
committed
[6.0] Remove duplicate call to install() for stdlib modules
Also amend the installation code handling macCatalyst to match the one for regular swiftmodules. (cherry picked from commit 649618d)
1 parent 7d89bbf commit b18e1fe

File tree

1 file changed

+2
-17
lines changed

1 file changed

+2
-17
lines changed

stdlib/cmake/modules/SwiftSource.cmake

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -721,22 +721,6 @@ function(_compile_swift_files
721721
list(APPEND module_outputs "${interface_file}" "${private_interface_file}")
722722
endif()
723723

724-
set(optional_arg)
725-
if(SWIFTFILE_SDK IN_LIST SWIFT_DARWIN_PLATFORMS OR
726-
SWIFTFILE_SDK STREQUAL "MACCATALYST")
727-
# Allow installation of stdlib without building all variants on Darwin.
728-
set(optional_arg "OPTIONAL")
729-
endif()
730-
731-
swift_install_in_component(DIRECTORY "${specific_module_dir}"
732-
DESTINATION "lib${LLVM_LIBDIR_SUFFIX}/swift/${library_subdir}"
733-
COMPONENT "${SWIFTFILE_INSTALL_IN_COMPONENT}")
734-
if(SWIFTFILE_STATIC)
735-
swift_install_in_component(DIRECTORY "${specific_module_dir_static}"
736-
DESTINATION "lib${LLVM_LIBDIR_SUFFIX}/swift_static/${library_subdir}"
737-
COMPONENT "${SWIFTFILE_INSTALL_IN_COMPONENT}")
738-
endif()
739-
740724
# macCatalyst zippered module setup
741725
if(maccatalyst_build_flavor STREQUAL "zippered")
742726
compute_library_subdir(maccatalyst_library_subdir
@@ -778,7 +762,8 @@ function(_compile_swift_files
778762
swift_install_in_component(DIRECTORY ${maccatalyst_specific_module_dir}
779763
DESTINATION "lib${LLVM_LIBDIR_SUFFIX}/swift/${maccatalyst_library_subdir}"
780764
COMPONENT "${SWIFTFILE_INSTALL_IN_COMPONENT}"
781-
"${optional_arg}")
765+
PATTERN "Project" EXCLUDE
766+
OPTIONAL)
782767
endif()
783768

784769
# If we have extra regexp flags, check if we match any of the regexps. If so

0 commit comments

Comments
 (0)