mirror of
https://github.com/ziglang/zig.git
synced 2026-02-13 04:48:20 +00:00
link: fix ignoring first linker arg
LLD treats the first argument as arg[0], the exe name
This commit is contained in:
parent
e332cd65c9
commit
8db9d04e6f
@ -736,6 +736,11 @@ static void construct_linker_job(LinkJob *lj) {
|
||||
|
||||
void codegen_link(CodeGen *g, const char *out_file) {
|
||||
LinkJob lj = {0};
|
||||
|
||||
// even though we're calling LLD as a library it thinks the first
|
||||
// argument is its own exe name
|
||||
lj.args.append("lld");
|
||||
|
||||
lj.rpath_table.init(4);
|
||||
lj.codegen = g;
|
||||
if (out_file) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user