From 409e622196f84b8704d0d1265a16987d773cce90 Mon Sep 17 00:00:00 2001 From: Saleem Abdulrasool Date: Fri, 8 Sep 2023 16:06:07 -0700 Subject: [PATCH] build: copy the import libraries to the correct location This fixes the test suite when performing a clean build. The libraries were being copied to the wrong location after the generalisation changes made earlier. --- lib/CMakeLists.txt | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt index 8853e61dae54b..7a6f55c80406f 100644 --- a/lib/CMakeLists.txt +++ b/lib/CMakeLists.txt @@ -98,13 +98,13 @@ if (SWIFT_SWIFT_PARSER) if(CMAKE_SYSTEM_NAME MATCHES Windows) foreach(implib ${SWIFT_SYNTAX_IMPORT_LIBRARIES}) - add_custom_command(OUTPUT ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/lib/swift/windows/${implib} + add_custom_command(OUTPUT ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/swift/windows/${SWIFT_HOST_VARIANT_ARCH}/${implib} DEPENDS ${SWIFT_PATH_TO_EARLYSWIFTSYNTAX_BUILD_DIR}/lib/swift/host/${implib} - COMMAND "${CMAKE_COMMAND}" -E copy_if_different ${SWIFT_PATH_TO_EARLYSWIFTSYNTAX_BUILD_DIR}/lib/swift/host/${implib} ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/lib/swift/windows/${implib}) + COMMAND "${CMAKE_COMMAND}" -E copy_if_different ${SWIFT_PATH_TO_EARLYSWIFTSYNTAX_BUILD_DIR}/lib/swift/host/${implib} ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/swift/windows/${SWIFT_HOST_VARIANT_ARCH}/${implib}) add_custom_target(copy_swiftSyntaxLibrary_${implib} - DEPENDS ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/lib/swift/windows/${implib} + DEPENDS ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/swift/windows/${SWIFT_HOST_VARIANT_ARCH}/${implib} COMMENT "Copying ${implib}") - swift_install_in_component(PROGRAMS ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/lib/swift/windows/${implib} + swift_install_in_component(PROGRAMS ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/swift/windows/${SWIFT_HOST_VARIANT_ARCH}/${implib} DESTINATION lib COMPONENT compiler) add_dependencies(swiftSyntaxLibraries copy_swiftSyntaxLibrary_${implib})