-
Notifications
You must be signed in to change notification settings - Fork 29
Pyodide support #275
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Pyodide support #275
Conversation
- Detect Emscripten cross-compilation in setup.py, skipping platform-specific sources (CoreText, DirectWrite, Uniscribe) - Add build-pyodide job to CI workflow - Upload Pyodide wheel to GitHub releases only (PyPI doesn't accept wasm32 wheels yet, see pypi/warehouse#10416) Fixes #270
| define_macros.append(("HAVE_DIRECTWRITE", "1")) | ||
| define_macros.append(("HAVE_UNISCRIBE", "1")) | ||
| libraries += ["usp10", "gdi32", "user32", "rpcrt4", "dwrite"] | ||
| sources += [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think harfbuzz.cc has all these files automatically included.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
but harfbuzz.cc lacks the subset module..
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right. That's annoying.
Pyodide doesn't support Python 3.14 yet, so we need to use 3.13 explicitly instead of '3.x' which resolves to the latest.
Remove redundant test step - cibuildwheel already runs tests via test-command for each wheel it builds.
|
@Vipitis the CI finally built some pyodide wheels for uharfbuzz here: https://github.com/harfbuzz/uharfbuzz/actions/runs/20712353445/artifacts/5023130791 Would you like to give them a go? The uharfuzz own tests do pass when run inside a pyodide venv, like cibuildwheel does. |
|
hey @anthrotype thanks a lot for figuring this out. I obtained the wheel yesterday already from your branch and now also from the ci artifacts. The latter has the wrong version number ( |
|
thanks for checking. the version number is expected, only when we push a tagged commit to do an actual release we do a full clone and "unshallow" the repository so the correnct version string is obtained from git. The 0.1 is setuptools-scm failing to get a proper tag. |
tox -e pyodidefor local build and testFixes #270