commit: 70db06723e73ae0b00458866e8b2913945b7a6f6 Author: Michael Mair-Keimberger <mm1ke <AT> gentoo <DOT> org> AuthorDate: Wed Feb 18 19:53:07 2026 +0000 Commit: Michael Mair-Keimberger <mm1ke <AT> gentoo <DOT> org> CommitDate: Wed Feb 18 19:53:07 2026 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=70db0672
sys-libs/libseccomp: remove unused patches Signed-off-by: Michael Mair-Keimberger <mm1ke <AT> gentoo.org> .../files/libseccomp-2.5.5-aliasing.patch | 30 ---------- .../libseccomp-2.5.5-arch-syscall-check.patch | 45 -------------- .../files/libseccomp-2.5.5-which-hunt.patch | 69 ---------------------- .../files/libseccomp-python-shared.patch | 25 -------- 4 files changed, 169 deletions(-) diff --git a/sys-libs/libseccomp/files/libseccomp-2.5.5-aliasing.patch b/sys-libs/libseccomp/files/libseccomp-2.5.5-aliasing.patch deleted file mode 100644 index 60190702d381..000000000000 --- a/sys-libs/libseccomp/files/libseccomp-2.5.5-aliasing.patch +++ /dev/null @@ -1,30 +0,0 @@ -https://github.com/seccomp/libseccomp/commit/2847f10dddca72167309c04cd09f326fd3b78e2f - -From 2847f10dddca72167309c04cd09f326fd3b78e2f Mon Sep 17 00:00:00 2001 -From: Sam James <[email protected]> -Date: Sun, 24 Dec 2023 20:38:06 +0100 -Subject: [PATCH] scmp_bpf_sim: fix aliasing UB - -See https://github.com/seccomp/libseccomp/pull/425. - -Punning sys_data_b between uint32_t* and struct* seccomp_data isn't legal, -use memcpy to fix the testsuite with Clang 17. - -Modern compilers recognise this idiom and optimise it out anyway. - -Signed-off-by: Sam James <[email protected]> -Acked-by: Tom Hromatka <[email protected]> -Signed-off-by: Paul Moore <[email protected]> ---- a/tools/scmp_bpf_sim.c -+++ b/tools/scmp_bpf_sim.c -@@ -182,7 +182,8 @@ static void bpf_execute(const struct bpf_program *prg, - switch (code) { - case BPF_LD+BPF_W+BPF_ABS: - if (k < BPF_SYSCALL_MAX) { -- uint32_t val = *((uint32_t *)&sys_data_b[k]); -+ uint32_t val; -+ memcpy(&val, &sys_data_b[k], sizeof(val)); - state.acc = ttoh32(arch, val); - } else - exit_error(ERANGE, ip_c); - diff --git a/sys-libs/libseccomp/files/libseccomp-2.5.5-arch-syscall-check.patch b/sys-libs/libseccomp/files/libseccomp-2.5.5-arch-syscall-check.patch deleted file mode 100644 index 238098ad4c9e..000000000000 --- a/sys-libs/libseccomp/files/libseccomp-2.5.5-arch-syscall-check.patch +++ /dev/null @@ -1,45 +0,0 @@ -From 744c9a897b74ad66d065791593e25a05e4b6f6a1 Mon Sep 17 00:00:00 2001 -From: Michal Privoznik <[email protected]> -Date: Tue, 1 Nov 2022 11:59:51 +0100 -Subject: [PATCH] src: Make arch-syscall-check work in VPATH build - -The aim of arch-syscall-check test is to check for syscalls -missing implementation. It does so by comparing two files: - - 1) src/syscalls.csv - 2) include/seccomp-syscalls.h - -However, due to use of relative paths these files are not found -when doing a VPATH build. But, we can re-use an idea from GNU -coreutils and get an absolute path to the source dir. All that's -needed then is to prefix those two paths with the source dir -path. - -Signed-off-by: Michal Privoznik <[email protected]> -Acked-by: Tom Hromatka <[email protected]> -Signed-off-by: Paul Moore <[email protected]> ---- - src/arch-syscall-check | 7 +++++-- - 1 file changed, 5 insertions(+), 2 deletions(-) - -diff --git a/src/arch-syscall-check b/src/arch-syscall-check -index ae67daa..9c7fd41 100755 ---- a/src/arch-syscall-check -+++ b/src/arch-syscall-check -@@ -22,8 +22,11 @@ - # along with this library; if not, see <http://www.gnu.org/licenses>. - # - --SYSCALL_CSV="./syscalls.csv" --SYSCALL_HDR="../include/seccomp-syscalls.h" -+# Based on an idea from GNU coreutils -+abs_topsrcdir="$(unset CDPATH; cd $(dirname $0)/.. && pwd)" -+ -+SYSCALL_CSV="$abs_topsrcdir/src/syscalls.csv" -+SYSCALL_HDR="$abs_topsrcdir/include/seccomp-syscalls.h" - - function check_snr() { - (export LC_ALL=C; diff \ --- -2.44.0 - diff --git a/sys-libs/libseccomp/files/libseccomp-2.5.5-which-hunt.patch b/sys-libs/libseccomp/files/libseccomp-2.5.5-which-hunt.patch deleted file mode 100644 index 90dc25bf4e7c..000000000000 --- a/sys-libs/libseccomp/files/libseccomp-2.5.5-which-hunt.patch +++ /dev/null @@ -1,69 +0,0 @@ -https://github.com/seccomp/libseccomp/pull/424 - -From 865adeed17cac7063cbbce0c5df225aa35c83621 Mon Sep 17 00:00:00 2001 -From: Sam James <[email protected]> -Date: Sat, 16 Dec 2023 02:17:36 +0000 -Subject: [PATCH] tests: avoid use of non-portable `which` - -which is not a standard POSIX utility, and indeed, each of these test scripts -uses #!/bin/bash as its shebang, so we can use `type -P` which has the same -behaviour as `which` for free. - -(If the tests used POSIX shell, we could do `command -v`, its only caveat is -that it'll pick up functions in the user's shell, which doesn't matter 99% of -the time anyway.) - -Distributions like Debian [0] and Gentoo [1] are looking to remove `which` -from their base set of packages. - -[0] https://lwn.net/Articles/874049/ -[1] https://bugs.gentoo.org/646588 - -Signed-off-by: Sam James <[email protected]> ---- a/tests/38-basic-pfc_coverage.sh -+++ b/tests/38-basic-pfc_coverage.sh -@@ -18,7 +18,7 @@ - # - function check_deps() { - [[ -z "$1" ]] && return -- which "$1" >& /dev/null -+ type -P "$1" >& /dev/null - return $? - } - ---- a/tests/55-basic-pfc_binary_tree.sh -+++ b/tests/55-basic-pfc_binary_tree.sh -@@ -18,7 +18,7 @@ - # - function check_deps() { - [[ -z "$1" ]] && return -- which "$1" >& /dev/null -+ type -P "$1" >& /dev/null - return $? - } - ---- a/tests/regression -+++ b/tests/regression -@@ -73,7 +73,7 @@ GLBL_SYS_API="../tools/scmp_api_level" - # - function check_deps() { - [[ -z "$1" ]] && return -- which "$1" >& /dev/null -+ type -P "$1" >& /dev/null - return $? - } - ---- a/tests/testgen -+++ b/tests/testgen -@@ -32,7 +32,7 @@ - # - function verify_deps() { - [[ -z "$1" ]] && return -- if ! which "$1" >& /dev/null; then -+ if ! type -P "$1" >& /dev/null; then - echo "error: install \"$1\" and include it in your \$PATH" - exit 1 - fi --- -2.43.0 - diff --git a/sys-libs/libseccomp/files/libseccomp-python-shared.patch b/sys-libs/libseccomp/files/libseccomp-python-shared.patch deleted file mode 100644 index 93e1ec8a9156..000000000000 --- a/sys-libs/libseccomp/files/libseccomp-python-shared.patch +++ /dev/null @@ -1,25 +0,0 @@ -From 763b863c3028f604f16cc6d2de7452dc16458596 Mon Sep 17 00:00:00 2001 -From: Mike Gilbert <[email protected]> -Date: Sun, 23 May 2021 16:17:32 -0400 -Subject: [PATCH] Link python module against shared library - ---- - src/python/setup.py | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/src/python/setup.py b/src/python/setup.py -index 0419111..fb650d0 100755 ---- a/src/python/setup.py -+++ b/src/python/setup.py -@@ -41,7 +41,7 @@ setup( - ext_modules = [ - Extension("seccomp", ["seccomp.pyx"], - # unable to handle libtool libraries directly -- extra_objects=["../.libs/libseccomp.a"], -+ extra_objects=["../.libs/libseccomp.so"], - # fix build warnings, see PEP 3123 - extra_compile_args=["-fno-strict-aliasing"]) - ] --- -2.32.0.rc1 -
