diff --git a/.mailmap b/.mailmap index 796340ab7de..dd56203f7cc 100644 --- a/.mailmap +++ b/.mailmap @@ -105,5 +105,5 @@ Valeriy Van Valeriy Van therealbnut therealbnut <635596+therealbnut@users.noreply.github.com> -buttaface -buttaface +finagolfin +finagolfin diff --git a/Sources/Build/BuildDescription/ProductBuildDescription.swift b/Sources/Build/BuildDescription/ProductBuildDescription.swift index 337bb9bd618..18043eec781 100644 --- a/Sources/Build/BuildDescription/ProductBuildDescription.swift +++ b/Sources/Build/BuildDescription/ProductBuildDescription.swift @@ -321,14 +321,6 @@ public final class ProductBuildDescription: SPMBuildCore.ProductBuildDescription args += ["-L", librarySearchPath.pathString] } - // Add toolchain's libdir at the very end (even after the user -Xlinker arguments). - // - // This will allow linking to libraries shipped in the toolchain. - let toolchainLibDir = try buildParameters.toolchain.toolchainLibDir - if self.fileSystem.isDirectory(toolchainLibDir) { - args += ["-L", toolchainLibDir.pathString] - } - // Library search path for the toolchain's copy of SwiftSyntax. #if BUILD_MACROS_AS_DYLIBS if product.type == .macro { diff --git a/Tests/BuildTests/BuildPlanTests.swift b/Tests/BuildTests/BuildPlanTests.swift index f998a35958d..719b9e543a9 100644 --- a/Tests/BuildTests/BuildPlanTests.swift +++ b/Tests/BuildTests/BuildPlanTests.swift @@ -3409,11 +3409,8 @@ final class BuildPlanTests: XCTestCase { } func testExtraBuildFlags() throws { - let libpath = AbsolutePath("/fake/path/lib") - let fs = InMemoryFileSystem(emptyFiles: "/A/Sources/exe/main.swift", - libpath.appending(components: "libSomething.dylib").pathString, "" ) @@ -3444,7 +3441,7 @@ final class BuildPlanTests: XCTestCase { )) let exe = try result.buildProduct(for: "exe").linkArguments() - XCTAssertMatch(exe, [.anySequence, "-L", "/path/to/foo", "-L/path/to/foo", "-Xlinker", "-rpath=foo", "-Xlinker", "-rpath", "-Xlinker", "foo", "-L", "\(libpath)"]) + XCTAssertMatch(exe, [.anySequence, "-L", "/path/to/foo", "-L/path/to/foo", "-Xlinker", "-rpath=foo", "-Xlinker", "-rpath", "-Xlinker", "foo"]) } func testUserToolchainCompileFlags() throws {