Skip to content

Commit f2710d4

Browse files
committed
lld/mach-o: Infer darwinnew from filename ld64.lld.darwinnew too
`-flavor` is difficult to use through the clang driver since it must be the first argument. clang's `-fuse-ld=foo` looks for `ld64.foo` when targeting darwin, so it's easiest if darwinnew accepts some `ld64.foo`. Let's go with `ld64.lld.darwinnew`, so that `clang -fuse-ld=lld.darwinnew` does the right thing (assuming a symlink with the name `ld64.ld.darwinnew exists in the right place). This is temporary until darwinnew replaces ld64.lld, and it only exists to make testing the new lld port easier.
1 parent 257d33c commit f2710d4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lld/tools/lld/lld.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ static Flavor getFlavor(StringRef s) {
7171
.CasesLower("wasm", "ld-wasm", Wasm)
7272
.CaseLower("link", WinLink)
7373
.CasesLower("ld64", "ld64.lld", "darwin", Darwin)
74-
.CaseLower("darwinnew", DarwinNew)
74+
.CasesLower("darwinnew", "ld64.lld.darwinnew", DarwinNew)
7575
.Default(Invalid);
7676
}
7777

0 commit comments

Comments
 (0)