[systemd] add triggers to fix the disappearing default.target on upgrades from f16

Michal Schmidt michich at fedoraproject.org
Tue Mar 27 22:15:01 UTC 2012


commit 3d6d8951ea5f848f2ada00b3b2982ae47504beda
Author: Michal Schmidt <mschmidt at redhat.com>
Date:   Wed Mar 28 00:07:38 2012 +0200

    add triggers to fix the disappearing default.target on upgrades from f16
    
    Add triggers from Bill Nottingham to correct the damage done by
    the obsoleted systemd-units's preun scriptlet (#807457).

 systemd.spec |   17 ++++++++++++++++-
 1 files changed, 16 insertions(+), 1 deletions(-)
---
diff --git a/systemd.spec b/systemd.spec
index 27ef716..f69e3d1 100644
--- a/systemd.spec
+++ b/systemd.spec
@@ -3,7 +3,7 @@
 Name:           systemd
 Url:            http://www.freedesktop.org/wiki/Software/systemd
 Version:        44
-Release:        3%{?gitcommit:.git%{gitcommit}}%{?dist}
+Release:        4%{?gitcommit:.git%{gitcommit}}%{?dist}
 License:        GPLv2+
 Group:          System Environment/Base
 Summary:        A System and Service Manager
@@ -253,6 +253,17 @@ if [ $1 -eq 0 ] ; then
         /bin/rm -f /etc/systemd/system/default.target >/dev/null 2>&1 || :
 fi
 
+%triggerun -- systemd-units < 38-5
+mv /etc/systemd/system/default.target /etc/systemd/system/default.target.save >/dev/null 2>&1 || :
+
+%triggerpostun -- systemd-units < 38-5
+mv /etc/systemd/system/default.target.save /etc/systemd/system/default.target >/dev/null 2>&1
+/bin/systemctl enable \
+        getty at .service \
+        remote-fs.target \
+        systemd-readahead-replay.service \
+        systemd-readahead-collect.service
+
 %files
 %doc %{_docdir}/systemd
 %dir %{_sysconfdir}/systemd
@@ -384,6 +395,10 @@ fi
 %{_bindir}/systemd-analyze
 
 %changelog
+* Wed Mar 28 2012 Michal Schmidt <mschmidt at redhat.com> - 44-4
+- Add triggers from Bill Nottingham to correct the damage done by
+  the obsoleted systemd-units's preun scriptlet (#807457).
+
 * Mon Mar 26 2012 Dennis Gilmore <dennis at ausil.us> - 44-3
 - apply patch from upstream so we can build systemd on arm and ppc
 - and likely the rest of the secondary arches


More information about the scm-commits mailing list