authorgravatar for shritesh@shritesh.comShritesh Bhattarai <shritesh@shritesh.com> 2019-04-10 17:14:44-05:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2019-04-10 19:14:19-04:00
log666e8799251452f74ca97b4a6a930c7b3d0ce553
treed045a4dbffe6748b23651568eb4efd450fd4e987
parenta71bfc249d3f814d7d659fe5cf4cb582483e8938

Build compiler_rt for WASM exe


1 files changed, 10 insertions(+), 0 deletions(-)

src/link.cpp+10
...@@ -1101,6 +1101,16 @@ static void construct_linker_job_wasm(LinkJob *lj) {...@@ -1101,6 +1101,16 @@ static void construct_linker_job_wasm(LinkJob *lj) {
1101 for (size_t i = 0; i < g->link_objects.length; i += 1) {1101 for (size_t i = 0; i < g->link_objects.length; i += 1) {
1102 lj->args.append((const char *)buf_ptr(g->link_objects.at(i)));1102 lj->args.append((const char *)buf_ptr(g->link_objects.at(i)));
1103 }1103 }
1104
1105 if (g->out_type == OutTypeExe) {
1106 if (g->libc_link_lib == nullptr) {
1107 Buf *builtin_a_path = build_a(g, "builtin");
1108 lj->args.append(buf_ptr(builtin_a_path));
1109 }
1110
1111 Buf *compiler_rt_o_path = build_compiler_rt(g);
1112 lj->args.append(buf_ptr(compiler_rt_o_path));
1113 }
1104}1114}
11051115
1106static void coff_append_machine_arg(CodeGen *g, ZigList<const char *> *list) {1116static void coff_append_machine_arg(CodeGen *g, ZigList<const char *> *list) {