Skip to content

Commit

Permalink
s
Browse files Browse the repository at this point in the history
  • Loading branch information
Yisheng Jiang committed Mar 22, 2023
1 parent 3eae1b9 commit 2b18adf
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions spin/Makefile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
all: spin.wasm
all: spin.wasm.js

clean: src/spin.c
rm -f build/*
Expand All @@ -10,4 +10,7 @@ build/spin.o: build/spin.ll
llc -march=wasm32 -filetype=obj build/spin.ll -o build/spin.o

spin.wasm: build/spin.o
wasm-ld -O 4 --features=atomics,mutable-global,bulk-memory --no-check-features --allow-undefined --shared-memory --import-memory --no-entry --export-all -o spin.wasm build/spin.o
wasm-ld -O 4 --features=atomics,mutable-global,bulk-memory --no-check-features --allow-undefined --import-memory --no-entry --export-all -o spin.wasm build/spin.o

spin.wasm.js: spin.wasm
cat spin.wasm | npx encode-wasm-uint8 > spin.wasm.js

0 comments on commit 2b18adf

Please sign in to comment.