From 5b976e5f842efefdbe79261feedbd730294edcd1 Mon Sep 17 00:00:00 2001 From: David Teigland Date: Wed, 5 Sep 2012 08:54:12 -0500 Subject: [PATCH] Scriptlets replaced with new systemd macros --- dlm.spec | 19 +++++++------------ 1 file changed, 7 insertions(+), 12 deletions(-) diff --git a/dlm.spec b/dlm.spec index 140c11f..4bf359b 100644 --- a/dlm.spec +++ b/dlm.spec @@ -1,6 +1,6 @@ Name: dlm Version: 3.99.5 -Release: 6%{?dist} +Release: 7%{?dist} License: GPLv2 and GPLv2+ and LGPLv2+ # For a breakdown of the licensing, see README.license Group: System Environment/Kernel @@ -53,21 +53,13 @@ install -Dm 0644 init/dlm.service %{buildroot}%{_unitdir}/dlm.service install -Dm 0644 init/dlm.sysconfig %{buildroot}/etc/sysconfig/dlm %post -if [ $1 -eq 1 ] ; then - /bin/systemctl daemon-reload >/dev/null 2>&1 || : -fi +%systemd_post dlm.service %preun -if [ $1 -eq 0 ] ; then - /bin/systemctl --no-reload disable dlm.service > /dev/null 2>&1 || : - /bin/systemctl stop dlm.service > /dev/null 2>&1 || : -fi +%systemd_preun dlm.service %postun -/bin/systemctl daemon-reload >/dev/null 2>&1 || : -if [ $1 -ge 1 ] ; then - /bin/systemctl try-restart dlm.service >/dev/null 2>&1 || : -fi +%systemd_postun_with_restart dlm.service %files %defattr(-,root,root,-) @@ -116,6 +108,9 @@ developing applications that use %{name}. %{_libdir}/pkgconfig/*.pc %changelog +* Wed Sep 05 2012 Václav Pavlín - 3.99.5-7 +- Scriptlets replaced with new systemd macros (#850093) + * Tue Aug 28 2012 David Teigland - 3.99.5-6 - only fedora requires kernel-modules-extra