summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--meta-networking/recipes-filter/nftables/nftables/0001-nftables-python-Split-root-from-prefix.patch44
-rw-r--r--meta-networking/recipes-filter/nftables/nftables_1.0.6.bb6
2 files changed, 5 insertions, 45 deletions
diff --git a/meta-networking/recipes-filter/nftables/nftables/0001-nftables-python-Split-root-from-prefix.patch b/meta-networking/recipes-filter/nftables/nftables/0001-nftables-python-Split-root-from-prefix.patch
deleted file mode 100644
index 377b29fff8..0000000000
--- a/meta-networking/recipes-filter/nftables/nftables/0001-nftables-python-Split-root-from-prefix.patch
+++ /dev/null
@@ -1,44 +0,0 @@
1From c7513195a72b2e5be5c9c439cc606eb5dcc3fb7a Mon Sep 17 00:00:00 2001
2From: Alex Kiernan <alex.kiernan@gmail.com>
3Date: Tue, 12 Jul 2022 17:44:34 +0100
4Subject: [PATCH] nftables: python: Split root from prefix
5
6The buildpaths QA check fails when python is enabled:
7
8 WARNING: nftables-1.0.4-r0 do_package_qa: QA Issue: File /usr/lib/python3.10/site-packages/nftables/__pycache__/nftables.cpython-310.pyc in package nftables-python contains reference to TMPDIR
9 File /usr/lib/python3.10/site-packages/nftables/__pycache__/__init__.cpython-310.pyc in package nftables-python contains reference to TMPDIR [buildpaths]
10
11Upstream-Status: Pending
12Signed-off-by: Alex Kiernan <alex.kiernan@gmail.com>
13---
14 py/Makefile.am | 2 +-
15 py/setup.py | 2 +-
16 2 files changed, 2 insertions(+), 2 deletions(-)
17
18diff --git a/py/Makefile.am b/py/Makefile.am
19index 215ecd9e4751..a827cca10135 100644
20--- a/py/Makefile.am
21+++ b/py/Makefile.am
22@@ -7,7 +7,7 @@ all-local:
23 install-exec-local:
24 cd $(srcdir) && \
25 $(PYTHON_BIN) setup.py build --build-base $(abs_builddir) \
26- install --prefix $(DESTDIR)$(prefix)
27+ install --root $(DESTDIR) --prefix $(prefix)
28
29 uninstall-local:
30 rm -rf $(DESTDIR)$(prefix)/lib*/python*/site-packages/nftables
31diff --git a/py/setup.py b/py/setup.py
32index 72fc8fd98b26..976aec583b71 100755
33--- a/py/setup.py
34+++ b/py/setup.py
35@@ -1,5 +1,5 @@
36 #!/usr/bin/env python
37-from distutils.core import setup
38+from setuptools._distutils.core import setup
39 from nftables import NFTABLES_VERSION
40
41 setup(name='nftables',
42--
432.35.1
44
diff --git a/meta-networking/recipes-filter/nftables/nftables_1.0.6.bb b/meta-networking/recipes-filter/nftables/nftables_1.0.6.bb
index 789a493127..fb9c6e7d62 100644
--- a/meta-networking/recipes-filter/nftables/nftables_1.0.6.bb
+++ b/meta-networking/recipes-filter/nftables/nftables_1.0.6.bb
@@ -7,7 +7,6 @@ DEPENDS = "libmnl libnftnl bison-native \
7 ${@bb.utils.contains('PACKAGECONFIG', 'mini-gmp', '', 'gmp', d)}" 7 ${@bb.utils.contains('PACKAGECONFIG', 'mini-gmp', '', 'gmp', d)}"
8 8
9SRC_URI = "http://www.netfilter.org/projects/nftables/files/${BP}.tar.xz \ 9SRC_URI = "http://www.netfilter.org/projects/nftables/files/${BP}.tar.xz \
10 file://0001-nftables-python-Split-root-from-prefix.patch \
11 file://run-ptest \ 10 file://run-ptest \
12 " 11 "
13SRC_URI[sha256sum] = "2407430ddd82987670e48dc2fda9e280baa8307abec04ab18d609df3db005e4c" 12SRC_URI[sha256sum] = "2407430ddd82987670e48dc2fda9e280baa8307abec04ab18d609df3db005e4c"
@@ -40,6 +39,11 @@ TESTDIR = "tests"
40 39
41PRIVATE_LIBS:${PN}-ptest:append = "libnftables.so.1" 40PRIVATE_LIBS:${PN}-ptest:append = "libnftables.so.1"
42 41
42do_install:append() {
43 # Avoid "contains reference to TMPDIR" warning
44 find ${D} -name *.pyc -delete
45}
46
43do_install_ptest() { 47do_install_ptest() {
44 cp -rf ${S}/build-aux ${D}${PTEST_PATH} 48 cp -rf ${S}/build-aux ${D}${PTEST_PATH}
45 cp -rf ${S}/src ${D}${PTEST_PATH} 49 cp -rf ${S}/src ${D}${PTEST_PATH}