-added compilation for multithreaded and singlethreaded code

-fixed problem with assets loading
This commit is contained in:
Mergul 2021-03-13 15:04:42 +01:00
parent 3eb4a40c39
commit 1254a990f1
2 changed files with 10 additions and 3 deletions

View file

@ -53,7 +53,7 @@ add_global_link_arguments(link_args, language : 'd')
if host_machine.cpu_family() == 'wasm32'
add_global_arguments('--output-bc', language : 'd') # Adding it in cross files breaks linker detection
emcc = find_program('emcc')
args_wasm = ['-s', 'FORCE_FILESYSTEM=1','-s', 'USE_PTHREADS=1', '-s', 'USE_SDL=2', '-s', 'ALLOW_MEMORY_GROWTH=1', '-s', 'WASM_MEM_MAX=1024MB', '-s', 'MALLOC=dlmalloc', '-s', 'WASM=1']
args_wasm = ['-O3', '-s', 'FORCE_FILESYSTEM=1', '-s', 'USE_SDL=2', '-s', 'USE_SDL_IMAGE=2', '-s', 'SDL2_IMAGE_FORMATS=["png"]', '-s', 'ERROR_ON_UNDEFINED_SYMBOLS=0', '-s', 'ALLOW_MEMORY_GROWTH=1', '-s', 'WASM_MEM_MAX=1024MB', '-s', 'MALLOC=dlmalloc', '-s', 'WASM=1', '--shell-file', '../demos/emscripten_multi_shell.html', '-s', 'DISABLE_DEPRECATED_FIND_EVENT_TARGET_BEHAVIOR=1']
endif