Switch RBTools's packaging to pyproject.toml.

Review Request #14138 — Created Sept. 3, 2024 and updated

Information

RBTools
release-5.x

Reviewers

RBTools has historically been a setuptools-based project, relying
heavily on the dynamic ability of setup.py. Over the years, the Python
ecosystem has moved to pyproject.toml files, with pluggable build
backends. This has reached a point of maturity, and pip will soon
remove support for installing either production or editable installs
from a legacy source tree.

We now use pyproject.toml to define all of the metadata of the
package. Since RBTools's packaging needs are simple, we can get away
with using the setuptools.build_meta backend directly.

Tested isolated builds in the following setups:

  • python -m build . (builds sdist, then a wheel from the sdist)
  • python -m build . -s (builds sdist)
  • python -m build . -w (builds wheel)

Tested isolated editable installs using pip install -e . and
non-isolated editable installs using pip install -e --no-build-isolation
and with make develop.

Performed full tree diffs of generated wheels from ./setup.py bdist_wheel
(prior to this change) and both wheel-producing python -m build methods.
Verified that all content was identical, with the exception of differences
in source map paths and some modern metadata for the package.

Manually inspected the distribution contents to make sure we had everything
we want in the package and nothing we don't want.

Summary ID
Switch RBTools's packaging to pyproject.toml.
RBTools has historically been a setuptools-based project, relying heavily on the dynamic ability of `setup.py`. Over the years, the Python ecosystem has moved to `pyproject.toml` files, with pluggable build backends. This has reached a point of maturity, and `pip` will soon remove support for installing either production or editable installs from a legacy source tree. We now use `pyproject.toml` to define all of the metadata of the package. Since RBTools's packaging needs are simple, we can get away with using the `setuptools.build_meta` backend directly.
cedc11073480b0a593ce993fe9e45acc1b855fd0
chipx86
Review request changed
Change Summary:
  • Fixed the Python version range. The old range in setup.py was incorrect.
  • Added docs to the source distribution.
Commits:
Summary ID
Switch RBTools's packaging to pyproject.toml.
RBTools has historically been a setuptools-based project, relying heavily on the dynamic ability of `setup.py`. Over the years, the Python ecosystem has moved to `pyproject.toml` files, with pluggable build backends. This has reached a point of maturity, and `pip` will soon remove support for installing either production or editable installs from a legacy source tree. We now use `pyproject.toml` to define all of the metadata of the package. Since RBTools's packaging needs are simple, we can get away with using the `setuptools.build_meta` backend directly.
c502eb4fd19078f13a03774acb6736bc3bdae2ec
Switch RBTools's packaging to pyproject.toml.
RBTools has historically been a setuptools-based project, relying heavily on the dynamic ability of `setup.py`. Over the years, the Python ecosystem has moved to `pyproject.toml` files, with pluggable build backends. This has reached a point of maturity, and `pip` will soon remove support for installing either production or editable installs from a legacy source tree. We now use `pyproject.toml` to define all of the metadata of the package. Since RBTools's packaging needs are simple, we can get away with using the `setuptools.build_meta` backend directly.
cedc11073480b0a593ce993fe9e45acc1b855fd0

Checks run (2 succeeded)

flake8 passed.
JSHint passed.
david
  1. Ship It!
  2. 
      
maubin
  1. Ship It!
  2.