forked from pool/bluez
Marcus Meissner
8872b8764e
- Add changelog entry for older change so factory-auto wont reject this. - This requests removes sbc building and packaging from bluez. SBC recently gets its own package and sources are even stripped out ot Bluez in current git master (future 5.0). On top of that current bluez-devel package conflicts with sbc-devel. Note: This change may broke packages which use sbc from bluez-devel as new sbc-devel package use different include path. This change is required to properly build PulseAudio 3.0 OBS-URL: https://build.opensuse.org/request/show/148076 OBS-URL: https://build.opensuse.org/package/show/Base:System/bluez?expand=0&rev=131
418 lines
10 KiB
RPMSpec
418 lines
10 KiB
RPMSpec
#
|
|
# spec file for package bluez
|
|
#
|
|
# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
|
# Copyright (c) 2010-2012 B1 Systems GmbH, Vohburg, Germany
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
Name: bluez
|
|
BuildRequires: dbus-1-devel >= 1.4
|
|
BuildRequires: flex
|
|
BuildRequires: libcap-ng-devel
|
|
%if 0%{?suse_version} > 1140
|
|
BuildRequires: systemd
|
|
%{?systemd_requires}
|
|
%define has_systemd 1
|
|
%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
|
|
Release: 0
|
|
Summary: Bluetooth Stack for Linux
|
|
License: GPL-2.0+
|
|
Group: Hardware/Mobile
|
|
Source: bluez-%{version}.tar.bz2
|
|
# bug in the 4.100 tarball: missing file...
|
|
Source1: org.bluez.service
|
|
Source2: bluez-coldplug.init
|
|
Source3: bluetooth.sysconfig
|
|
Source5: baselibs.conf
|
|
Source6: README.SUSE
|
|
Source7: bluetooth.modprobe
|
|
# already fixed upstream
|
|
Patch0: 0001-network-fix-network-Connect-method-parameters.patch
|
|
# TODO: check for obsoletion
|
|
Patch9: 001-remove-rule-dell-mouse.patch
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
Provides: bluez-utils = 3.36
|
|
Obsoletes: bluez-utils <= 3.36
|
|
Provides: bluez-audio = 3.36
|
|
Obsoletes: bluez-audio <= 3.36
|
|
Requires: libbluetooth3 = %{version}
|
|
Recommends: sbc
|
|
%if %( echo `rpm -q --queryformat %%{version} udev` ) < 144
|
|
%define OLD_UDEV 1
|
|
%else
|
|
%define OLD_UDEV 0
|
|
%if %( echo `rpm -q --queryformat %%{version} udev` ) > 190
|
|
%define NEW_UDEV 1
|
|
%else
|
|
%define NEW_UDEV 0
|
|
%endif
|
|
%endif
|
|
|
|
# In openSUSE 11.3 there is upstream compliant CUPS 1.4
|
|
# which means to have a fixed "/usr/lib/cups/" directory
|
|
# on all platforms (see Novell/Suse Bugzilla bnc#575544):
|
|
%if 0%{?suse_version} > 1120
|
|
%define cups_lib_dir %{_prefix}/lib/cups
|
|
%else
|
|
%define cups_lib_dir %{_libdir}/cups
|
|
%endif
|
|
|
|
%description
|
|
The Bluetooth stack for Linux.
|
|
|
|
|
|
|
|
Authors:
|
|
--------
|
|
Marcel Holtmann <marcel@holtmann.org>
|
|
and others, see AUTHORS
|
|
|
|
%package devel
|
|
Summary: Files needed for BlueZ development
|
|
License: GPL-2.0+
|
|
Group: Development/Sources
|
|
Requires: libbluetooth3 = %{version}
|
|
|
|
%description devel
|
|
Files needed to develop applications for the BlueZ Bluetooth protocol
|
|
stack.
|
|
|
|
|
|
|
|
Authors:
|
|
--------
|
|
Marcel Holtmann <marcel@holtmann.org>
|
|
and others, see AUTHORS
|
|
|
|
%package -n libbluetooth3
|
|
Summary: Bluetooth Libraries
|
|
License: GPL-2.0+
|
|
Group: Hardware/Mobile
|
|
Provides: bluez-libs = 3.36
|
|
Obsoletes: bluez-libs <= 3.36
|
|
|
|
%description -n libbluetooth3
|
|
Bluetooth protocol stack libraries.
|
|
|
|
|
|
|
|
Authors:
|
|
--------
|
|
Marcel Holtmann <marcel@holtmann.org>
|
|
and others, see AUTHORS in the documentation of the "bluez" package.
|
|
|
|
%package cups
|
|
Summary: CUPS Driver for Bluetooth Printers
|
|
License: GPL-2.0+
|
|
Group: Hardware/Printing
|
|
Requires: libbluetooth3 = %{version}
|
|
|
|
%description cups
|
|
Contains the files required by CUPS for printing to Bluetooth-connected
|
|
printers.
|
|
|
|
|
|
|
|
Authors:
|
|
--------
|
|
Marcel Holtmann <marcel@holtmann.org>
|
|
and others, see AUTHORS in the documentation of the "bluez" package.
|
|
|
|
%package test
|
|
Summary: Tools for testing of various Bluetooth-functions
|
|
License: GPL-2.0+ and MIT
|
|
Group: Development/Tools/Debuggers
|
|
Requires: dbus-1-python
|
|
Requires: libbluetooth3 = %{version}
|
|
Requires: python-gobject2
|
|
|
|
%description test
|
|
Contains a few tools for testing various bluetooth functions. The
|
|
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
|
|
Summary: Bluetooth Sound Support
|
|
License: GPL-2.0+
|
|
Group: Productivity/Multimedia/Sound/Utilities
|
|
Requires: libbluetooth3 = %{version}
|
|
Provides: bluez-audio:%_libdir/alsa-lib/libasound_module_pcm_bluetooth.so
|
|
|
|
%description alsa
|
|
The package contains libraries for using bluetooth audio services.
|
|
|
|
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
|
|
Summary: Bluetooth Stack for Linux
|
|
License: GPL-2.0+
|
|
Group: Hardware/Mobile
|
|
Requires: libbluetooth3 = %{version}
|
|
|
|
%description compat
|
|
The Bluetooth stack for Linux. This package contains older and partly
|
|
deprecated binaries that might still be needed for compatibility.
|
|
|
|
|
|
|
|
Authors:
|
|
--------
|
|
Marcel Holtmann <marcel@holtmann.org>
|
|
and others, see AUTHORS
|
|
|
|
%prep
|
|
%setup -q
|
|
%patch0 -p1
|
|
# disabled the patch because it does no longer cleanly apply and the rule has
|
|
# changed significantly anyway. I'll keep it until i get confirmation in bugzilla.
|
|
##%%patch9 -p1
|
|
cp %{S:6} .
|
|
mkdir dbus-apis
|
|
cp -a doc/*.txt dbus-apis/
|
|
|
|
%build
|
|
autoreconf -fiv
|
|
%configure --with-pic \
|
|
%if 0%{?has_systemd}
|
|
--with-systemdunitdir=%{_unitdir} \
|
|
%endif
|
|
--libexecdir=/lib \
|
|
--enable-gstreamer \
|
|
--enable-alsa \
|
|
--enable-usb \
|
|
--enable-tools \
|
|
--enable-bccmd \
|
|
--enable-hid2hci \
|
|
--enable-dfutool \
|
|
--enable-cups \
|
|
--enable-test \
|
|
--enable-pand \
|
|
--enable-dund \
|
|
--enable-wiimote \
|
|
--enable-datafiles \
|
|
--enable-pcmcia
|
|
|
|
make %{?_smp_mflags} all V=1
|
|
|
|
%install
|
|
make DESTDIR=$RPM_BUILD_ROOT install
|
|
# bluez-test
|
|
cd test
|
|
install --mode=0755 \
|
|
simple-agent \
|
|
simple-service \
|
|
list-devices \
|
|
test-audio \
|
|
test-adapter \
|
|
test-device \
|
|
test-discovery \
|
|
test-input \
|
|
test-manager \
|
|
test-network \
|
|
test-serial \
|
|
test-service \
|
|
test-telephony \
|
|
$RPM_BUILD_ROOT/%{_bindir}/
|
|
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
|
|
# which means to have a fixed "/usr/lib/cups/" directory
|
|
# on all platforms (see Novell/Suse Bugzilla bnc#575544):
|
|
if ! test -e %{buildroot}%{cups_lib_dir}/backend/bluetooth
|
|
then if test -e %{buildroot}%{_libdir}/cups/backend/bluetooth
|
|
then mkdir -p %{buildroot}%{cups_lib_dir}/backend
|
|
mv %{buildroot}%{_libdir}/cups/backend/bluetooth %{buildroot}%{cups_lib_dir}/backend/bluetooth
|
|
fi
|
|
fi
|
|
# no idea why this is suddenly necessary...
|
|
install --mode 0755 -d $RPM_BUILD_ROOT/var/lib/bluetooth
|
|
|
|
%check
|
|
make check
|
|
|
|
%clean
|
|
rm -rf $RPM_BUILD_ROOT
|
|
|
|
%pre
|
|
%if 0%{?has_systemd}
|
|
%service_add_pre bluetooth.service
|
|
%endif
|
|
|
|
%post
|
|
%{fillup_only -n bluetooth}
|
|
%if 0%{?has_systemd}
|
|
%service_add_post bluetooth.service
|
|
%else
|
|
%{insserv_force_if_yast bluez-coldplug}
|
|
%endif
|
|
|
|
%preun
|
|
%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 libbluetooth3 -p /sbin/ldconfig
|
|
|
|
%postun -n libbluetooth3 -p /sbin/ldconfig
|
|
|
|
%files
|
|
%defattr(-, root, root)
|
|
%doc AUTHORS COPYING ChangeLog README README.SUSE dbus-apis
|
|
%{_bindir}/hcitool
|
|
%{_bindir}/l2ping
|
|
%{_bindir}/rfcomm
|
|
%{_bindir}/sdptool
|
|
%{_bindir}/ciptool
|
|
%{_bindir}/dfutool
|
|
%{_bindir}/gatttool
|
|
%{_sbindir}/hciattach
|
|
%{_sbindir}/hciconfig
|
|
%{_sbindir}/bluetoothd
|
|
#%{_sbindir}/hid2hci
|
|
%{_sbindir}/bccmd
|
|
%if 0%{NEW_UDEV}
|
|
%dir /usr/lib/udev
|
|
/usr/lib/udev/*
|
|
%else
|
|
%dir /lib/udev
|
|
/lib/udev/*
|
|
%endif
|
|
%if 0%{OLD_UDEV}
|
|
%dir %{_sysconfdir}/udev/rules.d
|
|
%config %{_sysconfdir}/udev/rules.d/*
|
|
%endif
|
|
%doc %{_mandir}/man8/hciattach.8.gz
|
|
%doc %{_mandir}/man8/hciconfig.8.gz
|
|
%doc %{_mandir}/man8/bluetoothd.8.gz
|
|
%doc %{_mandir}/man8/hid2hci.8.gz
|
|
%doc %{_mandir}/man8/bccmd.8.gz
|
|
%doc %{_mandir}/man8/l2ping.8.gz
|
|
%doc %{_mandir}/man1/hcitool.1.gz
|
|
%doc %{_mandir}/man1/sdptool.1.gz
|
|
%doc %{_mandir}/man1/ciptool.1.gz
|
|
%doc %{_mandir}/man1/rfcomm.1.gz
|
|
%doc %{_mandir}/man1/dfutool.1.gz
|
|
%doc %{_mandir}/man1/hciemu.1.gz
|
|
%doc %{_mandir}/man1/rctest.1.gz
|
|
%dir %{_sysconfdir}/bluetooth
|
|
%config(noreplace) %{_sysconfdir}/bluetooth/main.conf
|
|
%config(noreplace) %{_sysconfdir}/bluetooth/rfcomm.conf
|
|
/var/adm/fillup-templates/sysconfig.bluetooth
|
|
%config %{_sysconfdir}/dbus-1/system.d/bluetooth.conf
|
|
%dir /var/lib/bluetooth
|
|
%dir %{_sysconfdir}/modprobe.d
|
|
%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
|
|
|
|
%files devel
|
|
%defattr(-, root, root)
|
|
/usr/include/bluetooth
|
|
%{_libdir}/libbluetooth.so
|
|
%{_libdir}/pkgconfig/bluez.pc
|
|
|
|
%files -n libbluetooth3
|
|
%defattr(-, root, root)
|
|
%{_libdir}/libbluetooth.so.*
|
|
%doc AUTHORS COPYING ChangeLog README
|
|
|
|
%files cups
|
|
%defattr(-,root,root)
|
|
%dir %{cups_lib_dir}
|
|
%dir %{cups_lib_dir}/backend
|
|
%{cups_lib_dir}/backend/bluetooth
|
|
|
|
%files test
|
|
%defattr(-,root,root)
|
|
%{_sbindir}/hciemu
|
|
%{_bindir}/l2test
|
|
%{_bindir}/rctest
|
|
%{_bindir}/list-devices
|
|
%{_bindir}/simple-agent
|
|
%{_bindir}/simple-service
|
|
%{_bindir}/test-adapter
|
|
%{_bindir}/test-audio
|
|
%{_bindir}/test-device
|
|
%{_bindir}/test-discovery
|
|
%{_bindir}/test-input
|
|
%{_bindir}/test-manager
|
|
%{_bindir}/test-network
|
|
%{_bindir}/test-serial
|
|
%{_bindir}/test-service
|
|
%{_bindir}/test-telephony
|
|
|
|
%files alsa
|
|
%defattr(-,root,root)
|
|
%dir /usr/share/alsa
|
|
%config /usr/share/alsa/bluetooth.conf
|
|
%{_libdir}/alsa-lib/*.so
|
|
|
|
%files compat
|
|
%defattr(-,root,root)
|
|
%{_bindir}/dund
|
|
%{_bindir}/pand
|
|
%doc %{_mandir}/man1/pand.1.gz
|
|
%doc %{_mandir}/man1/dund.1.gz
|
|
|
|
%changelog
|