Skip to content

Fix freetype wheel building #21279

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

Merged
merged 2 commits into from
Oct 6, 2021
Merged

Conversation

QuLogic
Copy link
Member

@QuLogic QuLogic commented Oct 5, 2021

PR Summary

The changes in #21263 caused wheel builds to fail, which we didn't see because they aren't run on pull requests. I've made sure that wheel CI passes this time.

The problem is that setting CC only is incomplete, and we need to set the linker, etc. It is better to grab that from sysconfig rather than messing around with the distutils compiler that I originally did. Also, fix build on PyPy as well.

PR Checklist

  • [n/a] Has pytest style unit tests (and pytest passes).
  • Is Flake 8 compliant (run flake8 on changed files to check).
  • [n/a] New features are documented, with examples if plot related.
  • [n/a] Documentation is sphinx and numpydoc compliant (the docs should build without error).
  • [n/a] Conforms to Matplotlib style conventions (install flake8-docstrings and run flake8 --docstring-convention=all).
  • [n/a] New features have an entry in doc/users/next_whats_new/ (follow instructions in README.rst there).
  • [n/a] API changes documented in doc/api/next_api_changes/ (follow instructions in README.rst there).

@QuLogic QuLogic added the Build label Oct 5, 2021
@QuLogic QuLogic added this to the v3.5.0 milestone Oct 5, 2021
Using just `CC` from the `distutils` compiler can break universal2
wheels on macOS, but passing all compiler and linker settings appears to
work.

Plus grabbing this information from `sysconfig` is better than hacking
the `distutils` compiler into working.
PyPy doesn't have a host type, so don't pass `--host` in that case, and
hope it is correct (which has been how it was since forever anyway.)
@QuLogic QuLogic force-pushed the fix-freetype-wheel branch from 0db0e86 to 81730f7 Compare October 5, 2021 05:18
@jklymak jklymak merged commit b8c22f0 into matplotlib:master Oct 6, 2021
@lumberbot-app
Copy link

lumberbot-app bot commented Oct 6, 2021

Owee, I'm MrMeeseeks, Look at me.

There seem to be a conflict, please backport manually. Here are approximate instructions:

  1. Checkout backport branch and update it.
$ git checkout v3.5.x
$ git pull
  1. Cherry pick the first parent branch of the this PR on top of the older branch:
$ git cherry-pick -m1 b8c22f027c6cf7bb6fe85357250f2c60a7eef384
  1. You will likely have some merge/cherry-pick conflict here, fix them and commit:
$ git commit -am 'Backport PR #21279: Fix freetype wheel building'
  1. Push to a named branch :
git push YOURFORK v3.5.x:auto-backport-of-pr-21279-on-v3.5.x
  1. Create a PR against branch v3.5.x, I would have named this PR:

"Backport PR #21279 on branch v3.5.x (Fix freetype wheel building)"

And apply the correct labels and milestones.

Congratulation you did some good work! Hopefully your backport PR will be tested by the continuous integration and merged soon!

Remember to remove Still Needs Manual Backport label once the PR gets merged.

If these instruction are inaccurate, feel free to suggest an improvement.

QuLogic pushed a commit to meeseeksmachine/matplotlib that referenced this pull request Oct 6, 2021
@QuLogic
Copy link
Member Author

QuLogic commented Oct 6, 2021

The backport was combined with #21263 in #21277.

@QuLogic QuLogic deleted the fix-freetype-wheel branch October 6, 2021 08:01
tacaswell pushed a commit to tacaswell/matplotlib that referenced this pull request Oct 12, 2021
tacaswell pushed a commit that referenced this pull request Oct 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants