From: Bernie Innocenti Date: Thu, 31 May 2018 12:45:11 +0000 (+0900) Subject: Tweak the wasm build scripts X-Git-Url: https://codewiz.org/gitweb?a=commitdiff_plain;h=74aad1b6c6085cf10ea34868a0a1cc78d0e66695;p=mandelwow.git Tweak the wasm build scripts --- diff --git a/debug_wasm.sh b/debug_wasm.sh index b9bbad9..e63591f 100755 --- a/debug_wasm.sh +++ b/debug_wasm.sh @@ -2,6 +2,6 @@ set -e export CFLAGS="-g" export CXXFLAGS="$CFLAGS" cargo rustc --target wasm32-unknown-emscripten --bin mandelwow -- -C link-args='-s USE_SDL=2 --preload-file flora.xm' -cp -a target/wasm32-unknown-emscripten/release/mandelwow.{js,wasm} . -cp -a target/wasm32-unknown-emscripten/release/deps/mandelwow.data . +cp -a target/wasm32-unknown-emscripten/debug/mandelwow.{js,wasm} . +cp -a target/wasm32-unknown-emscripten/debug/deps/mandelwow.data . emrun . diff --git a/release_asmjs.sh b/release_asmjs.sh index ca5c98c..c4e6f33 100755 --- a/release_asmjs.sh +++ b/release_asmjs.sh @@ -1,4 +1,6 @@ set -e +export CFLAGS="-O2" +export CXXFLAGS="$CFLAGS" cargo rustc --target asmjs-unknown-emscripten --release --no-default-features --bin mandelwow -- -C link-args='--emrun -s USE_WEBGL2=1 -s USE_SDL=2 -s ASSERTIONS=2 --preload-file flora.xm' cp -a target/asmjs-unknown-emscripten/release/mandelwow.js . emrun . diff --git a/release_wasm.sh b/release_wasm.sh index 9e4992f..477000f 100755 --- a/release_wasm.sh +++ b/release_wasm.sh @@ -1,7 +1,7 @@ set -e export CFLAGS="-O2" export CXXFLAGS="$CFLAGS" -cargo rustc --target wasm32-unknown-emscripten --release --bin mandelwow -- -C link-args='--emrun -s USE_WEBGL2=1 -s USE_SDL=2 -s ASSERTIONS=2 --preload-file flora.xm' +cargo rustc --target wasm32-unknown-emscripten --release --bin mandelwow -- -C link-args='--emrun -s USE_SDL=2 -s ASSERTIONS=2 --preload-file flora.xm' cp -a target/wasm32-unknown-emscripten/release/mandelwow.{js,wasm} . cp -a target/wasm32-unknown-emscripten/release/deps/mandelwow.data . emrun .