From bac48fef998829780216c024c1e57ce2ad3f2e51 Mon Sep 17 00:00:00 2001 From: Michal Schorm Date: Mon, 13 Sep 2021 13:23:20 +0200 Subject: [PATCH] Code reorganisation - whitespace changes - remove empty %check phase - move all scriptlets to one place -- Cherry-picked Fedora commit: 082bdac2473eceba348ba3b0eedd47b5e01315eb -- Related: #2073386 --- mysql-selinux.spec | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/mysql-selinux.spec b/mysql-selinux.spec index c8bdb5c..083cbe9 100644 --- a/mysql-selinux.spec +++ b/mysql-selinux.spec @@ -14,7 +14,7 @@ Summary: SELinux policy modules for MySQL and MariaDB packages Source0: https://github.com/devexp-db/mysql-selinux/archive/refs/tags/%{version}.tar.gz#/%{name}-%{version}.tar.gz BuildArch: noarch -BuildRequires: make +BuildRequires: make BuildRequires: selinux-policy-devel Requires(post): policycoreutils %{?selinux_requires} @@ -22,12 +22,10 @@ Requires(post): policycoreutils %description SELinux policy modules for MySQL and MariaDB packages. + %prep %setup -q -n %{name}-%{version} -%pre -%selinux_relabel_pre -s %{selinuxtype} - %build make @@ -36,7 +34,9 @@ make install -d %{buildroot}%{_datadir}/selinux/packages install -m 0644 %{modulename}.pp.bz2 %{buildroot}%{_datadir}/selinux/packages -%check + +%pre +%selinux_relabel_pre -s %{selinuxtype} %post %selinux_modules_install -s %{selinuxtype} %{_datadir}/selinux/packages/%{modulename}.pp.bz2 || : @@ -49,6 +49,7 @@ fi %posttrans %selinux_relabel_post -s %{selinuxtype} || : + %files %defattr(-,root,root,0755) %attr(0644,root,root) %{_datadir}/selinux/packages/%{modulename}.pp.bz2