mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-26 13:29:12 +00:00
Change a file extension .o -> .wasm to make Zig emit wasm
Zig 0.9 would prioritise the -target but now it seems to prioritise the file extension
This commit is contained in:
parent
f8b787c93a
commit
a590fafa76
1 changed files with 2 additions and 2 deletions
|
@ -121,12 +121,12 @@ fn build_wasm_test_host() {
|
||||||
|
|
||||||
fn build_wasm_platform(out_dir: &str, source_path: &str) -> PathBuf {
|
fn build_wasm_platform(out_dir: &str, source_path: &str) -> PathBuf {
|
||||||
let mut outfile = PathBuf::from(out_dir).join(PLATFORM_FILENAME);
|
let mut outfile = PathBuf::from(out_dir).join(PLATFORM_FILENAME);
|
||||||
outfile.set_extension("o");
|
outfile.set_extension("wasm");
|
||||||
|
|
||||||
run_zig(&[
|
run_zig(&[
|
||||||
"build-lib",
|
"build-lib",
|
||||||
"-target",
|
"-target",
|
||||||
"wasm32-wasi",
|
"wasm32-wasi-musl",
|
||||||
"-lc",
|
"-lc",
|
||||||
source_path,
|
source_path,
|
||||||
&format!("-femit-bin={}", outfile.to_str().unwrap()),
|
&format!("-femit-bin={}", outfile.to_str().unwrap()),
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue