Skip to content
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

Add workflow to build wheels using cibuildwheel #294

Merged
merged 2 commits into from
Apr 9, 2024

Conversation

jonathangreen
Copy link
Contributor

@jonathangreen jonathangreen commented Mar 21, 2024

This PR adds a new workflow so that wheel builds are done like lxml using cibuildwheel, creating statically linked wheels for the platforms supported by cibuildwheel. See the lxml workflows/wheels.yml here.

This build a static wheel for each platform, runs the test suite using this wheel, and then uploads the wheel as a build artifact.

This should let us push wheels for all platforms out to PyPi. Right now the workflow just attaches the built wheels to the build as an artifact, since I don't have any access to PyPi for this repo. cibuildwheel has some guidance in their docs as to how to upload the built wheels to PyPi and could be added to the workflow as a follow up.

In order to successfully build static wheels for all the platforms these PR will need to be merged before this one:

@jonathangreen
Copy link
Contributor Author

Now that #292 is merged, I pulled that new commit into this PR, so the wheel builds are working and tests are passing for linux targets. MacOS targets won't work until #293 goes in. You can see the wheels built by this PR in the workflow run.

@jonathangreen jonathangreen force-pushed the feature/ci-build-wheel branch 3 times, most recently from a88e18f to 807ec96 Compare April 7, 2024 22:14
@jonathangreen
Copy link
Contributor Author

@mxamin not sure if you have any interest in this one, but I rebased it to the latest commits as well. Now that #291, #292 and #293 are all merged in, the ci build wheel workflow should complete successfully and upload all the built wheels as artifacts.

@mxamin
Copy link
Collaborator

mxamin commented Apr 8, 2024

@jonathangreen Yes, of course I'm interested :)
I still need to do some more tests. Meanwhile what's the blocker to get the wheels for windows platforms?
Currently our main tool to create windows wheels is Appveyor which I wasn't able to make it work.

@jonathangreen
Copy link
Contributor Author

The main blocker for windows wheels is that I don't know anything about Python builds on Windows, or really doing builds on windows in general 😆

cibuildwheel supports it, and GH actions has windows workers so I'm fairly sure its is quite doable to build the windows wheels are part of this workflow.

@jonathangreen
Copy link
Contributor Author

jonathangreen commented Apr 9, 2024

@mxamin I made a small PR here to add the windows wheel builds back into this action with the few details I know about the windows builds: #308

I figured it was useful to keep the windows bit separate, since those jobs are failing. Let me know though if you want me to merge #308 into this one.

@mxamin
Copy link
Collaborator

mxamin commented Apr 9, 2024

@jonathangreen Do you know why "cp37-manylinux_aarch64" build is failing?

@jonathangreen
Copy link
Contributor Author

It was passing when I originally made the PR. When I have a chance later today I'll take a look and see whats going on there.

@jonathangreen
Copy link
Contributor Author

It looks like upstream lxml stopped publishing wheels for cp37-manylinux_aarch64, which was causing the job to fail, because we couldn't install lxml via a wheel during the build process.

Here is where lxml excluded these wheels:

I updated the workflow, so we exclude the same wheel builds that lxml does, which should get everything building again.

@mxamin mxamin merged commit 3fea8a4 into xmlsec:master Apr 9, 2024
69 of 87 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants