We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8b1cfc9 commit 15cd1b2Copy full SHA for 15cd1b2
Sources/SwiftBuildSupport/PackagePIFProjectBuilder+Products.swift
@@ -1022,6 +1022,13 @@ extension PackagePIFProjectBuilder {
1022
// This should eventually be set universally for all package targets/products.
1023
settings[.LINKER_DRIVER] = "swiftc"
1024
1025
+ // A test-runner should always be adjacent to the dynamic library containing the tests,
1026
+ // so add the appropriate rpaths.
1027
+ settings[.LD_RUNPATH_SEARCH_PATHS] = [
1028
+ "$(inherited)",
1029
+ "$(RPATH_ORIGIN)"
1030
+ ]
1031
+
1032
let deploymentTargets = unitTestProduct.deploymentTargets
1033
settings[.MACOSX_DEPLOYMENT_TARGET] = deploymentTargets?[.macOS] ?? nil
1034
settings[.IPHONEOS_DEPLOYMENT_TARGET] = deploymentTargets?[.iOS] ?? nil
0 commit comments