summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Gilbert <floppym@gentoo.org>2022-09-13 13:33:30 -0400
committerMike Gilbert <floppym@gentoo.org>2022-09-13 13:34:26 -0400
commita60bcdc8ce5eec6674d5e28afa2bd4899d137508 (patch)
treeca64ccf9f2e249884db690d158d661c9970d7ffd
parentgui-libs/gtk: Version bump to 4.8.0 (diff)
downloadgentoo-a60bcdc8ce5eec6674d5e28afa2bd4899d137508.tar.gz
gentoo-a60bcdc8ce5eec6674d5e28afa2bd4899d137508.tar.bz2
gentoo-a60bcdc8ce5eec6674d5e28afa2bd4899d137508.zip
net-firewall/nftables: drop RESTRICT="test? ( userpriv )"
Instead, check for root and skip the relevant tests otherwise. Closes: https://bugs.gentoo.org/869989 Signed-off-by: Mike Gilbert <floppym@gentoo.org>
-rw-r--r--net-firewall/nftables/nftables-1.0.4-r2.ebuild8
-rw-r--r--net-firewall/nftables/nftables-1.0.5.ebuild8
-rw-r--r--net-firewall/nftables/nftables-9999.ebuild8
3 files changed, 18 insertions, 6 deletions
diff --git a/net-firewall/nftables/nftables-1.0.4-r2.ebuild b/net-firewall/nftables/nftables-1.0.4-r2.ebuild
index 0da0a19b311e..a1e256654082 100644
--- a/net-firewall/nftables/nftables-1.0.4-r2.ebuild
+++ b/net-firewall/nftables/nftables-1.0.4-r2.ebuild
@@ -29,7 +29,7 @@ fi
LICENSE="GPL-2"
SLOT="0/1"
IUSE="debug doc +gmp json libedit +modern-kernel python +readline static-libs test xtables"
-RESTRICT="test? ( userpriv ) !test? ( test )"
+RESTRICT="!test? ( test )"
RDEPEND="
>=net-libs/libmnl-1.0.4:0=
@@ -123,7 +123,11 @@ src_compile() {
src_test() {
emake check
- edo tests/shell/run-tests.sh -v
+ if [[ ${EUID} == 0 ]]; then
+ edo tests/shell/run-tests.sh -v
+ else
+ ewarn "Skipping shell tests (requires root)"
+ fi
# Need to rig up Python eclass if using this, but it doesn't seem to work
# for me anyway.
diff --git a/net-firewall/nftables/nftables-1.0.5.ebuild b/net-firewall/nftables/nftables-1.0.5.ebuild
index 24d357de9872..b6fdb61bd493 100644
--- a/net-firewall/nftables/nftables-1.0.5.ebuild
+++ b/net-firewall/nftables/nftables-1.0.5.ebuild
@@ -29,7 +29,7 @@ fi
LICENSE="GPL-2"
SLOT="0/1"
IUSE="debug doc +gmp json libedit +modern-kernel python +readline static-libs test xtables"
-RESTRICT="test? ( userpriv ) !test? ( test )"
+RESTRICT="!test? ( test )"
RDEPEND="
>=net-libs/libmnl-1.0.4:0=
@@ -120,7 +120,11 @@ src_compile() {
src_test() {
emake check
- edo tests/shell/run-tests.sh -v
+ if [[ ${EUID} == 0 ]]; then
+ edo tests/shell/run-tests.sh -v
+ else
+ ewarn "Skipping shell tests (requires root)"
+ fi
# Need to rig up Python eclass if using this, but it doesn't seem to work
# for me anyway.
diff --git a/net-firewall/nftables/nftables-9999.ebuild b/net-firewall/nftables/nftables-9999.ebuild
index 24d357de9872..b6fdb61bd493 100644
--- a/net-firewall/nftables/nftables-9999.ebuild
+++ b/net-firewall/nftables/nftables-9999.ebuild
@@ -29,7 +29,7 @@ fi
LICENSE="GPL-2"
SLOT="0/1"
IUSE="debug doc +gmp json libedit +modern-kernel python +readline static-libs test xtables"
-RESTRICT="test? ( userpriv ) !test? ( test )"
+RESTRICT="!test? ( test )"
RDEPEND="
>=net-libs/libmnl-1.0.4:0=
@@ -120,7 +120,11 @@ src_compile() {
src_test() {
emake check
- edo tests/shell/run-tests.sh -v
+ if [[ ${EUID} == 0 ]]; then
+ edo tests/shell/run-tests.sh -v
+ else
+ ewarn "Skipping shell tests (requires root)"
+ fi
# Need to rig up Python eclass if using this, but it doesn't seem to work
# for me anyway.