Skip to content

Commit cc85c3c

Browse files
committed
Enable wasm addFunction/removeFunction to support calling FPDF_SaveAsCopy from js
1 parent d2a8757 commit cc85c3c

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

modules/wasm.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -591,8 +591,9 @@ def run_task_generate():
591591
"{0}".format("-g" if config == "debug" else "-O2"),
592592
"-s",
593593
f"EXPORTED_FUNCTIONS={complete_functions_list}",
594+
"-s", "ALLOW_TABLE_GROWTH",
594595
"-s",
595-
'EXPORTED_RUNTIME_METHODS=\'["ccall", "cwrap", "wasmExports", "HEAP8", "HEAP16", "HEAP32", "HEAPU8", "HEAPU16", "HEAPU32", "HEAPF32", "HEAPF64"]\'',
596+
'EXPORTED_RUNTIME_METHODS=\'["ccall", "cwrap", "wasmExports", "HEAP8", "HEAP16", "HEAP32", "HEAPU8", "HEAPU16", "HEAPU32", "HEAPF32", "HEAPF64", "addFunction", "removeFunction"]\'',
596597
"custom.cpp",
597598
lib_file_out,
598599
"-I{0}".format(include_dir),

0 commit comments

Comments
 (0)