Updated RPM scriptlets with latest systemd-rpm macros

Resolves: #850246
This commit is contained in:
Jan Safranek 2012-08-27 14:11:33 +02:00
parent 7fee532401
commit d21197474f

View File

@ -4,7 +4,7 @@
Summary: IPMI (Intelligent Platform Management Interface) library and tools Summary: IPMI (Intelligent Platform Management Interface) library and tools
Name: OpenIPMI Name: OpenIPMI
Version: 2.0.19 Version: 2.0.19
Release: 1%{?dist} Release: 2%{?dist}
License: LGPLv2+ and GPLv2+ or BSD License: LGPLv2+ and GPLv2+ or BSD
Group: System Environment/Base Group: System Environment/Base
URL: http://sourceforge.net/projects/openipmi/ URL: http://sourceforge.net/projects/openipmi/
@ -95,24 +95,13 @@ install -m 644 %SOURCE3 ${RPM_BUILD_ROOT}%{_unitdir}/ipmi.service
rm ${RPM_BUILD_ROOT}/%{_mandir}/man1/openipmigui.1 rm ${RPM_BUILD_ROOT}/%{_mandir}/man1/openipmigui.1
%post %post
if [ $1 -eq 1 ] ; then %systemd_post ipmi.service
# Initial installation
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
fi
%preun %preun
if [ $1 -eq 0 ] ; then %systemd_preun ipmi.service
# Package removal, not upgrade
/bin/systemctl --no-reload disable ipmi.service > /dev/null 2>&1 || :
/bin/systemctl stop ipmi.service > /dev/null 2>&1 || :
fi
%postun %postun
/bin/systemctl daemon-reload >/dev/null 2>&1 || : %systemd_postun_with_restart ipmi.service
if [ $1 -ge 1 ] ; then
# Package upgrade, not uninstall
/bin/systemctl try-restart ipmi.service >/dev/null 2>&1 || :
fi
%post libs -p /sbin/ldconfig %post libs -p /sbin/ldconfig
@ -177,6 +166,9 @@ rm -rf $RPM_BUILD_ROOT
%{_libdir}/pkgconfig/*.pc %{_libdir}/pkgconfig/*.pc
%changelog %changelog
* Mon Aug 27 2012 Jan Safranek <jsafrane@redhat.com> - 2.0.19-2
- Updated RPM scriptlets with latest systemd-rpm macros (#850246)
* Wed Aug 8 2012 Jan Safranek <jsafrane@redhat.com> - 2.0.19-1 * Wed Aug 8 2012 Jan Safranek <jsafrane@redhat.com> - 2.0.19-1
- Update to 2.0.19 - Update to 2.0.19