Fix Asyncify and improve build process
Build system improvements: - Add wasm-opt stub for Docker build to bypass asyncify in container - Add apply-asyncify.sh script for host-side asyncify transformation - Update build-pcbnew.sh to install wasm-opt stub and add EXPORTED_RUNTIME_METHODS - Add --with-zlib=sys to wxWidgets configure for proper zlib linking - Improve update-baseline-screenshots.sh to only copy new/significantly changed files wxWidgets submodule update: - Fix EM_JS to EM_ASYNC_JS for proper Asyncify registration Test updates: - Add new baseline screenshots for bitmapbuttons, dnd, gridrenderers, printpreview, specialized tests - Add kicad-pcbnew initial screenshot - Fix wxgrid-controls.png and wxgrid-dedicated-page.png (were showing errors) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
b70f098ae2
commit
6771e7de74
44 changed files with 167 additions and 32 deletions
32
wasm/stubs/wasm-opt-stub.sh
Executable file
32
wasm/stubs/wasm-opt-stub.sh
Executable file
|
|
@ -0,0 +1,32 @@
|
|||
#!/bin/bash
|
||||
# Stub wasm-opt that does nothing
|
||||
# This allows Emscripten to generate Asyncify JS runtime without running the actual transformation
|
||||
# The real wasm-opt --asyncify is run on the host where more RAM is available
|
||||
|
||||
# Handle --version query from Emscripten
|
||||
if [[ "$1" == "--version" ]]; then
|
||||
echo "wasm-opt version 121 (version_121)"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
# Find the output file argument (-o)
|
||||
OUTPUT=""
|
||||
INPUT=""
|
||||
PREV_ARG=""
|
||||
|
||||
for arg in "$@"; do
|
||||
if [ "$PREV_ARG" = "-o" ]; then
|
||||
OUTPUT="$arg"
|
||||
elif [[ "$arg" != -* ]] && [ -f "$arg" ]; then
|
||||
INPUT="$arg"
|
||||
fi
|
||||
PREV_ARG="$arg"
|
||||
done
|
||||
|
||||
# If we have both input and output, copy input to output
|
||||
if [ -n "$INPUT" ] && [ -n "$OUTPUT" ] && [ "$INPUT" != "$OUTPUT" ]; then
|
||||
cp "$INPUT" "$OUTPUT"
|
||||
fi
|
||||
|
||||
# Exit successfully so Emscripten thinks wasm-opt ran
|
||||
exit 0
|
||||
Loading…
Reference in a new issue