Add a very simple Emscripten-specific test.

This will be expanded on later to be a lot more complete.
This commit is contained in:
David Reid
2023-02-28 11:24:58 +10:00
parent 1f37940923
commit bfd66ab4d2
3 changed files with 289 additions and 0 deletions
+15
View File
@@ -6,3 +6,18 @@ Build and run from this directory. Example:
./bin/test_deviceio
Output files will be placed in the "res/output" folder.
Emscripten
----------
On Windows, you need to move into the build and run emsdk_env.bat from a command prompt using an absolute
path like "C:\emsdk\emsdk_env.bat". Note that PowerShell doesn't work for me for some reason. Examples:
emcc ../test_emscripten/ma_test_emscripten.c -o bin/test_emscripten.html-sAUDIO_WORKLET=1 -sWASM_WORKERS=1 -sASYNCIFY -DMA_ENABLE_AUDIO_WORKLETS -Wall -Wextra
If you output WASM it may not work when running the web page locally. To test you can run with something
like this:
emrun ./bin/test_emscripten.html
If you want to see stdout on the command line when running from emrun, add `--emrun` to your emcc command.