Conditionally pass debug flag to emcc
This commit is contained in:
parent
328dac0617
commit
c83e6831ea
@ -337,25 +337,29 @@ main :: proc() {
|
|||||||
)
|
)
|
||||||
run_cmd(cmd, "")
|
run_cmd(cmd, "")
|
||||||
|
|
||||||
|
wasm_debug_flag := opts.debug ? []string{"-g"} : []string{}
|
||||||
|
|
||||||
run_cmd(
|
run_cmd(
|
||||||
{
|
temp_concat(
|
||||||
"emcc" + EMSCRIPTEN_SHELL_EXT,
|
{
|
||||||
"-g",
|
"emcc" + EMSCRIPTEN_SHELL_EXT,
|
||||||
"-o",
|
"-o",
|
||||||
"bin/web/index.html",
|
"bin/web/index.html",
|
||||||
"bin/web/game.wasm.o",
|
"bin/web/game.wasm.o",
|
||||||
"libs/raylib/zig-out-static/lib/libraylib.a",
|
"libs/raylib/zig-out-static/lib/libraylib.a",
|
||||||
"libs/physfs/build/libphysfs.a",
|
"libs/physfs/build/libphysfs.a",
|
||||||
"-sUSE_GLFW=3",
|
"-sUSE_GLFW=3",
|
||||||
"-sWASM_BIGINT",
|
"-sWASM_BIGINT",
|
||||||
"-sWARN_ON_UNDEFINED_SYMBOLS=0",
|
"-sWARN_ON_UNDEFINED_SYMBOLS=0",
|
||||||
"-sALLOW_MEMORY_GROWTH",
|
"-sALLOW_MEMORY_GROWTH",
|
||||||
"-sASSERTIONS",
|
"-sASSERTIONS",
|
||||||
"--shell-file",
|
"--shell-file",
|
||||||
"main_web/index_template.html",
|
"main_web/index_template.html",
|
||||||
"--preload-file",
|
"--preload-file",
|
||||||
"assets",
|
"assets",
|
||||||
},
|
},
|
||||||
|
wasm_debug_flag,
|
||||||
|
),
|
||||||
"",
|
"",
|
||||||
)
|
)
|
||||||
remove_file("./bin/web/game.wasm.o")
|
remove_file("./bin/web/game.wasm.o")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user