ci: bump emscripten build to 3.14#5455
Conversation
davidhewitt
left a comment
There was a problem hiding this comment.
🎉 I've managed to get this working with 3.14!
| cd $(PYTHONBUILD)/cross-build/wasm32-emscripten/build/python && \ | ||
| source $(EMSDKDIR)/emsdk_env.sh && \ | ||
| emar rcs Modules/_hacl/libhacl.a Modules/_hacl/*.o | ||
| # Copy all .a libraries |
There was a problem hiding this comment.
cc @hoodmane have you run into this with pyodide? I suspect I'm somehow misconfiguring the build.
There was a problem hiding this comment.
"This" being needing to manually link the hacl modules in because the Tools script is missing them.
There was a problem hiding this comment.
Yes, we have problems with libmpdec and libexpat too but hacl is the worst.
|
|
||
| PYTHONLIBDIR=$(BUILDROOT)/install/Python-$(PYVERSION)/lib | ||
|
|
||
| CROSS_PYTHON=$(PYTHONBUILD)/cross-build/wasm32-emscripten/build/python/python.sh |
There was a problem hiding this comment.
Note that we are discussing moving some of these things. Should hopefully only be a minor annoyance for you though.
emscripten/Makefile
Outdated
| $(EMSDKDIR)/emsdk_env.sh: $(BUILDROOT)/.exists $(PYTHONBUILD)/.patched | ||
| # NB: future Python versions will stash emscripten version in config.toml | ||
| # EMSCRIPTEN_VERSION=$$(python -c "import tomllib; print(tomllib.load(open('$(PYTHONBUILD)/Tools/wasm/emscripten/config.toml', 'rb'))['emscripten-version'])") | ||
| EMSCRIPTEN_VERSION=4.0.12 && \ |
There was a problem hiding this comment.
I was following https://devguide.python.org/getting-started/setup-building/#emscripten, which says to use 4.0.12 for 3.14
emscripten/Makefile
Outdated
| # NB: future Python versions will stash emscripten version in config.toml | ||
| # EMSCRIPTEN_VERSION=$$(python -c "import tomllib; print(tomllib.load(open('$(PYTHONBUILD)/Tools/wasm/emscripten/config.toml', 'rb'))['emscripten-version'])") | ||
| EMSCRIPTEN_VERSION=4.0.12 && \ | ||
| git clone https://github.com/emscripten-core/emsdk.git --depth 1 --branch $$EMSCRIPTEN_VERSION $(EMSDKDIR) && \ |
There was a problem hiding this comment.
You can just clone the latest
git clone https://github.com/emscripten-core/emsdk.git --depth 1 $(EMSDKDIR)
There was a problem hiding this comment.
Actually if you're willing to use the tip of the 3.14 branch, I've automated the installation of emscripten and you could get rid of all of this and use:
python$(PYMAJORMINOR) Tools/wasm/emscripten build --quiet --emsdk-cache=./emsdk-cache
and it will install emscripten for you.
There was a problem hiding this comment.
Ah nice, I managed to get that working 👍
|
I think this is ready to merge, will probably do so later unless anyone has concerns (a CI-only change). |
bschoenmaeckers
left a comment
There was a problem hiding this comment.
Nice seeing this getting less complicated 👍
Attempts to update the emscripten build to 3.13.