diff options
Diffstat (limited to 'code/build.sh')
| -rwxr-xr-x | code/build.sh | 21 |
1 files changed, 18 insertions, 3 deletions
diff --git a/code/build.sh b/code/build.sh index be1cbc2..96b9516 100755 --- a/code/build.sh +++ b/code/build.sh @@ -14,8 +14,6 @@ fi CompilerFlags=" -fdiagnostics-absolute-paths ---target=wasm32 --nostdlib " WarningFlags=" @@ -27,6 +25,7 @@ WarningFlags=" -Wno-pointer-arith -Wno-unused-parameter -Wno-unused-function +-Wno-null-dereference " LinkerFlags=" @@ -52,9 +51,25 @@ fi printf 'game.c\n' clang \ $CompilerFlags \ + -nostdlib \ + --target=wasm32 \ $WarningFlags \ $LinkerFlags \ -o ../build/game.wasm \ game.c printf 'index.html platform.js\n' -cp index.html platform.js ../build +ln -f index.html platform.js ../build + +if true +then + cd ../ws + printf 'ws.c\n' + clang \ + -I./libs/wsServer/include -I./libs/wsServer/src \ + $CompilerFlags \ + $WarningFlags \ + -o ../build/ws \ + ws.c +fi + +printf '%s\n' "update" | websocat 'ws://localhost:1234/'
\ No newline at end of file |
