emcc.sh (361B)
1 #!bin/sh 2 3 rm -rf bin 4 mkdir bin 5 cd bin 6 7 proj_name=App 8 proj_root_dir=$(pwd)/../ 9 10 flags=( 11 -w -s WASM=1 -s USE_WEBGL2=1 -s ASYNCIFY=1 -O1 12 ) 13 14 # Include directories 15 inc=( 16 -I ../third_party/include/ # Gunslinger includes 17 ) 18 19 # Source files 20 src=( 21 ../source/*.c 22 ) 23 24 libs=( 25 ) 26 27 # Build 28 emcc ${inc[*]} ${src[*]} ${flags[*]} -o $proj_name.html 29 30 cd .. 31 32 33