[system-setup-keyboard] Update to 0.8.6 which adds systemd support
drago01
drago01 at fedoraproject.org
Sat Aug 28 09:00:27 UTC 2010
commit 1e598fe774923f8ac6c3f0458125f1ba04762f85
Author: Adel Gadllah <adel.gadllah at gmail.com>
Date: Sat Aug 28 10:59:31 2010 +0200
Update to 0.8.6 which adds systemd support
.gitignore | 1 +
sources | 2 +-
system-setup-keyboard.spec | 35 +++++++++++++++++++++++++++++++----
3 files changed, 33 insertions(+), 5 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 368128c..0e4f360 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1 +1,2 @@
system-setup-keyboard-0.8.5.tar.bz2
+/system-setup-keyboard-0.8.6.tar.bz2
diff --git a/sources b/sources
index 0f1f8cf..2e9574e 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-cb2fb76f9f99742097584e1effbc7445 system-setup-keyboard-0.8.5.tar.bz2
+248cecfcfb2b339be8babe1d44ba037f system-setup-keyboard-0.8.6.tar.bz2
diff --git a/system-setup-keyboard.spec b/system-setup-keyboard.spec
index de32c07..841bced 100644
--- a/system-setup-keyboard.spec
+++ b/system-setup-keyboard.spec
@@ -1,6 +1,6 @@
Name: system-setup-keyboard
-Version: 0.8.5
-Release: 2%{?dist}
+Version: 0.8.6
+Release: 1%{?dist}
Summary: xorg.conf keyboard layout callout
Group: Applications/System
@@ -13,7 +13,7 @@ BuildRequires: glib2-devel
BuildRequires: system-config-keyboard
Requires: xorg-x11-server-Xorg >= 1.7.99
-Requires: upstart
+Requires: systemd
Conflicts: xorg-x11-server-Xorg < 1.6.0-7
Provides: fedora-setup-keyboard = %{version}-%{release}
@@ -30,7 +30,6 @@ snippet.
%build
make CFLAGS="%{optflags}" %{?_smp_mflags}
-
%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT
@@ -41,17 +40,45 @@ touch $RPM_BUILD_ROOT/%{_sysconfdir}/X11/xorg.conf.d/00-system-setup-keyboard.co
%clean
rm -rf $RPM_BUILD_ROOT
+%post
+if [ $1 -eq 1 ]; then
+ # Enable (but don´t start) the units by default
+ /bin/systemctl enable system-setup-keyboard.service >/dev/null 2>&1 || :
+fi
+
+%preun
+if [ $1 -eq 0 ]; then
+ # Disable and stop the units
+ /bin/systemctl disable system-setup-keyboard.service >/dev/null 2>&1 || :
+ /bin/systemctl stop system-setup-keyboard.service >/dev/null 2>&1 || :
+fi
+
+%postun
+if [ $1 -ge 1 ] ; then
+ # On upgrade, reload init system configuration if we changed unit files
+ /bin/systemctl daemon-reload >/dev/null 2>&1 || :
+ # On upgrade, restart the daemon
+ /bin/systemctl try-restart system-setup-keyboard.service >/dev/null 2>&1 || :
+fi
%files
%defattr(-,root,root,-)
%{_bindir}/%{name}
%{_sysconfdir}/init/%{name}.conf
%{_mandir}/man1/system-setup-keyboard.1*
+/lib/systemd/system/system-setup-keyboard.service
+# Own directories to avoid hard requirement on a upstart
+# can be removed once we decided to stay with systemd
+%dir %{_sysconfdir}/init/
+
%ghost %{_sysconfdir}/X11/xorg.conf.d/00-system-setup-keyboard.conf
%doc COPYING
%changelog
+* Sat Aug 28 2010 Adel Gadllah <adel.gadllah at gmail.com> 0.8.6-1
+- 0.8.6 release - systemd support
+
* Mon Jun 21 2010 Peter Hutterer <peter.hutterer at redhat.com> 0.8.5-2
- Update description, we don't use HAL anymore after all.
- %ghost the generated 00-system-setup-keyboard.conf file.
More information about the scm-commits
mailing list