From b11c95dc9861a2f23afb73bd9672e5655b7d8348 Mon Sep 17 00:00:00 2001 From: Adam Scott Date: Tue, 20 Feb 2024 08:19:56 -0500 Subject: [PATCH] Add `WASM_BIGINT` linker flag to the web build (cherry picked from commit 3ae524fa9e42828183f8046f6f33b945475bb052) --- platform/web/detect.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/platform/web/detect.py b/platform/web/detect.py index a634a7ca8a4..d71e01349c3 100644 --- a/platform/web/detect.py +++ b/platform/web/detect.py @@ -220,6 +220,10 @@ def configure(env: "Environment"): env.Append(LINKFLAGS=["-s", "SIDE_MODULE=2"]) env.extra_suffix = ".dlink" + env.extra_suffix + # WASM_BIGINT is needed since emscripten ≥ 3.1.41 + if cc_semver >= (3, 1, 41): + env.Append(LINKFLAGS=["-s", "WASM_BIGINT"]) + # Reduce code size by generating less support code (e.g. skip NodeJS support). env.Append(LINKFLAGS=["-s", "ENVIRONMENT=web,worker"])