mirror of
https://github.com/python/cpython
synced 2024-09-15 23:57:10 +00:00
gh-84461: Build Emscripten with WASM BigInt support (#94219)
This commit is contained in:
parent
51fd4de101
commit
e69306f08b
|
@ -98,9 +98,11 @@ ### Cross compile to wasm32-emscripten for node
|
||||||
```
|
```
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
node --experimental-wasm-threads --experimental-wasm-bulk-memory builddir/emscripten-node/python.js
|
node --experimental-wasm-threads --experimental-wasm-bulk-memory --experimental-wasm-bigint builddir/emscripten-node/python.js
|
||||||
```
|
```
|
||||||
|
|
||||||
|
(``--experimental-wasm-bigint`` is not needed with recent NodeJS versions)
|
||||||
|
|
||||||
# wasm32-emscripten limitations and issues
|
# wasm32-emscripten limitations and issues
|
||||||
|
|
||||||
Emscripten before 3.1.8 has known bugs that can cause memory corruption and
|
Emscripten before 3.1.8 has known bugs that can cause memory corruption and
|
||||||
|
|
2
configure
generated
vendored
2
configure
generated
vendored
|
@ -7953,6 +7953,8 @@ fi
|
||||||
|
|
||||||
as_fn_append LDFLAGS_NODIST " -sALLOW_MEMORY_GROWTH -sTOTAL_MEMORY=20971520"
|
as_fn_append LDFLAGS_NODIST " -sALLOW_MEMORY_GROWTH -sTOTAL_MEMORY=20971520"
|
||||||
|
|
||||||
|
as_fn_append LDFLAGS_NODIST " -sWASM_BIGINT"
|
||||||
|
|
||||||
as_fn_append LDFLAGS_NODIST " -sFORCE_FILESYSTEM -lidbfs.js -lnodefs.js -lproxyfs.js -lworkerfs.js"
|
as_fn_append LDFLAGS_NODIST " -sFORCE_FILESYSTEM -lidbfs.js -lnodefs.js -lproxyfs.js -lworkerfs.js"
|
||||||
|
|
||||||
if test "x$enable_wasm_dynamic_linking" = xyes; then :
|
if test "x$enable_wasm_dynamic_linking" = xyes; then :
|
||||||
|
|
|
@ -2028,6 +2028,9 @@ AS_CASE([$ac_sys_system],
|
||||||
dnl Start with 20 MB and allow to grow
|
dnl Start with 20 MB and allow to grow
|
||||||
AS_VAR_APPEND([LDFLAGS_NODIST], [" -sALLOW_MEMORY_GROWTH -sTOTAL_MEMORY=20971520"])
|
AS_VAR_APPEND([LDFLAGS_NODIST], [" -sALLOW_MEMORY_GROWTH -sTOTAL_MEMORY=20971520"])
|
||||||
|
|
||||||
|
dnl map int64_t and uint64_t to JS bigint
|
||||||
|
AS_VAR_APPEND([LDFLAGS_NODIST], [" -sWASM_BIGINT"])
|
||||||
|
|
||||||
dnl Include file system support
|
dnl Include file system support
|
||||||
AS_VAR_APPEND([LDFLAGS_NODIST], [" -sFORCE_FILESYSTEM -lidbfs.js -lnodefs.js -lproxyfs.js -lworkerfs.js"])
|
AS_VAR_APPEND([LDFLAGS_NODIST], [" -sFORCE_FILESYSTEM -lidbfs.js -lnodefs.js -lproxyfs.js -lworkerfs.js"])
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue