Skip to content

Commit 2f500f2

Browse files
authored
Merge pull request #1725 from etcwilde/ewilde/6.0-fix-dashes-in-fuse-ld
[🍒 Swift-6.0.x] fuse-ld only takes one dash
2 parents 1540247 + 7e5de78 commit 2f500f2

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

Sources/SwiftDriver/Jobs/GenericUnixToolchain+LinkerSupport.swift

+2-2
Original file line numberDiff line numberDiff line change
@@ -50,9 +50,9 @@ extension GenericUnixToolchain {
5050
case .executable:
5151
// Select the linker to use.
5252
if let arg = parsedOptions.getLastArgument(.useLd)?.asSingle {
53-
commandLine.appendFlag("--fuse-ld=\(arg)")
53+
commandLine.appendFlag("-fuse-ld=\(arg)")
5454
} else if lto != nil {
55-
commandLine.appendFlag("--fuse-ld=lld")
55+
commandLine.appendFlag("-fuse-ld=lld")
5656
}
5757

5858
if let arg = parsedOptions.getLastArgument(.ldPath)?.asSingle {

Tests/SwiftDriverTests/SwiftDriverTests.swift

+1-1
Original file line numberDiff line numberDiff line change
@@ -2405,7 +2405,7 @@ final class SwiftDriverTests: XCTestCase {
24052405
let plannedJobs = try driver.planBuild().removingAutolinkExtractJobs()
24062406
let lastJob = plannedJobs.last!
24072407
XCTAssertTrue(lastJob.tool.name.contains("clang"))
2408-
XCTAssertTrue(lastJob.commandLine.contains(.flag("--fuse-ld=lld")))
2408+
XCTAssertTrue(lastJob.commandLine.contains(.flag("-fuse-ld=lld")))
24092409
}
24102410
}
24112411

0 commit comments

Comments
 (0)