diff options
| author | Shritesh Bhattarai <shritesh@shritesh.com> | 2019-04-14 00:03:32 -0500 |
|---|---|---|
| committer | Shritesh Bhattarai <shritesh@shritesh.com> | 2019-04-14 00:03:32 -0500 |
| commit | 94e0871603add796e87ac53a3271cf5b9b3d6b0e (patch) | |
| tree | 30bb50f6decfe5ce6cf2c4d41ca8861ee0a686d8 /src/link.cpp | |
| parent | ecd0f8925447074307e8795bb8d6f9f6277a1a26 (diff) | |
| download | zig-94e0871603add796e87ac53a3271cf5b9b3d6b0e.tar.gz zig-94e0871603add796e87ac53a3271cf5b9b3d6b0e.zip | |
wasi: don't pass --no-entry to linker
Diffstat (limited to 'src/link.cpp')
| -rw-r--r-- | src/link.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/link.cpp b/src/link.cpp index 78e549c80b..6c6ff07ba9 100644 --- a/src/link.cpp +++ b/src/link.cpp @@ -1091,7 +1091,9 @@ static void construct_linker_job_wasm(LinkJob *lj) { CodeGen *g = lj->codegen; lj->args.append("-error-limit=0"); - lj->args.append("--no-entry"); // So lld doesn't look for _start. + if (g->zig_target->os != OsWASI) { + lj->args.append("--no-entry"); // So lld doesn't look for _start. + } lj->args.append("--allow-undefined"); lj->args.append("--export-all"); lj->args.append("-o"); |
