Code reorganisation

- whitespace changes
 - remove empty %check phase
 - move all scriptlets to one place
This commit is contained in:
Michal Schorm 2021-09-13 13:23:20 +02:00
parent 802ff2081e
commit 082bdac247

View File

@ -22,12 +22,10 @@ Requires(post): policycoreutils
%description %description
SELinux policy modules for MySQL and MariaDB packages. SELinux policy modules for MySQL and MariaDB packages.
%prep %prep
%setup -q -n %{name}-%{version} %setup -q -n %{name}-%{version}
%pre
%selinux_relabel_pre -s %{selinuxtype}
%build %build
make make
@ -36,7 +34,9 @@ make
install -d %{buildroot}%{_datadir}/selinux/packages install -d %{buildroot}%{_datadir}/selinux/packages
install -m 0644 %{modulename}.pp.bz2 %{buildroot}%{_datadir}/selinux/packages install -m 0644 %{modulename}.pp.bz2 %{buildroot}%{_datadir}/selinux/packages
%check
%pre
%selinux_relabel_pre -s %{selinuxtype}
%post %post
%selinux_modules_install -s %{selinuxtype} %{_datadir}/selinux/packages/%{modulename}.pp.bz2 || : %selinux_modules_install -s %{selinuxtype} %{_datadir}/selinux/packages/%{modulename}.pp.bz2 || :
@ -49,6 +49,7 @@ fi
%posttrans %posttrans
%selinux_relabel_post -s %{selinuxtype} || : %selinux_relabel_post -s %{selinuxtype} || :
%files %files
%defattr(-,root,root,0755) %defattr(-,root,root,0755)
%attr(0644,root,root) %{_datadir}/selinux/packages/%{modulename}.pp.bz2 %attr(0644,root,root) %{_datadir}/selinux/packages/%{modulename}.pp.bz2