Skip to content

Commit

Permalink
Less &&, so we can re-run the package-wasm script with impunity
Browse files Browse the repository at this point in the history
There are more efficient ways to do incremental builds, but this is
convenient.
  • Loading branch information
sz3 committed Feb 4, 2024
1 parent 4862400 commit a9bd6e4
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions package-wasm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,20 @@ apt update
apt install python3 -y

cd opencv4/
mkdir opencv-build-wasm && cd opencv-build-wasm
mkdir opencv-build-wasm
cd opencv-build-wasm
python3 ../platforms/js/build_js.py build_wasm --build_wasm --emscripten_dir=/emsdk/upstream/emscripten

cd /usr/src/app
mkdir build-wasm && cd build-wasm
mkdir build-wasm
cd build-wasm
emcmake cmake .. -DUSE_WASM=1 -DOPENCV_DIR=/usr/src/app/opencv4
make -j5 install
(cd ../web/ && tar -czvf cimbar.wasm.tar.gz cimbar_js.* index.html main.js)

cd /usr/src/app
mkdir build-asmjs && cd build-asmjs
mkdir build-asmjs
cd build-asmjs
emcmake cmake .. -DUSE_WASM=2 -DOPENCV_DIR=/usr/src/app/opencv4
make -j5 install
(cd ../web/ && zip cimbar.asmjs.zip cimbar_js.js index.html main.js)
Expand Down

0 comments on commit a9bd6e4

Please sign in to comment.