]> git.ipfire.org Git - thirdparty/snapper.git/commitdiff
- enable SELinux per default 792/head
authorArvin Schnell <aschnell@suse.de>
Tue, 21 Mar 2023 09:24:12 +0000 (10:24 +0100)
committerArvin Schnell <aschnell@suse.de>
Tue, 21 Mar 2023 09:24:12 +0000 (10:24 +0100)
Makefile.repo
package/snapper.changes
snapper.spec.in

index 0db54d95545f7dfeca75f5dd1689c61060ceb806..085f2706a966f1629489c53f8d67002c858c3b69 100644 (file)
@@ -11,7 +11,7 @@ endif
 PREFIX = /usr
 
 configure: all
-       ./configure --prefix=$(PREFIX) --libdir=$(PREFIX)/$(LIB)
+       ./configure --prefix=$(PREFIX) --libdir=$(PREFIX)/$(LIB) --enable-selinux
 
 all:
        aclocal
index ecf4441b3a8e209a7de5cba055185f005944ca2d..042f59a6035c6f6de580a64b4554a7ff31e5d381 100644 (file)
@@ -1,3 +1,9 @@
+-------------------------------------------------------------------
+Tue Mar 21 08:51:05 CET 2023 - aschnell@suse.com
+
+- enable SELinux (and allow to disable via conditional build)
+  (bsc#1209515)
+
 -------------------------------------------------------------------
 Thu Feb 23 11:14:58 CET 2023 - aschnell@suse.com
 
index f99b18ea28691d619b280399d90bb9c337369ef6..0a0024aa68d546330b970c297c72380971aac4cf 100644 (file)
@@ -1,7 +1,7 @@
 #
 # spec file for package snapper
 #
-# Copyright (c) 2022 SUSE LLC
+# Copyright (c) 2023 SUSE LLC
 #
 # All modifications and additions to the file contributed by third parties
 # remain the property of their copyright owners, unless otherwise agreed
@@ -28,6 +28,9 @@
 %define pam_security_dir /%{_lib}/security
 %endif
 
+# Optionally build without SELinux support
+%bcond_without selinux
+
 # Optionally build with test coverage reporting
 %bcond_with coverage
 
@@ -95,10 +98,12 @@ BuildRequires:  libzypp(plugin:commit)
 BuildRequires:  pam-devel
 %if 0%{?fedora_version} || 0%{?rhel_version} || 0%{?centos_version} || 0%{?scientificlinux_version}
 BuildRequires:  json-c-devel
-BuildRequires:  libselinux-devel
 %else
 BuildRequires:  libjson-c-devel
 %endif
+%if %{with selinux}
+BuildRequires:  libselinux-devel
+%endif
 BuildRequires:  zlib-devel
 %if %{with coverage}
 BuildRequires:  lcov
@@ -131,17 +136,13 @@ export CXXFLAGS="%{optflags} -DNDEBUG"
 autoreconf -fvi
 %configure \
        --docdir="%{_defaultdocdir}/snapper"                                    \
-%if %{with coverage}
-       --enable-coverage \
-%endif
+       %{?with_coverage:--enable-coverage}                                     \
        --with-pam-security="%{pam_security_dir}"                               \
 %if ! 0%{?suse_version}
        --disable-rollback                                                      \
        --disable-btrfs-quota                                                   \
 %endif
-%if 0%{?fedora_version} || 0%{?rhel_version}
-       --enable-selinux                                                        \
-%endif
+       %{?with_selinux:--enable-selinux}                                       \
        --disable-silent-rules --disable-ext4
 make %{?_smp_mflags}