mirror of
https://github.com/ldc-developers/ldc.git
synced 2025-05-05 01:20:51 +03:00
Give user possibility to avoid passing -fuse-ld to cc with --linker=
. (#3382)
This commit is contained in:
parent
336da83945
commit
1aa55f7879
3 changed files with 18 additions and 5 deletions
|
@ -577,7 +577,9 @@ void ArgsBuilder::addLinker() {
|
|||
// Default to ld.gold on Linux due to ld.bfd issues with ThinLTO (see #2278)
|
||||
// and older bfd versions stripping llvm.used symbols (e.g., ModuleInfo
|
||||
// refs) with --gc-sections (see #2870).
|
||||
args.push_back("-fuse-ld=gold");
|
||||
// Can be overridden by `-linker=` (explicitly empty).
|
||||
if (opts::linker.getNumOccurrences() == 0)
|
||||
args.push_back("-fuse-ld=gold");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue