Skip to content

Commit c1e80bd

Browse files
committed
updates
1 parent e716565 commit c1e80bd

File tree

2 files changed

+2
-6
lines changed

2 files changed

+2
-6
lines changed

Sources/SWBCore/SpecImplementations/Tools/LinkerTools.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -368,7 +368,7 @@ public final class LdLinkerSpec : GenericLinkerSpec, SpecIdentifierType, @unchec
368368
&& cbc.producer.platform?.minimumOSForSwiftInTheOS != nil {
369369
// NOTE: For swift.org toolchains, this is fine as `DYLD_LIBRARY_PATH` is used to override these settings.
370370
let swiftABIVersion = await (cbc.producer.swiftCompilerSpec.discoveredCommandLineToolSpecInfo(cbc.producer, cbc.scope, delegate) as? DiscoveredSwiftCompilerToolSpecInfo)?.swiftABIVersion
371-
runpathSearchPaths.insert( swiftABIVersion.flatMap { "/usr/lib/swift-\($0)" } ?? "/usr/lib/swift_static", at: 0)
371+
runpathSearchPaths.insert( swiftABIVersion.flatMap { "/usr/lib/swift-\($0)" } ?? "/usr/lib/swift", at: 0)
372372
// Ensure the linker driver does not insert a duplicate rpath (if linking using swiftc)
373373
suppressDriverStdlibPaths = true
374374
}

Sources/SWBCore/SpecImplementations/Tools/SwiftCompiler.swift

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3062,18 +3062,14 @@ public final class SwiftCompilerSpec : CompilerSpec, SpecIdentifierType, SwiftDi
30623062
if !forTAPI {
30633063
if shouldStaticLinkStdlib {
30643064
// Platform-specific static linking flags
3065-
// args += [["-Xlinker", "$(LD_FORCE_STATIC_LINK_STDLIB)"]]
30663065
if producer.isApplePlatform {
30673066
// Darwin/Apple platforms use force_load_swift_libs and Framework linking
30683067
args += [["-Xlinker", "-force_load_swift_libs"]]
30693068
args += [["-lc++", "-framework", "Foundation"]]
30703069
} else {
30713070
// Non-Apple platforms (Linux, etc.) use static library linking
3072-
// args += [["-lc++", "-framework", "Foundation"]]
3073-
// args += [["-lc++"]]
3074-
args += [["-static-stdlib"]]
3075-
// args += [["-Xlinker", "-no-pie"]]
30763071
// Note: Foundation is not available as a framework on non-Apple platforms
3072+
args += [["-static-stdlib", ]]
30773073
}
30783074
}
30793075

0 commit comments

Comments
 (0)