Skip to content

Commit

Permalink
Revise Emscripten optimizations
Browse files Browse the repository at this point in the history
  • Loading branch information
mesheets committed Jul 1, 2024
1 parent 650004d commit c4eb118
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ ifneq (,$(strip $(findstring $(TARGETTYPE), WebAssembly)))
# - Modularize: https://emscripten.org/docs/getting_started/FAQ.html#can-i-use-multiple-emscripten-compiled-programs-on-one-web-page
# - Environment: https://emscripten.org/docs/getting_started/FAQ.html#can-i-build-javascript-that-only-runs-on-the-web
# - Single File: https://emscripten.org/docs/compiling/Building-Projects.html?highlight=SINGLE_FILE#emscripten-linker-output-files
CFLAGS_EXEC += --shell-file ./emscripten/webnqc_shell.html -s EXPORT_NAME=createWebNqc -s EXPORTED_RUNTIME_METHODS='["callMain","FS"]' \
CFLAGS_EXEC += -Os --shell-file ./emscripten/webnqc_shell.html -s EXPORT_NAME=createWebNqc -s EXPORTED_RUNTIME_METHODS='["callMain","FS"]' \
-s INVOKE_RUN=false -s MODULARIZE=1 -s ENVIRONMENT=web -s WASM=0
else
ifneq (,$(strip $(findstring $(OSTYPE), Darwin)))
Expand Down Expand Up @@ -209,7 +209,7 @@ exec: info $(EXEC_DIR)/nqc$(EXEC_EXT)

$(EXEC_DIR)/nqc$(EXEC_EXT): compiler/parse.cpp $(OBJ)
$(MKDIR) $(dir $@)
$(CXX) -o $@ $(CFLAGS) $(CFLAGS_EXEC) $(OBJ) $(LIBS)
$(CXX) -o $@ $(CFLAGS_EXEC) $(OBJ) $(LIBS)

#
# Emscripten build for WebAssembly
Expand Down

0 comments on commit c4eb118

Please sign in to comment.