From eaa41826a7a2c4e20f76c79ec56fa3b79ea45cd5fc32d15eb2421efc29f239f0 Mon Sep 17 00:00:00 2001 From: Vincent Untz Date: Mon, 27 Feb 2012 23:11:29 +0000 Subject: [PATCH] Accepting request 107164 from home:vuntz:branches:GNOME:Factory Fix systemd-related packaging OBS-URL: https://build.opensuse.org/request/show/107164 OBS-URL: https://build.opensuse.org/package/show/GNOME:Factory/accountsservice?expand=0&rev=21 --- accountsservice.changes | 10 ++++++++++ accountsservice.spec | 19 +++++++++++++++---- 2 files changed, 25 insertions(+), 4 deletions(-) diff --git a/accountsservice.changes b/accountsservice.changes index c96c23d..7ad1bf4 100644 --- a/accountsservice.changes +++ b/accountsservice.changes @@ -1,3 +1,13 @@ +------------------------------------------------------------------- +Mon Feb 27 13:21:43 UTC 2012 - vuntz@opensuse.org + +- Fix systemd-related packaging: + + Use %{?systemd_requires}. + + Call %service_{add,del}_* macros in scriptlets for + accounts-daemon.service. +- Remove xz BuildRequires now that it comes for free in the build + system. + ------------------------------------------------------------------- Thu Dec 8 08:55:14 UTC 2011 - dimstar@opensuse.org diff --git a/accountsservice.spec b/accountsservice.spec index 840a3c8..cd846eb 100644 --- a/accountsservice.spec +++ b/accountsservice.spec @@ -1,7 +1,7 @@ # # spec file for package accountsservice # -# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -31,14 +31,13 @@ Patch0: accountsservice-sysconfig.patch BuildRequires: gnome-common BuildRequires: gobject-introspection-devel BuildRequires: intltool -# Only needed because we don't (and won't) support building xz tarballs by default... See bnc#697467 -BuildRequires: xz BuildRequires: pkgconfig(dbus-glib-1) BuildRequires: pkgconfig(glib-2.0) BuildRequires: pkgconfig(polkit-gobject-1) BuildRequires: pkgconfig(systemd) Recommends: %{name}-lang BuildRoot: %{_tmppath}/%{name}-%{version}-build +%{?systemd_requires} %description The accountsservice server provides a set of D-Bus interfaces for @@ -100,6 +99,18 @@ rm -f %{buildroot}%{_libdir}/*.la %clean rm -rf %{buildroot} +%pre +%service_add_pre accounts-daemon.service + +%post +%service_add_post accounts-daemon.service + +%preun +%service_del_preun accounts-daemon.service + +%postun +%service_del_postun accounts-daemon.service + %post -n libaccountsservice0 -p /sbin/ldconfig %postun -n libaccountsservice0 -p /sbin/ldconfig @@ -107,7 +118,7 @@ rm -rf %{buildroot} %files %defattr(-,root,root,-) %doc AUTHORS COPYING NEWS README -/lib/systemd/system/accounts-daemon.service +%{_unitdir}/accounts-daemon.service %{_sysconfdir}/dbus-1/system.d/org.freedesktop.Accounts.conf %{_libexecdir}/accounts-daemon %{_datadir}/dbus-1/interfaces/org.freedesktop.Accounts.xml