From 57e5cb041f44bf25b5723ac2672d67375fe85543412fec00b53c154950b4197a Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Sat, 30 Apr 2022 16:43:28 +0000 Subject: [PATCH] - Deactive python3 by default, it's just not a good idea for ring0. OBS-URL: https://build.opensuse.org/package/show/security/libseccomp?expand=0&rev=98 --- libseccomp.changes | 5 +++++ libseccomp.spec | 16 +++++++++++----- series | 1 - 3 files changed, 16 insertions(+), 6 deletions(-) delete mode 100644 series diff --git a/libseccomp.changes b/libseccomp.changes index 8313bf9..df01158 100644 --- a/libseccomp.changes +++ b/libseccomp.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Sat Apr 30 16:42:48 UTC 2022 - Jan Engelhardt + +- Deactive python3 by default, it's just not a good idea for ring0. + ------------------------------------------------------------------- Thu Apr 21 21:23:08 UTC 2022 - Jan Engelhardt diff --git a/libseccomp.spec b/libseccomp.spec index c0c8ccf..aa8ff47 100644 --- a/libseccomp.spec +++ b/libseccomp.spec @@ -28,15 +28,17 @@ Source: https://github.com/seccomp/libseccomp/releases/download/v%versio Source2: https://github.com/seccomp/libseccomp/releases/download/v%version/libseccomp-%version.tar.gz.asc Source3: %name.keyring Source99: baselibs.conf -Source100: series Patch1: make-python-build.patch BuildRequires: autoconf BuildRequires: automake >= 1.11 BuildRequires: fdupes BuildRequires: libtool >= 2 BuildRequires: pkgconfig +%bcond_without python +%if 0%{?with python} BuildRequires: python-rpm-macros BuildRequires: python3-Cython >= 0.29 +%endif %description The libseccomp library provides an interface to the Linux Kernel's @@ -102,7 +104,9 @@ echo 'int main () { return 0; }' >tests/52-basic-load.c autoreconf -fiv %configure \ --includedir="%_includedir/%name" \ +%if 0%{?with python} --enable-python \ +%endif --disable-static \ --disable-silent-rules \ GPERF=/bin/true @@ -111,11 +115,11 @@ autoreconf -fiv %install %make_install find "%buildroot/%_libdir" -type f -name "*.la" -delete +rm -fv %buildroot/%python3_sitearch/install_files.txt %fdupes %buildroot/%_prefix -rm %{buildroot}%{python3_sitearch}/install_files.txt %check -export LD_LIBRARY_PATH="${PWD}/src/.libs" +export LD_LIBRARY_PATH="$PWD/src/.libs" make check %post -n %lname -p /sbin/ldconfig @@ -135,8 +139,10 @@ make check %_bindir/scmp_sys_resolver %_mandir/man1/scmp_sys_resolver.1* +%if 0%{?with python} %files -n python3-seccomp -%{python3_sitearch}/seccomp-%{version}-py*.egg-info -%{python3_sitearch}/seccomp.cpython*.so +%python3_sitearch/seccomp-%version-py*.egg-info +%python3_sitearch/seccomp.cpython*.so +%endif %changelog diff --git a/series b/series deleted file mode 100644 index a26b99a..0000000 --- a/series +++ /dev/null @@ -1 +0,0 @@ -make-python-build.patch