replace scriptlets with systemd macros (#856666)

cyrus-sasl-2.1.23-36
This commit is contained in:
Petr Lautrbach 2012-09-14 22:27:27 +02:00
parent 90d2211309
commit 8527d3716f
1 changed files with 10 additions and 16 deletions

View File

@ -8,7 +8,7 @@
Summary: The Cyrus SASL library
Name: cyrus-sasl
Version: 2.1.23
Release: 35%{?dist}
Release: 36%{?dist}
License: BSD with advertising
Group: System Environment/Libraries
# Source0 originally comes from ftp://ftp.andrew.cmu.edu/pub/cyrus-mail/;
@ -57,9 +57,9 @@ BuildRequires: libdb-devel
%if ! %{bootstrap_cyrus_sasl}
BuildRequires: openldap-devel
%endif
Requires(post): chkconfig, /sbin/service
Requires(pre): /usr/sbin/useradd /usr/sbin/groupadd
Requires(postun): /usr/sbin/userdel /usr/sbin/groupdel
Requires(post): chkconfig, /sbin/service systemd-units
Requires(pre): /usr/sbin/useradd /usr/sbin/groupadd systemd-units
Requires(postun): /usr/sbin/userdel /usr/sbin/groupdel systemd-units
Requires: /sbin/nologin
Provides: user(%username)
Provides: group(%username)
@ -348,22 +348,13 @@ getent group %{username} >/dev/null || groupadd -g 76 -r %{username}
getent passwd %{username} >/dev/null || useradd -r -g %{username} -d %{homedir} -s /sbin/nologin -c \"%{hint}\" %{username}
%post
if [ $1 -eq 1 ]; then
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
fi
%systemd_post saslauthd.service
%preun
if [ $1 -eq 0 ]; then
/bin/systemctl --no-reload disable saslauthd.service >/dev/null 2>&1 || :
/bin/systemctl stop saslauthd.service >/dev/null 2>&1 || :
fi
%systemd_preun saslauthd.service
%postun
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
if [ $1 -ge 1 ]; then
/bin/systemctl try-restart saslauthd.service >/dev/null 2>&1 || :
fi
exit 0
%systemd_postun_with_restart saslauthd.service
%triggerun -n cyrus-sasl -- cyrus-sasl < 2.1.23-32
/usr/bin/systemd-sysv-convert --save saslauthd >/dev/null 2>&1 || :
@ -440,6 +431,9 @@ exit 0
/etc/rc.d/init.d/saslauthd
%changelog
* Fri Sep 14 2012 Petr Lautrbach <plautrba@redhat.com> 2.1.23-36
- replace scriptlets with systemd macros (#856666)
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.1.23-35
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild