]> git.pld-linux.org Git - packages/bluez.git/blame - bluez.spec
up to 5.68
[packages/bluez.git] / bluez.spec
CommitLineData
886fa953
JB
1# TODO:
2# - verify/update bluetooth init script
d358118c 3# - separate obex?
b7b1b136
JB
4#
5# Conditional build:
6%bcond_without deprecated # deprecated tools (ciptool,hciattach,hciconfig,hcidump,hcitool,rfcomm,sdptool)
7#
8e2aef6c
AM
8Summary: Bluetooth utilities
9Summary(pl.UTF-8): Narzędzia Bluetooth
10Name: bluez
7e96ad71 11Version: 5.68
180032fd 12Release: 1
8e2aef6c
AM
13License: GPL v2+
14Group: Applications/System
6feb4e6d 15Source0: https://www.kernel.org/pub/linux/bluetooth/%{name}-%{version}.tar.xz
7e96ad71 16# Source0-md5: 00a72fed12e706b2d8bb40786154d3aa
8e2aef6c
AM
17Source1: %{name}.init
18Source2: %{name}.sysconfig
477801c9
JR
19# Scripts for automatically btattach-ing serial ports connected to Broadcom HCIs
20# as found on some Atom based x86 hardware
21Source3: 69-btattach-bcm.rules
22Source4: btattach-bcm@.service
23Source5: btattach-bcm-service.sh
24Patch0: 0001-obex-Use-GLib-helper-function-to-manipulate-paths.patch
8e2aef6c 25URL: http://www.bluez.org/
b7b1b136 26BuildRequires: alsa-lib-devel >= 1.0
b0a62422 27BuildRequires: autoconf >= 2.60
8e2aef6c 28BuildRequires: automake
f288002d 29BuildRequires: check-devel >= 0.9.6
477801c9 30BuildRequires: cups-devel
a5b81081 31BuildRequires: dbus-devel >= 1.6
649d5a09 32BuildRequires: docutils
41be8c17 33BuildRequires: ell-devel >= 0.39
0ff69826 34BuildRequires: glib2-devel >= 1:2.28
f072e9cd 35BuildRequires: json-c-devel >= 0.13
886fa953 36BuildRequires: libical-devel
8e2aef6c 37BuildRequires: libtool
8e2aef6c 38BuildRequires: pkgconfig >= 1:0.9.0
9980fdad 39BuildRequires: readline-devel
5f69477c 40BuildRequires: rpmbuild(macros) >= 2.011
477801c9 41BuildRequires: systemd-devel
886fa953 42BuildRequires: tar >= 1:1.22
e4a249a5 43BuildRequires: udev-devel >= 1:172
886fa953 44BuildRequires: xz
f3eba8ca 45Requires(post,preun,postun): systemd-units >= 1:250.1
bfe3d974 46Requires: %{name}-libs = %{version}-%{release}
a5b81081 47Requires: dbus-libs >= 1.6
41be8c17 48Requires: ell >= 0.39
0ff69826 49Requires: glib2 >= 1:2.28
0416a3b3 50Requires: hwdata >= 0.225
f072e9cd 51Requires: json-c >= 0.13
9b3fd779 52Requires: rc-scripts
f3eba8ca 53Requires: systemd-units >= 1:250.1
e4a249a5 54Requires: udev >= 1:172
886fa953 55Provides: bluez-hcidump = %{version}
bfe3d974 56Provides: bluez-utils = %{version}-%{release}
886fa953 57Provides: obexd = %{version}
c8deab5a
JR
58Provides: dbus(org.openobex.client)
59Provides: obex-data-server = %{version}
886fa953
JB
60# moved somewhere or dropped?
61#Obsoletes: alsa-plugins-bluetooth
6f85f406
JB
62Obsoletes: bluez-hcidump < 3
63Obsoletes: bluez-hciemu < 2
64Obsoletes: bluez-pan < 2
65Obsoletes: bluez-sdp < 2
66Obsoletes: bluez-systemd < 4.98-3
67Obsoletes: bluez-utils < 4
68Obsoletes: bluez-utils-init < 4
69Obsoletes: obexd < 1
70Obsoletes: obex-data-server < 1
886fa953
JB
71# moved somewhere or dropped?
72#Obsoletes: gstreamer-bluetooth < 4.101-3
73#Obsoletes: gstreamer0.10-bluetooth < 5
8e2aef6c
AM
74Conflicts: bluez-bluefw
75ExcludeArch: s390 s390x
76BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
77
78# currently lib, not %{_lib} (see cups.spec)
79%define cupsdir /usr/lib/cups/backend
d80dfd39 80%define udevdir /lib/udev
8e2aef6c
AM
81
82%description
83Bluetooth utilities:
d8eef2ef 84 - bluetoothd
8e2aef6c
AM
85 - hciattach
86 - hciconfig
886fa953
JB
87 - hcidump
88 - hcitool
8e2aef6c 89 - l2ping
8e2aef6c 90 - start scripts (PLD)
8e2aef6c
AM
91
92The BLUETOOTH trademarks are owned by Bluetooth SIG, Inc., U.S.A.
93
94%description -l pl.UTF-8
95Narzędzia Bluetooth:
d8eef2ef 96 - bluetoothd
8e2aef6c
AM
97 - hciattach
98 - hciconfig
886fa953
JB
99 - hcidump
100 - hcitool
8e2aef6c 101 - l2ping
8e2aef6c 102 - skrypty startowe (PLD)
8e2aef6c
AM
103
104Znaki towarowe BLUETOOTH są własnością Bluetooth SIG, Inc. z USA.
105
8e2aef6c
AM
106%package -n cups-backend-bluetooth
107Summary: Bluetooth backend for CUPS
108Summary(pl.UTF-8): Backend Bluetooth dla CUPS-a
109Group: Applications/Printing
42ca9004 110Requires: %{name}-libs = %{version}-%{release}
8e2aef6c
AM
111Requires: cups
112
113%description -n cups-backend-bluetooth
114Bluetooth backend for CUPS.
115
116%description -n cups-backend-bluetooth -l pl.UTF-8
117Backend Bluetooth dla CUPS-a.
118
42ca9004
JB
119%package -n zsh-completion-bluez
120Summary: Zsh completion for bluez commands
121Summary(pl.UTF-8): Dopełnianie parametrów w zsh dla poleceń z pakietu bluez
122Group: Applications/Shells
123Requires: %{name} = %{version}-%{release}
124Requires: zsh
125
126%description -n zsh-completion-bluez
127Zsh completion for bluez commands (bluezctl utility).
128
129%description -n zsh-completion-bluez -l pl.UTF-8
130Dopełnianie parametrów w zsh dla poleceń z pakietu bluez (narzędzia
131bluezctl).
132
8e2aef6c
AM
133%package libs
134Summary: Bluetooth libraries
135Summary(pl.UTF-8): Biblioteki Bluetooth
ce95dcac 136Group: Libraries
6f85f406 137Obsoletes: bluez-sdp < 2
8e2aef6c
AM
138
139%description libs
140Libraries for use in Bluetooth applications.
141
142The BLUETOOTH trademarks are owned by Bluetooth SIG, Inc., U.S.A.
143
144%description libs -l pl.UTF-8
145Biblioteki do używania w aplikacjach Bluetooth.
146
147Znaki towarowe BLUETOOTH są własnością Bluetooth SIG, Inc. z USA.
148
149%package libs-devel
150Summary: Header files for Bluetooth applications
151Summary(pl.UTF-8): Pliki nagłówkowe dla aplikacji Bluetooth
152Group: Development/Libraries
bfe3d974 153Requires: %{name}-libs = %{version}-%{release}
6f85f406 154Obsoletes: bluez-sdp-devel < 2
8e2aef6c
AM
155
156%description libs-devel
157bluez-libs-devel contains header files for use in Bluetooth
158applications.
159
160%description libs-devel -l pl.UTF-8
161Ten pakiet zawiera pliki nagłówkowe do używania w aplikacjach
162Bluetooth.
163
164%package libs-static
165Summary: Static Bluetooth libraries
166Summary(pl.UTF-8): Biblioteki statyczne Bluetooth
167Group: Development/Libraries
bfe3d974 168Requires: %{name}-libs-devel = %{version}-%{release}
6f85f406 169Obsoletes: bluez-sdp-static < 2
8e2aef6c
AM
170
171%description libs-static
172bluez-libs-static contains development static libraries for use in
173Bluetooth applications.
174
175%description libs-static -l pl.UTF-8
176Ten pakiet zawiera biblioteki statyczne, których można używać do
177aplikacji Bluetooth.
178
179%prep
180%setup -q
477801c9 181%patch0 -p1
8e2aef6c 182
0d05b843
JB
183# external ell is broken if ell/ell.h is in place due to deps generation and Makefile.am rules
184%{__rm} -r ell
185
8e2aef6c
AM
186%build
187%{__libtoolize}
188%{__aclocal}
189%{__autoconf}
190%{__autoheader}
191%{__automake}
192%configure \
b0a62422 193 --disable-silent-rules \
2686afe6 194 --enable-btpclient \
42ca9004 195 %{?with_deprecated:--enable-deprecated} \
d358118c 196 --enable-experimental \
42ca9004 197 --enable-external-ell \
b7b1b136 198 --enable-health \
dc831a02 199 --enable-hid2hci \
886fa953 200 --enable-library \
477801c9
JR
201 --enable-tools \
202 --enable-cups \
203 --enable-testing \
2686afe6 204 --enable-mesh \
b7b1b136
JB
205 --enable-midi \
206 --enable-nfc \
207 --enable-sap \
d358118c
JB
208 --enable-sixaxis \
209 --enable-static \
dc831a02 210 --with-udevdir=%{udevdir} \
d358118c
JB
211 --with-systemdsystemunitdir=%{systemdunitdir} \
212 --with-systemduserunitdir=%{systemduserunitdir}
8e2aef6c 213
284a9eb9 214%{__make} \
dc831a02 215 cupsdir=%{cupsdir}
8e2aef6c
AM
216
217%install
218rm -rf $RPM_BUILD_ROOT
f8fe27de 219install -d $RPM_BUILD_ROOT/etc/{rc.d/init.d,sysconfig} \
d358118c 220 $RPM_BUILD_ROOT{%{_libdir}/{bluetooth,obex}/plugins,%{_sysconfdir}/bluetooth}
8e2aef6c
AM
221
222%{__make} install \
223 DESTDIR=$RPM_BUILD_ROOT \
224 cupsdir=%{cupsdir} \
2b38a1f3 225 rulesdir=%{udevdir}/rules.d \
b0a62422 226 udevdir=%{udevdir}
8e2aef6c 227
8e2aef6c
AM
228install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/bluetooth
229install %{SOURCE2} $RPM_BUILD_ROOT/etc/sysconfig/bluetooth
9a71d017 230
886fa953
JB
231install profiles/input/*.conf $RPM_BUILD_ROOT%{_sysconfdir}/bluetooth
232install profiles/network/*.conf $RPM_BUILD_ROOT%{_sysconfdir}/bluetooth
16869a45 233
477801c9 234#serial port connected Broadcom HCIs scripts
dc831a02
JB
235install %{SOURCE3} $RPM_BUILD_ROOT%{udevdir}/rules.d
236install %{SOURCE4} $RPM_BUILD_ROOT%{systemdunitdir}
237install %{SOURCE5} $RPM_BUILD_ROOT%{_libexecdir}/bluetooth
477801c9
JR
238
239# Install the HCI emulator, useful for testing
dc831a02 240install emulator/btvirt $RPM_BUILD_ROOT%{_libexecdir}/bluetooth
477801c9 241
886fa953 242%{__rm} $RPM_BUILD_ROOT%{_libdir}/libbluetooth.la
477801c9 243%{__rm} $RPM_BUILD_ROOT%{_libdir}/bluetooth/plugins/*.{la,a}
8e2aef6c
AM
244
245%clean
246rm -rf $RPM_BUILD_ROOT
247
248%post
249/sbin/chkconfig --add bluetooth
250%service bluetooth restart
bfe3d974 251%systemd_post bluetooth.service
5f69477c 252%systemd_user_post obex.service
8e2aef6c
AM
253
254%preun
255if [ "$1" = "0" ]; then
256 %service bluetooth stop
257 /sbin/chkconfig --del bluetooth
258fi
c7fd41e3 259%systemd_preun bluetooth.service
5f69477c 260%systemd_user_preun obex.service
c7fd41e3 261
bfe3d974 262%postun
ef6d37ba 263%systemd_reload
c7fd41e3 264
d358118c
JB
265%triggerpostun -- bluez < 5.13-1
266%service rfcomm stop
267/sbin/chkconfig --del rfcomm
5f69477c
JR
268# bluez < 4.98-3
269%systemd_trigger bluetooth.service
d358118c 270
bfe3d974
JR
271%post libs -p /sbin/ldconfig
272%postun libs -p /sbin/ldconfig
273
8e2aef6c
AM
274%files
275%defattr(644,root,root,755)
f7f17420 276%doc AUTHORS ChangeLog README
a5b81081 277%attr(755,root,root) %{_bindir}/bluemoon
886fa953 278%attr(755,root,root) %{_bindir}/bluetoothctl
a9cb60b8 279%attr(755,root,root) %{_bindir}/btattach
886fa953 280%attr(755,root,root) %{_bindir}/btmon
05f769ed 281%attr(755,root,root) %{_bindir}/hex2hcd
ad500939 282%attr(755,root,root) %{_bindir}/isotest
3aca1cde 283%attr(755,root,root) %{_bindir}/l2ping
886fa953 284%attr(755,root,root) %{_bindir}/l2test
f072e9cd 285%attr(755,root,root) %{_bindir}/mesh-cfgclient
14465098 286%attr(755,root,root) %{_bindir}/mesh-cfgtest
2686afe6 287%attr(755,root,root) %{_bindir}/meshctl
e4a249a5 288%attr(755,root,root) %{_bindir}/mpris-proxy
886fa953 289%attr(755,root,root) %{_bindir}/rctest
b7b1b136
JB
290%if %{with deprecated}
291%attr(755,root,root) %{_bindir}/ciptool
292%attr(755,root,root) %{_bindir}/hciattach
293%attr(755,root,root) %{_bindir}/hciconfig
294%attr(755,root,root) %{_bindir}/hcidump
295%attr(755,root,root) %{_bindir}/hcitool
3aca1cde
JB
296%attr(755,root,root) %{_bindir}/rfcomm
297%attr(755,root,root) %{_bindir}/sdptool
b7b1b136 298%endif
2686afe6 299%if "%{_libexecdir}" != "%{_libdir}"
749521e9 300%dir %{_libexecdir}/bluetooth
2686afe6 301%endif
42ca9004 302%attr(755,root,root) %{_libexecdir}/bluetooth/bluetooth-meshd
749521e9 303%attr(755,root,root) %{_libexecdir}/bluetooth/bluetoothd
477801c9
JR
304%attr(755,root,root) %{_libexecdir}/bluetooth/btattach-bcm-service.sh
305%attr(755,root,root) %{_libexecdir}/bluetooth/btvirt
749521e9 306%attr(755,root,root) %{_libexecdir}/bluetooth/obexd
8e2aef6c
AM
307%dir %{_libdir}/bluetooth
308%dir %{_libdir}/bluetooth/plugins
d358118c 309%attr(755,root,root) %{_libdir}/bluetooth/plugins/sixaxis.so
049dc700 310%dir %{_libdir}/obex
d358118c 311%dir %{_libdir}/obex/plugins
8e2aef6c 312%dir %{_sysconfdir}/bluetooth
886fa953
JB
313%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/bluetooth/input.conf
314%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/bluetooth/network.conf
8e2aef6c
AM
315%attr(754,root,root) /etc/rc.d/init.d/bluetooth
316%attr(640,root,root) %config(noreplace) %verify(not md5 mtime size) /etc/sysconfig/bluetooth
317%config(noreplace) %verify(not md5 mtime size) /etc/dbus-1/system.d/bluetooth.conf
42ca9004 318%config(noreplace) %verify(not md5 mtime size) /etc/dbus-1/system.d/bluetooth-mesh.conf
bfe3d974 319%{systemdunitdir}/bluetooth.service
42ca9004 320%{systemdunitdir}/bluetooth-mesh.service
477801c9 321%{systemdunitdir}/btattach-bcm@.service
d358118c 322%{systemduserunitdir}/obex.service
886fa953 323%{_datadir}/dbus-1/services/org.bluez.obex.service
d358118c 324%{_datadir}/dbus-1/system-services/org.bluez.service
42ca9004 325%{_datadir}/dbus-1/system-services/org.bluez.mesh.service
9b2d7208 326%attr(755,root,root) %{udevdir}/hid2hci
477801c9 327%{udevdir}/rules.d/69-btattach-bcm.rules
886fa953 328%{udevdir}/rules.d/97-hid2hci.rules
a9cb60b8 329%{_mandir}/man1/btattach.1*
14465098 330%{_mandir}/man1/btmon.1*
b7b1b136 331%{_mandir}/man1/hid2hci.1*
ad500939 332%{_mandir}/man1/isotest.1*
b7b1b136
JB
333%{_mandir}/man1/l2ping.1*
334%{_mandir}/man1/rctest.1*
335%if %{with deprecated}
3aca1cde 336%{_mandir}/man1/ciptool.1*
886fa953
JB
337%{_mandir}/man1/hciattach.1*
338%{_mandir}/man1/hciconfig.1*
339%{_mandir}/man1/hcidump.1*
3aca1cde 340%{_mandir}/man1/hcitool.1*
3aca1cde
JB
341%{_mandir}/man1/rfcomm.1*
342%{_mandir}/man1/sdptool.1*
b7b1b136 343%endif
14465098 344%{_mandir}/man8/bluetooth-meshd.8*
3aca1cde 345%{_mandir}/man8/bluetoothd.8*
8e2aef6c
AM
346
347%files -n cups-backend-bluetooth
348%defattr(644,root,root,755)
349%attr(755,root,root) %{_prefix}/lib/cups/backend/bluetooth
350
42ca9004
JB
351%files -n zsh-completion-bluez
352%defattr(644,root,root,755)
353%{zsh_compdir}/_bluetoothctl
354
8e2aef6c
AM
355%files libs
356%defattr(644,root,root,755)
357%attr(755,root,root) %{_libdir}/libbluetooth.so.*.*.*
3aca1cde 358%attr(755,root,root) %ghost %{_libdir}/libbluetooth.so.3
8e2aef6c
AM
359
360%files libs-devel
361%defattr(644,root,root,755)
362%attr(755,root,root) %{_libdir}/libbluetooth.so
8e2aef6c 363%{_includedir}/bluetooth
8e2aef6c
AM
364%{_pkgconfigdir}/bluez.pc
365
366%files libs-static
367%defattr(644,root,root,755)
368%{_libdir}/libbluetooth.a
This page took 0.169592 seconds and 4 git commands to generate.