@@ -835,6 +835,7 @@ class BuildPlanTestCase: BuildSystemProviderTestCase {
835
835
" -Xlinker " , " -rpath " , " -Xlinker " , " @loader_path " ,
836
836
" @ \( buildPath. appending ( components: " exe.product " , " Objects.LinkFileList " ) ) " ,
837
837
" -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-5.5/macosx " ,
838
+ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-6.2/macosx " ,
838
839
" -target " , defaultTargetTriple,
839
840
" -Xlinker " , " -add_ast_path " , " -Xlinker " ,
840
841
buildPath. appending ( components: " Modules " , " lib.swiftmodule " ) . pathString,
@@ -1150,6 +1151,7 @@ class BuildPlanTestCase: BuildSystemProviderTestCase {
1150
1151
" -Xlinker " , " -rpath " , " -Xlinker " , " @loader_path " ,
1151
1152
" @ \( buildPath. appending ( components: " exe.product " , " Objects.LinkFileList " ) ) " ,
1152
1153
" -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-5.5/macosx " ,
1154
+ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-6.2/macosx " ,
1153
1155
" -target " , defaultTargetTriple,
1154
1156
" -g " ,
1155
1157
] )
@@ -1244,6 +1246,7 @@ class BuildPlanTestCase: BuildSystemProviderTestCase {
1244
1246
" -Xlinker " , " -rpath " , " -Xlinker " , " @loader_path " ,
1245
1247
" @ \( buildPath. appending ( components: " exe.product " , " Objects.LinkFileList " ) ) " ,
1246
1248
" -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-5.5/macosx " ,
1249
+ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-6.2/macosx " ,
1247
1250
" -target " , defaultTargetTriple,
1248
1251
" -g " ,
1249
1252
] )
@@ -1794,6 +1797,7 @@ class BuildPlanTestCase: BuildSystemProviderTestCase {
1794
1797
" -Xlinker " , " -rpath " , " -Xlinker " , " @loader_path " ,
1795
1798
" @ \( buildPath. appending ( components: " exe.product " , " Objects.LinkFileList " ) ) " ,
1796
1799
" -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-5.5/macosx " ,
1800
+ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-6.2/macosx " ,
1797
1801
" -target " , defaultTargetTriple,
1798
1802
" -Xlinker " , " -add_ast_path " , " -Xlinker " , " /path/to/build/ \( result. plan. destinationBuildParameters. triple) /debug/exe.build/exe.swiftmodule " ,
1799
1803
" -g " ,
@@ -2353,11 +2357,12 @@ class BuildPlanTestCase: BuildSystemProviderTestCase {
2353
2357
2354
2358
#if os(macOS)
2355
2359
let version = MinimumDeploymentTarget . computeXCTestMinimumDeploymentTarget ( for: . macOS) . versionString
2356
- let rpathsForBackdeployment : [ String ]
2360
+ var rpathsForBackdeployment : [ String ] = [ ]
2357
2361
if let version = try ? Version ( string: version, lenient: true ) , version. major < 12 {
2358
- rpathsForBackdeployment = [ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-5.5/macosx " ]
2359
- } else {
2360
- rpathsForBackdeployment = [ ]
2362
+ rpathsForBackdeployment += [ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-5.5/macosx " ]
2363
+ }
2364
+ if let version = try ? Version ( string: version, lenient: true ) , version. major < 26 {
2365
+ rpathsForBackdeployment += [ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-6.2/macosx " ]
2361
2366
}
2362
2367
XCTAssertEqual (
2363
2368
try result. buildProduct ( for: " PkgPackageTests " ) . linkArguments ( ) ,
@@ -2475,6 +2480,7 @@ class BuildPlanTestCase: BuildSystemProviderTestCase {
2475
2480
" -Xlinker " , " -dead_strip " ,
2476
2481
" -Xlinker " , " -rpath " , " -Xlinker " , " @loader_path " ,
2477
2482
" @ \( buildPath. appending ( components: " exe.product " , " Objects.LinkFileList " ) ) " ,
2483
+ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-6.2/macosx " ,
2478
2484
" -target " , hostTriple. tripleString ( forPlatformVersion: " 12.0 " ) ,
2479
2485
" -g " ,
2480
2486
] )
@@ -2846,6 +2852,7 @@ class BuildPlanTestCase: BuildSystemProviderTestCase {
2846
2852
" -Xlinker " , " -rpath " , " -Xlinker " , " @loader_path " ,
2847
2853
" @ \( buildPath. appending ( components: " exe.product " , " Objects.LinkFileList " ) ) " ,
2848
2854
" -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-5.5/macosx " ,
2855
+ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-6.2/macosx " ,
2849
2856
" -target " , defaultTargetTriple,
2850
2857
" -Xlinker " , " -add_ast_path " ,
2851
2858
" -Xlinker " , buildPath. appending ( components: " exe.build " , " exe.swiftmodule " ) . pathString,
@@ -2992,6 +2999,7 @@ class BuildPlanTestCase: BuildSystemProviderTestCase {
2992
2999
" -Xlinker " , " -rpath " , " -Xlinker " , " @loader_path " ,
2993
3000
" @ \( buildPath. appending ( components: " Foo.product " , " Objects.LinkFileList " ) ) " ,
2994
3001
" -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-5.5/macosx " ,
3002
+ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-6.2/macosx " ,
2995
3003
" -target " , defaultTargetTriple,
2996
3004
" -Xlinker " , " -add_ast_path " ,
2997
3005
" -Xlinker " , buildPath. appending ( components: " Foo.build " , " Foo.swiftmodule " ) . pathString,
@@ -3009,6 +3017,7 @@ class BuildPlanTestCase: BuildSystemProviderTestCase {
3009
3017
" -Xlinker " , " -rpath " , " -Xlinker " , " @loader_path " ,
3010
3018
" @ \( buildPath. appending ( components: " Bar-Baz.product " , " Objects.LinkFileList " ) ) " ,
3011
3019
" -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-5.5/macosx " ,
3020
+ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-6.2/macosx " ,
3012
3021
" -target " , defaultTargetTriple,
3013
3022
" -Xlinker " , " -add_ast_path " ,
3014
3023
" -Xlinker " , buildPath. appending ( components: " Modules " , " Bar.swiftmodule " ) . pathString,
@@ -3165,6 +3174,7 @@ class BuildPlanTestCase: BuildSystemProviderTestCase {
3165
3174
" -Xlinker " , " -rpath " , " -Xlinker " , " @loader_path " ,
3166
3175
" @ \( buildPath. appending ( components: " lib.product " , " Objects.LinkFileList " ) ) " ,
3167
3176
" -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-5.5/macosx " ,
3177
+ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-6.2/macosx " ,
3168
3178
" -target " , defaultTargetTriple,
3169
3179
" -Xlinker " , " -add_ast_path " , " -Xlinker " ,
3170
3180
buildPath. appending ( components: " Modules " , " lib.swiftmodule " ) . pathString,
@@ -7295,6 +7305,7 @@ class BuildPlanTestCase: BuildSystemProviderTestCase {
7295
7305
" -emit-executable " ,
7296
7306
" @ \( buildPath. appending ( components: " exe.product " , " Objects.LinkFileList " ) ) " ,
7297
7307
" -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-5.5/macosx " ,
7308
+ " -Xlinker " , " -rpath " , " -Xlinker " , " /fake/path/lib/swift-6.2/macosx " ,
7298
7309
" -target " , defaultTargetTriple,
7299
7310
" -Xlinker " , " -add_ast_path " ,
7300
7311
" -Xlinker " , buildPath. appending ( components: " Modules " , " lib.swiftmodule " ) . pathString,
0 commit comments