Skip to content

Consider adding a pyproject.toml for PEP 517 #505

@ca-hu

Description

@ca-hu

The libselinux python bindings and the sepolicy python module use setup.py without a pyprojects.toml.

./libselinux/src/setup.py
./python/sepolicy/setup.py

Which leads to deprecation warnings, e.g.:

[   22s] python3.11 -m pip install --prefix=/usr `test -n "/home/abuild/rpmbuild/BUILD/policycoreutils-3.10-build/BUILDROOT" && echo --root /home/abuild/rpmbuild/BUILD/policycoreutils-3.10-build/BUILDROOT --ignore-installed --no-deps`  .
[   23s] WARNING: Disabling truststore because of missing certificates
[   23s] Processing /home/abuild/rpmbuild/BUILD/policycoreutils-3.10-build/policycoreutils-3.10/sepolicy
[   23s]   Preparing metadata (setup.py): started
[   23s]   Preparing metadata (setup.py): finished with status 'done'
[   23s] Building wheels for collected packages: sepolicy
[   23s]   DEPRECATION: Building 'sepolicy' using the legacy setup.py bdist_wheel mechanism, which will be removed in a future version. pip 25.3 will enforce this behaviour change. A possible replacement is to use the standardized build interface by setting the `--use-pep517` option, (possibly combined with `--no-build-isolation`), or adding a `pyproject.toml` file to the source tree of 'sepolicy'. Discussion can be found at https://github.com/pypa/pip/issues/6334
[   23s]   Building wheel for sepolicy (setup.py): started
[   23s]   Building wheel for sepolicy (setup.py): finished with status 'done'

More information can be found here: pypa/pip#6334

ATM it is still mostly backwards compatible, but we have run into issues with build isolation lately:
https://bugzilla.suse.com/show_bug.cgi?id=1258173

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions