mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-27 13:59:08 +00:00
make wasm32-wasi default target given zig bug is fixed
This commit is contained in:
parent
dd8914a75c
commit
b26fc9f1af
1 changed files with 1 additions and 14 deletions
|
@ -362,21 +362,8 @@ pub fn build_zig_host_wasm32(
|
||||||
unimplemented!("Linking a shared library to wasm not yet implemented");
|
unimplemented!("Linking a shared library to wasm not yet implemented");
|
||||||
}
|
}
|
||||||
|
|
||||||
let zig_target = if matches!(opt_level, OptLevel::Development) {
|
|
||||||
"wasm32-wasi"
|
|
||||||
} else {
|
|
||||||
// For LLVM backend wasm we are emitting a .bc file anyway so this target is OK
|
|
||||||
"i386-linux-musl"
|
|
||||||
};
|
|
||||||
|
|
||||||
// NOTE currently just to get compiler warnings if the host code is invalid.
|
// NOTE currently just to get compiler warnings if the host code is invalid.
|
||||||
// the produced artifact is not used
|
// the produced artifact is not used
|
||||||
//
|
|
||||||
// NOTE we're emitting LLVM IR here (again, it is not actually used)
|
|
||||||
//
|
|
||||||
// we'd like to compile with `-target wasm32-wasi` but that is blocked on
|
|
||||||
//
|
|
||||||
// https://github.com/ziglang/zig/issues/9414
|
|
||||||
let mut zig_cmd = zig();
|
let mut zig_cmd = zig();
|
||||||
|
|
||||||
zig_cmd
|
zig_cmd
|
||||||
|
@ -397,7 +384,7 @@ pub fn build_zig_host_wasm32(
|
||||||
"--library",
|
"--library",
|
||||||
"c",
|
"c",
|
||||||
"-target",
|
"-target",
|
||||||
zig_target,
|
"wasm32-wasi",
|
||||||
// "-femit-llvm-ir=/home/folkertdev/roc/roc/crates/cli_testing_examples/benchmarks/platform/host.ll",
|
// "-femit-llvm-ir=/home/folkertdev/roc/roc/crates/cli_testing_examples/benchmarks/platform/host.ll",
|
||||||
"-fPIC",
|
"-fPIC",
|
||||||
"--strip",
|
"--strip",
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue