swiftlang/swift-build

Allow using swiftc as the Swift Build linker driver

Open

#3 opened on Jan 28, 2025

 (5 comments) (0 reactions) (0 assignees)Swift (184 forks)github user discovery
good first issue

Repository metrics

Stars
 (2,219 stars)
PR merge metrics
 (Avg merge 2d 22h) (59 merged PRs in 30d)

Description

Swift Build currently always uses clang as the linker driver, while SwiftPM has historically used swiftc. We should add a build setting clients can use to opt into using swiftc as the linker driver to ensure consistency where the two drivers have divergent behavior / command line flags. This will likely require some changes throughout the build system where we currently make assumptions about flags the linker driver accepts, and especially how we escape flags to pass them to the underlying linker.

Contributor guide