From 04bc1b7bdcdcd5b590e48e4e651ebbdaaca2b30eee41b786ba8d5e44e0731a73 Mon Sep 17 00:00:00 2001 From: Johannes Segitz Date: Thu, 18 Mar 2021 10:08:18 +0000 Subject: [PATCH] Accepting request 879710 from home:dimstar:Factory - Switch to pcre2: + Replace pcre-devel BuildRequires with pkgconfig(libpcre2-8) + Pass USE_PCRE2=y to make. As we have currently pcre2 AND pcre in the distro bootstrap, I'm trying to clean that up a little bit Thie will hopefully allow to keep pcre2, but get rid of pcre - making the bootstrap cycle a little bit smaller (Requires a Preinstall: libprcre2-8-0 in prjconf, which should replace the existing preinstall libpcre0 we already have) OBS-URL: https://build.opensuse.org/request/show/879710 OBS-URL: https://build.opensuse.org/package/show/security:SELinux/libselinux?expand=0&rev=133 --- libselinux-bindings.changes | 7 +++++++ libselinux-bindings.spec | 14 ++++++-------- libselinux.changes | 11 ++++++++++- libselinux.spec | 6 +++--- 4 files changed, 26 insertions(+), 12 deletions(-) diff --git a/libselinux-bindings.changes b/libselinux-bindings.changes index 1a3094d..e2ba3ef 100644 --- a/libselinux-bindings.changes +++ b/libselinux-bindings.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Wed Mar 17 15:17:27 UTC 2021 - Dominique Leuenberger + +- Switch to pcre2: + + Replace pcre-devel BuildRequires with pkgconfig(libpcre2-8) + + Pass USE_PCRE2=y to make. + ------------------------------------------------------------------- Tue Mar 9 09:01:15 UTC 2021 - Johannes Segitz diff --git a/libselinux-bindings.spec b/libselinux-bindings.spec index 5925e00..95f019a 100644 --- a/libselinux-bindings.spec +++ b/libselinux-bindings.spec @@ -36,11 +36,11 @@ Patch4: readv-proto.patch Patch5: python3.8-compat.patch Patch6: swig4_moduleimport.patch BuildRequires: libsepol-devel-static >= %{libsepol_ver} -BuildRequires: pcre-devel BuildRequires: python-rpm-macros BuildRequires: python3-devel BuildRequires: ruby-devel BuildRequires: swig +BuildRequires: pkgconfig(libpcre2-8) %description libselinux provides an interface to get and set process and file @@ -83,15 +83,13 @@ language. %build %define _lto_cflags %{nil} -make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="%{optflags} -fno-semantic-interposition" -C src V=1 -make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="%{optflags} -fno-semantic-interposition" -C src swigify V=1 -make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="%{optflags} -fno-semantic-interposition" -C src pywrap V=1 -make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="%{optflags} -fno-semantic-interposition" -C src rubywrap V=1 +make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="%{optflags} -fno-semantic-interposition" swigify V=1 USE_PCRE2=y +make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="%{optflags} -fno-semantic-interposition" pywrap V=1 USE_PCRE2=y +make %{?_smp_mflags} LIBDIR="%{_libdir}" CFLAGS="%{optflags} -fno-semantic-interposition" rubywrap V=1 USE_PCRE2=y %install -make DESTDIR=%{buildroot} LIBDIR="%{_libdir}" SHLIBDIR="/%{_lib}" LIBSEPOLA=%{_libdir}/libsepol.a -C src install V=1 -make DESTDIR=%{buildroot} LIBDIR="%{_libdir}" SHLIBDIR="/%{_lib}" LIBSEPOLA=%{_libdir}/libsepol.a -C src install-pywrap V=1 -make DESTDIR=%{buildroot} LIBDIR="%{_libdir}" SHLIBDIR="/%{_lib}" LIBSEPOLA=%{_libdir}/libsepol.a -C src install-rubywrap V=1 +make DESTDIR=%{buildroot} LIBDIR="%{_libdir}" SHLIBDIR="/%{_lib}" LIBSEPOLA=%{_libdir}/libsepol.a install-pywrap V=1 +make DESTDIR=%{buildroot} LIBDIR="%{_libdir}" SHLIBDIR="/%{_lib}" LIBSEPOLA=%{_libdir}/libsepol.a install-rubywrap V=1 rm -rf %{buildroot}/%{_lib} %{buildroot}%{_libdir}/libselinux.* %{buildroot}%{_libdir}/pkgconfig %files -n python3-selinux diff --git a/libselinux.changes b/libselinux.changes index ffefba2..29e8ce7 100644 --- a/libselinux.changes +++ b/libselinux.changes @@ -1,3 +1,12 @@ +------------------------------------------------------------------- +Wed Mar 17 15:13:16 UTC 2021 - Dominique Leuenberger + +- Switch to pcre2: + + Replace pcre-devel BuildRequires with pkgconfig(libpcre2-8) + + Pass USE_PCRE2=y to make. + + Replace pkgconfig(libpcre) Requires in -devel static with + pkgconfig(libpcre2-8). + ------------------------------------------------------------------- Tue Mar 9 09:01:15 UTC 2021 - Johannes Segitz @@ -6,7 +15,7 @@ Tue Mar 9 09:01:15 UTC 2021 - Johannes Segitz See "KERNEL STATUS PAGE" section in avc_init(3) for more details. * New log callback levels for enforcing and policy load notices - SELINUX_POLICYLOAD, SELINUX_SETENFORCE - * Changed userspace AVC setenforce and policy load messages to audit + * Changed userspace AVC setenforce and policy load messages to audit format. ------------------------------------------------------------------- diff --git a/libselinux.spec b/libselinux.spec index ced4e94..07ab65f 100644 --- a/libselinux.spec +++ b/libselinux.spec @@ -32,8 +32,8 @@ Patch4: readv-proto.patch Patch5: skip_cycles.patch BuildRequires: fdupes BuildRequires: libsepol-devel >= %{libsepol_ver} -BuildRequires: pcre-devel BuildRequires: pkgconfig +BuildRequires: pkgconfig(libpcre2-8) %description libselinux provides an interface to get and set process and file @@ -84,7 +84,7 @@ necessary to develop your own software using libselinux. Summary: Static archives for the SELinux runtime Group: Development/Libraries/C and C++ Requires: libselinux-devel = %{version} -Requires: pkgconfig(libpcre) +Requires: pkgconfig(libpcre2-8) Requires: pkgconfig(libsepol) %description devel-static @@ -101,7 +101,7 @@ necessary to develop your own software using libselinux. %build %define _lto_cflags %{nil} -make %{?_smp_mflags} LIBDIR="%{_libdir}" CC="gcc" CFLAGS="%{optflags} -fno-semantic-interposition" +make %{?_smp_mflags} LIBDIR="%{_libdir}" CC="gcc" CFLAGS="%{optflags} -fno-semantic-interposition" USE_PCRE2=y %install mkdir -p %{buildroot}/%{_lib}