Reapply r327026 (partially):
Merge lld trunk r321017 to contrib/llvm/tools/lld. (Note that in this merge, I foolishly combined upstream changes with this local change. But only this ifdef part is really needed, as we always default to ELF link mode.)
This commit is contained in:
parent
dd6565b7a6
commit
59948e95d8
@ -142,6 +142,9 @@ int main(int argc, const char **argv) {
|
||||
InitLLVM x(argc, argv);
|
||||
|
||||
std::vector<const char *> args(argv, argv + argc);
|
||||
#ifdef __FreeBSD__
|
||||
return !elf::link(args, canExitEarly(), llvm::outs(), llvm::errs());
|
||||
#else
|
||||
switch (parseFlavor(args)) {
|
||||
case Gnu:
|
||||
if (isPETarget(args))
|
||||
@ -160,4 +163,5 @@ int main(int argc, const char **argv) {
|
||||
"Invoke ld.lld (Unix), ld64.lld (macOS), lld-link (Windows), wasm-ld"
|
||||
" (WebAssembly) instead");
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user