From b3f882a5de95cfe41b68db37c6fdb3927e2e2c312e0bb399344ffb2eb90d748d Mon Sep 17 00:00:00 2001 From: Andreas Jaeger Date: Mon, 5 Nov 2012 20:48:35 +0000 Subject: [PATCH] Accepting request 139864 from home:elvigia:branches:Base:System - bluez-coldplug init script is forced but it s not needed when using systemd with dbus activation. OBS-URL: https://build.opensuse.org/request/show/139864 OBS-URL: https://build.opensuse.org/package/show/Base:System/bluez?expand=0&rev=128 --- bluez.changes | 6 ++++++ bluez.spec | 15 +++++++++++---- 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/bluez.changes b/bluez.changes index 64d469a..1d9a441 100644 --- a/bluez.changes +++ b/bluez.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Wed Oct 31 14:50:01 UTC 2012 - crrodriguez@opensuse.org + +- bluez-coldplug init script is forced but it s not needed + when using systemd with dbus activation. + ------------------------------------------------------------------- Wed Oct 17 08:52:03 UTC 2012 - fcrozat@suse.com diff --git a/bluez.spec b/bluez.spec index 7f08fb0..e9acc27 100644 --- a/bluez.spec +++ b/bluez.spec @@ -147,7 +147,7 @@ Authors: %package test Summary: Tools for testing of various Bluetooth-functions -License: GPL-2.0+ ; MIT +License: GPL-2.0+ and MIT Group: Development/Tools/Debuggers Requires: dbus-1-python Requires: libbluetooth3 = %{version} @@ -295,7 +295,9 @@ cd .. rm -v $RPM_BUILD_ROOT/%{_libdir}/*.la rm -rvf $RPM_BUILD_ROOT/%{_libdir}/gstreamer-* rm -v $RPM_BUILD_ROOT/%{_libdir}/alsa-lib/*.la +%if ! 0%{?has_systemd} install --mode=0755 -D %{S:2} $RPM_BUILD_ROOT/%{_sysconfdir}/init.d/bluez-coldplug +%endif install --mode=0644 -D %{S:3} $RPM_BUILD_ROOT/var/adm/fillup-templates/sysconfig.bluetooth install --mode=0644 -D %{S:7} $RPM_BUILD_ROOT/%{_sysconfdir}/modprobe.d/50-bluetooth.conf # In openSUSE 11.3 there is upstream compliant CUPS 1.4 @@ -323,21 +325,25 @@ rm -rf $RPM_BUILD_ROOT %post %{fillup_only -n bluetooth} -%{insserv_force_if_yast bluez-coldplug} %if 0%{?has_systemd} %service_add_post bluetooth.service +%else +%{insserv_force_if_yast bluez-coldplug} %endif %preun -%stop_on_removal bluez-coldplug %if 0%{?has_systemd} %service_del_preun bluetooth.service +%else +%stop_on_removal bluez-coldplug %endif %postun %{insserv_cleanup} %if 0%{?has_systemd} %service_del_postun bluetooth.service +%else +%{insserv_cleanup} %endif %post -n libsbc0 -p /sbin/ldconfig @@ -374,7 +380,6 @@ rm -rf $RPM_BUILD_ROOT %dir %{_sysconfdir}/udev/rules.d %config %{_sysconfdir}/udev/rules.d/* %endif -%{_sysconfdir}/init.d/bluez-coldplug %doc %{_mandir}/man8/hciattach.8.gz %doc %{_mandir}/man8/hciconfig.8.gz %doc %{_mandir}/man8/bluetoothd.8.gz @@ -398,6 +403,8 @@ rm -rf $RPM_BUILD_ROOT %config(noreplace) %{_sysconfdir}/modprobe.d/50-bluetooth.conf %if 0%{?has_systemd} %{_unitdir}/bluetooth.service +%else +%{_sysconfdir}/init.d/bluez-coldplug %endif %{_datadir}/dbus-1/system-services/org.bluez.service