In your terminal run:
./server
Or if the server file is not executable:
chmod u+x server
./server
Visit http://localhost:8008/ in a browser supporting WebAssembly.
MAKE SURE EMSCRIPTEN IS INSTALLED IN THE HOME DIRECTORTY OF THE PROJECT
To compile calculator.c
to .wasm
, run:
emcc calculator/calculator.c -O2 -s WASM=1 -s SIDE_MODULE=1 -o calculator/calculator.wasm
MAKE SURE EMSCRIPTEN IS INSTALLED IN THE HOME DIRECTORTY OF THE PROJECT
To compile calculator.c
to .wasm
, run:
emcc stringinator/stringinator.c -O2 -s WASM=1 -s 'EXTRA_EXPORTED_RUNTIME_METHODS=["stringToUTF8", "UTF8ToString"]' -o stringinator/stringinator.js