Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions lib/Driver/UnixToolChains.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -168,11 +168,11 @@ toolchains::GenericUnix::constructInvocation(const DynamicLinkJobAction &job,

// Select the linker to use.
std::string Linker;
if (const Arg *A = context.Args.getLastArg(options::OPT_use_ld)) {
Linker = A->getValue();
} else if (context.OI.LTOVariant != OutputInfo::LTOKind::None) {
if (context.OI.LTOVariant != OutputInfo::LTOKind::None) {
// Force to use lld for LTO
Linker = "lld";
} else if (const Arg *A = context.Args.getLastArg(options::OPT_use_ld)) {
Linker = A->getValue();
} else {
Linker = getDefaultLinker();
}
Expand Down