]> git.ipfire.org Git - thirdparty/nftables.git/commitdiff
py: add pyproject.toml to support PEP-517-compatible build-systems
authorJeremy Sowden <jeremy@azazel.net>
Mon, 31 Jul 2023 11:40:24 +0000 (12:40 +0100)
committerPablo Neira Ayuso <pablo@netfilter.org>
Thu, 3 Aug 2023 07:47:49 +0000 (09:47 +0200)
This makes it possible to build and install the module without directly
invoking setup.py which has been deprecated.

Retain the setup.py script for backwards-compatibility.

Update INSTALL to mention the new config-file.

Link: https://blog.ganssle.io/articles/2021/10/setup-py-deprecated.html
Signed-off-by: Jeremy Sowden <jeremy@azazel.net>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
INSTALL
py/Makefile.am
py/pyproject.toml [new file with mode: 0644]

diff --git a/INSTALL b/INSTALL
index 9b626745d7a41e72dfde6a8b6d547b5ba69ee177..53021e5aafc35f396eb7422387ff92eac5b6001c 100644 (file)
--- a/INSTALL
+++ b/INSTALL
@@ -86,7 +86,8 @@ Installation instructions for nftables
 
  CPython bindings are available for nftables under the py/ folder.
 
- setup.py is provided to install it.
+ A pyproject.toml config file and legacy setup.py script are provided to install
+ it.
 
  Source code
  ===========
index 974539fd44ad2d2fe84f751d32244be9b486ba81..76aa082f8709dad5329ae5c57dd9ebb08515efd2 100644 (file)
@@ -1 +1 @@
-EXTRA_DIST = setup.cfg setup.py src
+EXTRA_DIST = pyproject.toml setup.cfg setup.py src
diff --git a/py/pyproject.toml b/py/pyproject.toml
new file mode 100644 (file)
index 0000000..fed528d
--- /dev/null
@@ -0,0 +1,3 @@
+[build-system]
+requires = ["setuptools"]
+build-backend = "setuptools.build_meta"