summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--mkspecs/wasm-emscripten/qmake.conf8
1 files changed, 8 insertions, 0 deletions
diff --git a/mkspecs/wasm-emscripten/qmake.conf b/mkspecs/wasm-emscripten/qmake.conf
index 6c4e62aff2..a9ded4be12 100644
--- a/mkspecs/wasm-emscripten/qmake.conf
+++ b/mkspecs/wasm-emscripten/qmake.conf
@@ -21,6 +21,11 @@ EMCC_COMMON_LFLAGS = \
--bind \
-s \"BINARYEN_TRAP_MODE=\'clamp\'\"
+EMCC_USE_PORTS_FLAGS = \
+ -s USE_LIBPNG=1 \
+ -s USE_FREETYPE=1 \
+ -s USE_ZLIB=1
+
# The -s arguments can also be used with release builds,
# but are here in debug for clarity.
EMCC_COMMON_LFLAGS_DEBUG = \
@@ -38,6 +43,9 @@ QMAKE_COMPILER += emscripten
QMAKE_CC = emcc
QMAKE_CXX = em++
+QMAKE_CFLAGS += $$EMCC_USE_PORTS_FLAGS
+QMAKE_CXXFLAGS += $$EMCC_USE_PORTS_FLAGS
+
# Practical debugging setup:
# "-g4" preserves function names for stack traces
# "-Os" produces reasonably sized binaries