File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed
Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -562,8 +562,13 @@ def add_rpath_for_cmake_build(args, rpath):
562562def get_swift_backdeploy_library_paths (args ):
563563 if platform .system () == 'Darwin' :
564564 # Need to include backwards compatibility libraries for Concurrency
565- # FIXME: Would be nice if we could get this from `swiftc -print-target-info`
566- return ['/usr/lib/swift' , args .target_info ["paths" ]["runtimeLibraryPaths" ][0 ] + '/../../swift-5.5/macosx' ]
565+ if args .release :
566+ # For release builds, we need a relative path that finds the compatibility libs in the current toolchain.
567+ backdeploy_path = '@executable_path/../lib/swift-5.5/macosx'
568+ else :
569+ # FIXME: Would be nice if we could get this from `swiftc -print-target-info`
570+ backdeploy_path = args .target_info ["paths" ]["runtimeLibraryPaths" ][0 ] + '/../../swift-5.5/macosx'
571+ return ['/usr/lib/swift' , backdeploy_path ]
567572 else :
568573 return []
569574
You can’t perform that action at this time.
0 commit comments