mirror of
https://github.com/ggerganov/ggwave.git
synced 2026-04-21 05:36:33 +08:00
close #19 : add cmake option for single-file wasm build
If enabled, we build ggwave using "-s SINGLE_FILE=1" which causes the WASM to be embedded inside the .js file. Otherwise, 2 separate files are produced: - libggwave.js - libggwave.wasm
This commit is contained in:
@@ -21,6 +21,8 @@ endif()
|
||||
if (EMSCRIPTEN)
|
||||
set(GGWAVE_SUPPORT_SDL2_DEFAULT ON)
|
||||
set(BUILD_SHARED_LIBS_DEFAULT OFF)
|
||||
|
||||
option(GGWAVE_WASM_SINGLE_FILE "ggwave: embed WASM inside the generated ggwave.js" ON)
|
||||
else()
|
||||
set(GGWAVE_SUPPORT_SDL2_DEFAULT ON)
|
||||
set(BUILD_SHARED_LIBS_DEFAULT ON)
|
||||
|
||||
Reference in New Issue
Block a user