@@ -269,22 +269,23 @@ else()
269269endif ()
270270
271271# Configure 'SwiftCompilerModules' SwiftPM package. The 'Package.swift' will
272- # be created at '${build_dir}/SwiftCompilerSources /Package.swift' and can be
273- # built with 'swift-build'.
272+ # be created at '${build_dir}/SwiftCompilerModulesPackage /Package.swift' and can
273+ # be built with 'swift-build'.
274274# Note that this SwiftPM package itself is just for development purposes, and
275275# is not actually used for the compiler building.
276- set (swiftcompiler_source_dir_name "_Sources" )
276+ set (swiftcompiler_modules_package_directory
277+ "${SWIFT_BINARY_DIR} /SwiftCompilerModulesPackage" )
277278configure_file (Package.swift.in
278- "${CMAKE_CURRENT_BINARY_DIR } /Package.swift" @ONLY)
279+ "${swiftcompiler_modules_package_directory } /Package.swift" @ONLY)
279280# SwiftPM requires all sources are inside the directory of 'Package.swift'.
280281# Create symlinks to the actual source directories.
281282execute_process (COMMAND
282283 "${CMAKE_COMMAND} " -E create_symlink
283284 "${CMAKE_CURRENT_SOURCE_DIR} /Sources"
284- "${CMAKE_CURRENT_BINARY_DIR} / ${swiftcompiler_source_dir_name} " )
285+ "${swiftcompiler_modules_package_directory} /Sources " )
285286if (SWIFT_BUILD_REGEX_PARSER_IN_COMPILER)
286287 execute_process (COMMAND
287288 "${CMAKE_COMMAND} " -E create_symlink
288289 "${EXPERIMENTAL_STRING_PROCESSING_SOURCE_DIR} /Sources/_RegexParser"
289- "${CMAKE_CURRENT_BINARY_DIR } /_RegexParser_Sources" )
290+ "${swiftcompiler_modules_package_directory } /_RegexParser_Sources" )
290291endif ()
0 commit comments