SHA256
1
0
forked from pool/bluez

Accepting request 149406 from home:dimstar:branches:Base:System

- Unconditionally enable the systemd bluetooth service (actual
  activation of bluez is triggered by udev) (bnc#796671).
- Run spec-cleaner.

OBS-URL: https://build.opensuse.org/request/show/149406
OBS-URL: https://build.opensuse.org/package/show/Base:System/bluez?expand=0&rev=135
This commit is contained in:
Stefan Seyfried 2013-01-25 07:57:16 +00:00 committed by Git OBS Bridge
parent b82bd705f6
commit 67f48c3207
2 changed files with 47 additions and 88 deletions

View File

@ -1,3 +1,10 @@
-------------------------------------------------------------------
Mon Jan 21 11:16:34 UTC 2013 - dimstar@opensuse.org
- Unconditionally enable the systemd bluetooth service (actual
activation of bluez is triggered by udev) (bnc#796671).
- Run spec-cleaner.
------------------------------------------------------------------- -------------------------------------------------------------------
Fri Jan 11 14:38:03 UTC 2013 - crrodriguez@opensuse.org Fri Jan 11 14:38:03 UTC 2013 - crrodriguez@opensuse.org

View File

@ -18,32 +18,20 @@
Name: bluez Name: bluez
BuildRequires: dbus-1-devel >= 1.4
BuildRequires: flex BuildRequires: flex
BuildRequires: libcap-ng-devel BuildRequires: libcap-ng-devel
BuildRequires: pkgconfig(dbus-1) >= 1.4
%if 0%{?suse_version} > 1140 %if 0%{?suse_version} > 1140
BuildRequires: systemd BuildRequires: systemd
%{?systemd_requires} %{?systemd_requires}
%define has_systemd 1 %define has_systemd 1
%endif %endif
BuildRequires: alsa-devel
BuildRequires: automake
BuildRequires: check-devel
BuildRequires: glib2-devel >= 2.28
BuildRequires: libsndfile-devel
BuildRequires: libtool
BuildRequires: libudev-devel
BuildRequires: libusb-devel
BuildRequires: pkg-config
BuildRequires: readline-devel
BuildRequires: udev
BuildRequires: pkgconfig(libnl-1)
Url: http://www.bluez.org
Version: 4.101 Version: 4.101
Release: 0 Release: 0
Summary: Bluetooth Stack for Linux Summary: Bluetooth Stack for Linux
License: GPL-2.0+ License: GPL-2.0+
Group: Hardware/Mobile Group: Hardware/Mobile
Url: http://www.bluez.org
Source: bluez-%{version}.tar.bz2 Source: bluez-%{version}.tar.bz2
Source2: bluez-coldplug.init Source2: bluez-coldplug.init
Source3: bluetooth.sysconfig Source3: bluetooth.sysconfig
@ -52,13 +40,25 @@ Source6: README.SUSE
Source7: bluetooth.modprobe Source7: bluetooth.modprobe
# already fixed upstream # already fixed upstream
Patch0: 0001-network-fix-network-Connect-method-parameters.patch Patch0: 0001-network-fix-network-Connect-method-parameters.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: alsa-devel
BuildRequires: automake
BuildRequires: check-devel
BuildRequires: libsndfile-devel
BuildRequires: libtool
BuildRequires: libudev-devel
BuildRequires: libusb-devel
BuildRequires: pkg-config
BuildRequires: readline-devel
BuildRequires: udev
BuildRequires: pkgconfig(glib-2.0) >= 2.28
BuildRequires: pkgconfig(libnl-1)
Requires: libbluetooth3 = %{version}
Recommends: sbc
Provides: bluez-utils = 3.36 Provides: bluez-utils = 3.36
Obsoletes: bluez-utils <= 3.36 Obsoletes: bluez-utils <= 3.36
Provides: bluez-audio = 3.36 Provides: bluez-audio = 3.36
Obsoletes: bluez-audio <= 3.36 Obsoletes: bluez-audio <= 3.36
Requires: libbluetooth3 = %{version} BuildRoot: %{_tmppath}/%{name}-%{version}-build
Recommends: sbc
%if %( echo `rpm -q --queryformat %%{version} udev` ) < 144 %if %( echo `rpm -q --queryformat %%{version} udev` ) < 144
%define OLD_UDEV 1 %define OLD_UDEV 1
%else %else
@ -82,13 +82,6 @@ Recommends: sbc
%description %description
The Bluetooth stack for Linux. The Bluetooth stack for Linux.
Authors:
--------
Marcel Holtmann <marcel@holtmann.org>
and others, see AUTHORS
%package devel %package devel
Summary: Files needed for BlueZ development Summary: Files needed for BlueZ development
License: GPL-2.0+ License: GPL-2.0+
@ -99,13 +92,6 @@ Requires: libbluetooth3 = %{version}
Files needed to develop applications for the BlueZ Bluetooth protocol Files needed to develop applications for the BlueZ Bluetooth protocol
stack. stack.
Authors:
--------
Marcel Holtmann <marcel@holtmann.org>
and others, see AUTHORS
%package -n libbluetooth3 %package -n libbluetooth3
Summary: Bluetooth Libraries Summary: Bluetooth Libraries
License: GPL-2.0+ License: GPL-2.0+
@ -116,13 +102,6 @@ Obsoletes: bluez-libs <= 3.36
%description -n libbluetooth3 %description -n libbluetooth3
Bluetooth protocol stack libraries. Bluetooth protocol stack libraries.
Authors:
--------
Marcel Holtmann <marcel@holtmann.org>
and others, see AUTHORS in the documentation of the "bluez" package.
%package cups %package cups
Summary: CUPS Driver for Bluetooth Printers Summary: CUPS Driver for Bluetooth Printers
License: GPL-2.0+ License: GPL-2.0+
@ -133,13 +112,6 @@ Requires: libbluetooth3 = %{version}
Contains the files required by CUPS for printing to Bluetooth-connected Contains the files required by CUPS for printing to Bluetooth-connected
printers. printers.
Authors:
--------
Marcel Holtmann <marcel@holtmann.org>
and others, see AUTHORS in the documentation of the "bluez" package.
%package test %package test
Summary: Tools for testing of various Bluetooth-functions Summary: Tools for testing of various Bluetooth-functions
License: GPL-2.0+ and MIT License: GPL-2.0+ and MIT
@ -152,32 +124,18 @@ Requires: python-gobject2
Contains a few tools for testing various bluetooth functions. The Contains a few tools for testing various bluetooth functions. The
BLUETOOTH trademarks are owned by Bluetooth SIG, Inc., U.S.A. BLUETOOTH trademarks are owned by Bluetooth SIG, Inc., U.S.A.
Authors:
--------
Marcel Holtmann <marcel@holtmann.org>
and others, see AUTHORS in the documentation of the "bluez" package.
%package alsa %package alsa
Summary: Bluetooth Sound Support Summary: Bluetooth Sound Support
License: GPL-2.0+ License: GPL-2.0+
Group: Productivity/Multimedia/Sound/Utilities Group: Productivity/Multimedia/Sound/Utilities
Requires: libbluetooth3 = %{version} Requires: libbluetooth3 = %{version}
Provides: bluez-audio:%_libdir/alsa-lib/libasound_module_pcm_bluetooth.so Provides: bluez-audio:%{_libdir}/alsa-lib/libasound_module_pcm_bluetooth.so
%description alsa %description alsa
The package contains libraries for using bluetooth audio services. The package contains libraries for using bluetooth audio services.
The BLUETOOTH trademarks are owned by Bluetooth SIG, Inc., USA. The BLUETOOTH trademarks are owned by Bluetooth SIG, Inc., USA.
Authors:
--------
Marcel Holtmann <marcel@holtmann.org>
and others, see AUTHORS in the documentation of the "bluez" package.
%package compat %package compat
Summary: Bluetooth Stack for Linux Summary: Bluetooth Stack for Linux
License: GPL-2.0+ License: GPL-2.0+
@ -188,17 +146,10 @@ Requires: libbluetooth3 = %{version}
The Bluetooth stack for Linux. This package contains older and partly The Bluetooth stack for Linux. This package contains older and partly
deprecated binaries that might still be needed for compatibility. deprecated binaries that might still be needed for compatibility.
Authors:
--------
Marcel Holtmann <marcel@holtmann.org>
and others, see AUTHORS
%prep %prep
%setup -q %setup -q
%patch0 -p1 %patch0 -p1
cp %{S:6} . cp %{SOURCE6} .
mkdir dbus-apis mkdir dbus-apis
cp -a doc/*.txt dbus-apis/ cp -a doc/*.txt dbus-apis/
@ -227,7 +178,7 @@ autoreconf -fiv
make %{?_smp_mflags} all V=1 make %{?_smp_mflags} all V=1
%install %install
make DESTDIR=$RPM_BUILD_ROOT install %make_install
# bluez-test # bluez-test
cd test cd test
install --mode=0755 \ install --mode=0755 \
@ -244,16 +195,16 @@ install --mode=0755 \
test-serial \ test-serial \
test-service \ test-service \
test-telephony \ test-telephony \
$RPM_BUILD_ROOT/%{_bindir}/ %{buildroot}/%{_bindir}/
cd .. cd ..
rm -v $RPM_BUILD_ROOT/%{_libdir}/*.la rm -v %{buildroot}/%{_libdir}/*.la
rm -rvf $RPM_BUILD_ROOT/%{_libdir}/gstreamer-* rm -rvf %{buildroot}/%{_libdir}/gstreamer-*
rm -v $RPM_BUILD_ROOT/%{_libdir}/alsa-lib/*.la rm -v %{buildroot}/%{_libdir}/alsa-lib/*.la
%if ! 0%{?has_systemd} %if ! 0%{?has_systemd}
install --mode=0755 -D %{S:2} $RPM_BUILD_ROOT/%{_sysconfdir}/init.d/bluez-coldplug install --mode=0755 -D %{SOURCE2} %{buildroot}/%{_sysconfdir}/init.d/bluez-coldplug
%endif %endif
install --mode=0644 -D %{S:3} $RPM_BUILD_ROOT/var/adm/fillup-templates/sysconfig.bluetooth install --mode=0644 -D %{SOURCE3} %{buildroot}%{_localstatedir}/adm/fillup-templates/sysconfig.bluetooth
install --mode=0644 -D %{S:7} $RPM_BUILD_ROOT/%{_sysconfdir}/modprobe.d/50-bluetooth.conf install --mode=0644 -D %{SOURCE7} %{buildroot}/%{_sysconfdir}/modprobe.d/50-bluetooth.conf
# In openSUSE 11.3 there is upstream compliant CUPS 1.4 # In openSUSE 11.3 there is upstream compliant CUPS 1.4
# which means to have a fixed "/usr/lib/cups/" directory # which means to have a fixed "/usr/lib/cups/" directory
# on all platforms (see Novell/Suse Bugzilla bnc#575544): # on all platforms (see Novell/Suse Bugzilla bnc#575544):
@ -264,13 +215,13 @@ then if test -e %{buildroot}%{_libdir}/cups/backend/bluetooth
fi fi
fi fi
# no idea why this is suddenly necessary... # no idea why this is suddenly necessary...
install --mode 0755 -d $RPM_BUILD_ROOT/var/lib/bluetooth install --mode 0755 -d %{buildroot}%{_localstatedir}/lib/bluetooth
%check %check
make check make check
%clean %clean
rm -rf $RPM_BUILD_ROOT rm -rf %{buildroot}
%pre %pre
%if 0%{?has_systemd} %if 0%{?has_systemd}
@ -281,7 +232,10 @@ rm -rf $RPM_BUILD_ROOT
# todo: check if this is still obeyed / needed with systemd # todo: check if this is still obeyed / needed with systemd
%{fillup_only -n bluetooth} %{fillup_only -n bluetooth}
%if 0%{?has_systemd} %if 0%{?has_systemd}
%service_add_post bluetooth.service # We need the bluez systemd service enabled at any time. It won't start up
# on it's own, as it is triggered by udev in the end (bnc#796671)
/bin/systemctl enable bluetooth.service 2>&1 || :
/bin/systemctl daemon-reload >/dev/null 2>&1 || :
%else %else
%{insserv_force_if_yast bluez-coldplug} %{insserv_force_if_yast bluez-coldplug}
%endif %endif
@ -321,11 +275,9 @@ rm -rf $RPM_BUILD_ROOT
#%{_sbindir}/hid2hci #%{_sbindir}/hid2hci
%{_sbindir}/bccmd %{_sbindir}/bccmd
%if 0%{NEW_UDEV} %if 0%{NEW_UDEV}
%dir /usr/lib/udev %{_prefix}/lib/udev/
/usr/lib/udev/*
%else %else
%dir /lib/udev /lib/udev/
/lib/udev/*
%endif %endif
%if 0%{OLD_UDEV} %if 0%{OLD_UDEV}
%dir %{_sysconfdir}/udev/rules.d %dir %{_sysconfdir}/udev/rules.d
@ -347,9 +299,9 @@ rm -rf $RPM_BUILD_ROOT
%dir %{_sysconfdir}/bluetooth %dir %{_sysconfdir}/bluetooth
%config(noreplace) %{_sysconfdir}/bluetooth/main.conf %config(noreplace) %{_sysconfdir}/bluetooth/main.conf
%config(noreplace) %{_sysconfdir}/bluetooth/rfcomm.conf %config(noreplace) %{_sysconfdir}/bluetooth/rfcomm.conf
/var/adm/fillup-templates/sysconfig.bluetooth %{_localstatedir}/adm/fillup-templates/sysconfig.bluetooth
%config %{_sysconfdir}/dbus-1/system.d/bluetooth.conf %config %{_sysconfdir}/dbus-1/system.d/bluetooth.conf
%dir /var/lib/bluetooth %dir %{_localstatedir}/lib/bluetooth
%dir %{_sysconfdir}/modprobe.d %dir %{_sysconfdir}/modprobe.d
%config(noreplace) %{_sysconfdir}/modprobe.d/50-bluetooth.conf %config(noreplace) %{_sysconfdir}/modprobe.d/50-bluetooth.conf
%if 0%{?has_systemd} %if 0%{?has_systemd}
@ -361,7 +313,7 @@ rm -rf $RPM_BUILD_ROOT
%files devel %files devel
%defattr(-, root, root) %defattr(-, root, root)
/usr/include/bluetooth %{_includedir}/bluetooth
%{_libdir}/libbluetooth.so %{_libdir}/libbluetooth.so
%{_libdir}/pkgconfig/bluez.pc %{_libdir}/pkgconfig/bluez.pc
@ -397,8 +349,8 @@ rm -rf $RPM_BUILD_ROOT
%files alsa %files alsa
%defattr(-,root,root) %defattr(-,root,root)
%dir /usr/share/alsa %dir %{_datadir}/alsa
%config /usr/share/alsa/bluetooth.conf %config %{_datadir}/alsa/bluetooth.conf
%{_libdir}/alsa-lib/*.so %{_libdir}/alsa-lib/*.so
%files compat %files compat