| author | |
| committer | |
| log | 8db9d04e6f89a17f17e369a1a2582bdb8db50843 |
| tree | a3551c179f7349a9801e77352a5b5ab6eeed143e |
| parent | e332cd65c95472c0e06bfc6a2cccf17c36ee4606 |
LLD treats the first argument as arg[0], the exe name1 files changed, 5 insertions(+), 0 deletions(-)
src/link.cpp+5| ... | ... | @@ -736,6 +736,11 @@ static void construct_linker_job(LinkJob *lj) { |
| 736 | 736 | |
| 737 | 737 | void codegen_link(CodeGen *g, const char *out_file) { |
| 738 | 738 | LinkJob lj = {0}; |
| 739 | ||
| 740 | // even though we're calling LLD as a library it thinks the first | |
| 741 | // argument is its own exe name | |
| 742 | lj.args.append("lld"); | |
| 743 | ||
| 739 | 744 | lj.rpath_table.init(4); |
| 740 | 745 | lj.codegen = g; |
| 741 | 746 | if (out_file) { |