Skip to content

Conversation

@clayote
Copy link
Contributor

@clayote clayote commented Oct 20, 2025

Python 3.14 finally removes the distutils package, which breaks the way p4a byte-compiles all its recipes using setup.py install. This PR replaces all instances of setup.py install with pip install, but leaves all other uses of setup.py.

Two recipes, android and freetype, used distutils in other ways. I've replaced those uses with setuptools, too.

On Python 3.14, many recipes, notably `msgpack`, no longer byte-
compile with `setup.py install`, because the way that command
byte-compiles relies on `distutils`, which is gone.
@clayote clayote requested a review from T-Dynamos October 22, 2025 01:30
@clayote clayote changed the title Use pip install instead of setup.py install when building recipes Remove distutils Oct 22, 2025
@clayote
Copy link
Contributor Author

clayote commented Oct 22, 2025

I bumped the freetype versions just because I happened to be looking at them. If this isn't good practice, I'll put them back.

@T-Dynamos
Copy link
Contributor

@clayote Can we port freetype-py to PyProjectRecipe?

@clayote
Copy link
Contributor Author

clayote commented Oct 22, 2025

hmmm... sure, why not

I don't think this will require the version hack
`setuptools-scm` can't deal with the github hosted one, it seems.
@clayote
Copy link
Contributor Author

clayote commented Oct 23, 2025

The way I had to change the source url to get the newly PyProject based FreetypePy recipe to build suggests that I'll need to make similar changes to every other recipe. Well, it had to happen eventually.

@clayote
Copy link
Contributor Author

clayote commented Oct 23, 2025

The version of cffi that adds Python 3.14 support also drops Python 3.8 support.

I think that means p4a will need to pick one or the other, and I'd certainly favor Python 3.14.

T-Dynamos and others added 5 commits October 23, 2025 15:42
On Python 3.14, many recipes, notably `msgpack`, no longer byte-
compile with `setup.py install`, because the way that command
byte-compiles relies on `distutils`, which is gone.
It was actually using distutils every time, apparently?
Copy link
Contributor

@T-Dynamos T-Dynamos left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@clayote
Copy link
Contributor Author

clayote commented Oct 26, 2025

Any recipe not using a pythonhosted.org url will likely need to be revised, because eg. GitHub hosted bundles don't have version metadata that setuptools can use.

@kuzeyron kuzeyron added the core-providers Core code that's not a recipe label Oct 26, 2025
@T-Dynamos
Copy link
Contributor

I think those recipes aren’t a top priority since they’re not widely used and most of the popular ones are already up to date. Let’s handle the rest in another PR since this one already includes 15 files.

@clayote clayote marked this pull request as ready for review October 27, 2025 04:51
@kuzeyron kuzeyron added the PR-tested PR has been tested label Oct 27, 2025
@kuzeyron
Copy link
Contributor

Thanks!

@kuzeyron kuzeyron merged commit e1bd249 into kivy:develop Oct 27, 2025
42 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

core-providers Core code that's not a recipe PR-tested PR has been tested recipe

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants