1
0
mirror of https://github.com/sehugg/8bitworkshop.git synced 2024-12-30 18:31:30 +00:00
8bitworkshop/emsrc/caspr/Makefile.local
2018-02-15 09:56:45 -06:00

34 lines
727 B
Makefile

DEST=/Users/sehugg/PuzzlingPlans/8bitworkshop/src/worker
TARGETS=js/caspr.js wasm/caspr.js
all: $(TARGETS)
cp js/caspr.js $(DEST)
cp wasm/caspr.* $(DEST)/wasm
clean:
rm -f $(TARGETS)
js/%.js: %.bc
emcc -Oz --memory-init-file 0 \
-s ASM_JS=1 \
-s MODULARIZE=1 \
-s ALLOW_MEMORY_GROWTH=1 \
-s EXPORT_NAME=\"'$*'\" \
-s 'EXTRA_EXPORTED_RUNTIME_METHODS=["FS"]' \
-s FORCE_FILESYSTEM=1 \
$< -o $@ $(ARGS_$*) \
wasm/%.js: %.bc
emcc -Oz --memory-init-file 0 \
-s WASM=1 \
-s MODULARIZE=1 \
-s ALLOW_MEMORY_GROWTH=1 \
-s NO_EXIT_RUNTIME=1 \
-s BINARYEN_ASYNC_COMPILATION=0 \
-s EXPORT_NAME=\"'$*'\" \
-s 'EXTRA_EXPORTED_RUNTIME_METHODS=["FS"]' \
-s FORCE_FILESYSTEM=1 \
$< -o $@ $(ARGS_$*) \