Separate bluez-test package into tests and tools
[platform/upstream/bluez.git] / packaging / bluez.spec
1 # Do not create provides fro extension-tm1 because the main package
2 # should anchor any reverse-dependencies
3 %global __provides_exclude_from ^(.*\\.tm1)$
4
5 #%define __spec_check_pre exit 0
6 %define unified true
7
8 #%define with_libcapng --enable-capng
9 %define _libpath /usr/lib
10 Name:           bluez
11 Summary:        Bluetooth Stack for Linux
12 Version:        5.63
13 Release:        1
14 Group:          Network & Connectivity/Bluetooth
15 License:        GPL-2.0+ and LGPL-2.1+
16 URL:            http://www.bluez.org/
17 Source:         bluez-%{version}.tar.gz
18 Source2:        bluez-coldplug.init
19 Source3:        bluetooth.sysconfig
20 Source4:        bluetooth.sh
21 Source5:        baselibs.conf
22 Source7:        bluetooth.modprobe
23 Source101:      obex-root-setup
24 Source102:      create-symlinks
25 Source103:      obex.sh
26 Source1001:     bluez.manifest
27 Patch :         Use-g_memdup2-for-glib-2.70-upgrade.patch
28 #Patch1 :    bluez-ncurses.patch
29 #Patch2 :    disable-eir-unittest.patch
30 #Requires:   dbus >= 0.60
31 #BuildRequires:  pkgconfig(libudev)
32 BuildRequires:  pkgconfig(dbus-1)
33 BuildRequires:  pkgconfig(iniparser)
34 BuildRequires:  pkgconfig(libxml-2.0)
35 BuildRequires:  pkgconfig(json-c)
36 BuildRequires:  pkgconfig(ell)
37 #BuildRequires:  pkgconfig(glib-2.0)
38 #BuildRequires:  pkgconfig(ncurses)
39 #BuildRequires:  flex
40 #BuildRequires:  bison
41 #BuildRequires:  readline-devel
42 #BuildRequires:  openssl-devel
43 BuildRequires:  flex
44 BuildRequires:  libcap-ng-devel
45 BuildRequires:  systemd
46 %{?systemd_requires}
47 BuildRequires:  pkgconfig(alsa)
48 BuildRequires:  automake
49 BuildRequires:  check-devel
50 BuildRequires:  glib2-devel >= 2.16
51 BuildRequires:  libsndfile-devel
52 BuildRequires:  libtool
53 BuildRequires:  libudev-devel
54 BuildRequires:  pkg-config
55 BuildRequires:  readline-devel
56 BuildRequires:  udev
57 BuildRequires:  pkgconfig(libtzplatform-config)
58 Requires:       %{name}-compat = %{version}-%{release}
59 Requires:       security-config
60 Recommends:     %{name}-profile_common = %{version}-%{release}
61
62 %description
63 The Bluetooth stack for Linux.
64
65 %if %{unified} == true
66 %package extension-bredr
67 Summary:    Bluez extension for BREDR functionality
68 Requires:  %{name} = %{version}-%{release}
69 Conflicts:  %{name}-extension-le = %{version}-%{release}
70 %description extension-bredr
71 Bluez extension for BREDR functionality
72
73 %package extension-le
74 Summary:    Bluez extension for LE functionality
75 Requires:  %{name} = %{version}-%{release}
76 Conflicts:  %{name}-extension-bredr = %{version}-%{release}
77 %description extension-le
78 Bluez extension for LE functionality
79 %endif
80
81 %package -n obexd
82 Summary:        OBEX Server A basic OBEX server implementation
83 Group:          Network & Connectivity/Bluetooth
84 Requires:       tizen-platform-config-tools
85
86 %description -n obexd
87 OBEX Server A basic OBEX server implementation.
88
89 %package test
90 Summary:        Tools for testing of various Bluetooth-functions
91 License:        GPL-2.0+
92 Group:          Development/Tools
93 Requires:       dbus-python
94 Requires:       python-gobject
95
96 %description test
97 Contains a few tools for testing various bluetooth functions. The
98 BLUETOOTH trademarks are owned by Bluetooth SIG, Inc., U.S.A.
99
100
101 %package tools
102 Summary:        Bluez configuration tools
103 License:        GPL-2.0+
104 Group:          Development/Tools
105
106 %description tools
107 # !!! WARNING !!!
108 # Using any tool in this package results direct access to bluez stack,
109 # so the result of the tool won't be applied to Tizen system properly.
110 # Recommend to use it cautiously and only in development phase.
111 Bluez tools to manipulate bluetooth devices and configuartion.
112
113 %package profile_common
114 Summary:        Modified bluez for mobile/common profile
115 Provides:       %{name}-compat = %{version}-%{release}
116 Provides:       %{name}-profile_mobile = %{version}-%{release}
117 Provides:       %{name}-profile_ivi = %{version}-%{release}
118 Conflicts:      %{name}-profile_wearable
119 Conflicts:      %{name}-profile_tv
120 %description profile_common
121 Bluez default service script for Tizen (mobile/common profile)
122
123 %package profile_wearable
124 Summary:        Modified bluez for wearable profile
125 Provides:       %{name}-compat = %{version}-%{release}
126 Conflicts:      %{name}-profile_common
127 Conflicts:      %{name}-profile_tv
128 %description profile_wearable
129 Bluez modified service script for Tizen wearable
130
131 %package profile_tv
132 Summary:        Modified bluez for wearable profile
133 Provides:       %{name}-compat = %{version}-%{release}
134 Conflicts:      %{name}-profile_common
135 Conflicts:      %{name}-profile_wearable
136 %description profile_tv
137 Bluez modified service script for Tizen TV
138
139 %package plugin-headless
140 Summary:        Bluez headless plugin
141 Requires:       %{name}-compat = %{version}-%{release}
142 %description plugin-headless
143 This package is Bluez plugin to manager headless device
144
145 %package plugin-keyboard
146 Summary:        Bluez keyboard plugin
147 Requires:       %{name}-compat = %{version}-%{release}
148 %description plugin-keyboard
149 This package is Bluez plugin to manager keyboard device
150
151 %package plugin-robot
152 Summary:        Bluez robot plugin
153 Requires:       %{name}-compat = %{version}-%{release}
154 %description plugin-robot
155 This package is Bluez plugin to manager robot device
156
157 %package plugin-da
158 Summary:        Bluez plugin for Digital Appliance
159 Requires:       %{name}-compat = %{version}-%{release}
160 %description plugin-da
161 This package is Bluez plugin to manager Digital Appliance devices
162
163 %package mesh
164 Summary:        contains binaries for bluetooth mesh
165 Requires:       %{name}-compat = %{version}-%{release}
166 License:        GPL-2.0+
167 %description mesh
168 Contains bluetooth mesh daemon
169
170 %prep
171 %setup -q
172 cp %{SOURCE1001} .
173 %patch -p1
174
175 %build
176 autoreconf -fiv
177
178 #if "{?profile}" == "ivi"
179 # TIZEN_FEATURE_BLUEZ_BRCM_CHIP: only in tools/hciattach.c ==> RUNTIME! (profile.h)
180 #endif
181
182 #if "{?profile}" == "wearable"
183 # TIZEN_FEATURE_BLUEZ_SMS_ONLY: only in obexd/plugins/messages-tizen.c ==> RUNTIME! (profile.h)
184 # TIZEN_FEATURE_BLUEZ_BRCM_QOS: only in profiles/audio/avdtp.c ==> RUNTIME! (profile.h)
185 # TIZEN_FEATURE_BLUEZ_ROLE_CHANGE: only in profiles/audio/avdtp.c ==> RUNTIME! (profile.h)
186 # TIZEN_FEATURE_BLUEZ_CONFIRM_ONLY: only in src/device.c ==> RUNTIME! (profile.h)
187 #endif
188
189
190 # For LE only
191
192 export CFLAGS_DEFAULT="$CFLAGS"
193
194 %if %{unified} == true
195 # Add GCC9 exception
196 export CFLAGS+=" -Wno-stringop-truncation -Wno-format-truncation -Wno-address-of-packed-member"
197
198 export LDFLAGS=" -lncurses -Wl,--as-needed "
199 export CFLAGS+=" -Werror -DTIZEN_FEATURE_BLUEZ_MODIFY -DTIZEN_FEATURE_BLUEZ_A2DP_MULTISTREAM -DTIZEN_FEATURE_BLUEZ_PBAP_SIM -DTIZEN_FEATURE_BLUEZ_AVRCP_TARGET -DTIZEN_FEATURE_BLUEZ_AVRCP_CONTROL -DTIZEN_FEATURE_BLUEZ_AVRCP_TARGET -DENABLE_AVRCP_CATEGORY1 -DTIZEN_BT_HID_DEVICE_ENABLE"
200
201 %ifarch aarch64
202 echo arch64
203 export CFLAGS+=" -DARCH64"
204 %endif
205
206 %ifarch x86_64
207 echo x86_64
208 export CFLAGS+=" -DARCH64"
209 %endif
210
211 %reconfigure --disable-static \
212                         --sysconfdir=%{_sysconfdir} \
213                         --localstatedir=%{_localstatedir} \
214                         --with-systemdsystemunitdir=%{_libpath}/systemd/system \
215                         --with-systemduserunitdir=%{_libpath}/systemd/user \
216                         --libexecdir=%{_libexecdir} \
217                         --enable-debug \
218                         --enable-pie \
219                         --enable-usb=no \
220                         --enable-tools \
221                         --disable-bccmd \
222                         --enable-pcmcia=no \
223                         --enable-hid2hci=yes \
224                         --enable-alsa=no \
225                         --enable-gstreamer=no \
226                         --disable-dfutool \
227                         --disable-cups \
228                         --enable-proximity=yes \
229                         --enable-tds=yes \
230                         --enable-dbusoob \
231                         --enable-test \
232                         --enable-mesh=yes \
233                         --with-telephony=tizen \
234                         --enable-obex \
235                         --enable-library \
236                         --enable-gatt \
237                         --enable-testing \
238                         --enable-experimental \
239                         --enable-autopyypair=no \
240                         --enable-tizenunusedplugin=no \
241                         --disable-crypto-tests \
242                         --enable-external-ell
243
244 make %{?_smp_mflags} all V=1
245
246 mkdir -p le
247
248 #%make_install
249 cp -a  %{buildroot}%{_libexecdir}/bluetooth/bluetoothd le/
250
251
252 # For BREDR only
253 make distclean
254
255 autoreconf -fiv
256
257 export CFLAGS="$CFLAGS_DEFAULT"
258
259 # Add GCC9 exception
260 export CFLAGS+=" -Wno-stringop-truncation -Wno-format-truncation -Wno-address-of-packed-member"
261
262 export LDFLAGS=" -lncurses -Wl,--as-needed "
263 export CFLAGS+=" -Werror -DTIZEN_FEATURE_BLUEZ_MODIFY -DTIZEN_FEATURE_BLUEZ_A2DP_MULTISTREAM -DTIZEN_FEATURE_BLUEZ_PBAP_SIM -DTIZEN_FEATURE_BLUEZ_AVRCP_TARGET -DTIZEN_FEATURE_BLUEZ_AVRCP_CONTROL -DTIZEN_FEATURE_BLUEZ_AVRCP_TARGET -DENABLE_AVRCP_CATEGORY1 -DTIZEN_BT_HID_DEVICE_ENABLE"
264
265 %ifarch aarch64
266 echo arch64
267 export CFLAGS+=" -DARCH64"
268 %endif
269
270 %ifarch x86_64
271 echo x86_64
272 export CFLAGS+=" -DARCH64"
273 %endif
274
275 %reconfigure --disable-static \
276                         --sysconfdir=%{_sysconfdir} \
277                         --localstatedir=%{_localstatedir} \
278                         --with-systemdsystemunitdir=%{_libpath}/systemd/system \
279                         --with-systemduserunitdir=%{_libpath}/systemd/user \
280                         --libexecdir=%{_libexecdir} \
281                         --enable-debug \
282                         --enable-pie \
283                         --enable-serial \
284                         --enable-input \
285                         --enable-usb=no \
286                         --enable-tools \
287                         --disable-bccmd \
288                         --enable-pcmcia=no \
289                         --enable-hid2hci=yes \
290                         --enable-alsa=no \
291                         --enable-gstreamer=no \
292                         --disable-dfutool \
293                         --disable-cups \
294                         --enable-health=yes \
295                         --enable-dbusoob \
296                         --enable-test \
297                         --enable-mesh=yes \
298                         --with-telephony=tizen \
299                         --enable-obex \
300                         --enable-library \
301                         --enable-testing \
302                         --enable-experimental \
303                         --enable-autopair=no \
304                         --enable-hid=yes \
305                         --enable-bredr=yes \
306                         --enable-tizenunusedplugin=no \
307                         --disable-crypto-tests \
308                         --enable-external-ell
309
310 make %{?_smp_mflags} all V=1
311
312 mkdir -p bredr
313
314 #%make_install
315 cp -a  %{buildroot}%{_libexecdir}/bluetooth/bluetoothd bredr/
316
317
318 # For BREDR + LE
319 make distclean
320
321 autoreconf -fiv
322 %endif
323 export CFLAGS="$CFLAGS_DEFAULT"
324
325 # Add GCC9 exception
326 export CFLAGS+=" -Wno-stringop-truncation -Wno-format-truncation -Wno-address-of-packed-member"
327
328 export LDFLAGS=" -lncurses -Wl,--as-needed "
329 export CFLAGS+=" -Werror -DTIZEN_FEATURE_BLUEZ_MODIFY -DTIZEN_FEATURE_BLUEZ_A2DP_MULTISTREAM -DTIZEN_FEATURE_BLUEZ_PBAP_SIM -DTIZEN_FEATURE_BLUEZ_AVRCP_TARGET -DTIZEN_FEATURE_BLUEZ_AVRCP_CONTROL -DTIZEN_FEATURE_BLUEZ_AVRCP_TARGET -DENABLE_AVRCP_CATEGORY1 -DTIZEN_BT_HID_DEVICE_ENABLE"
330
331 %ifarch aarch64
332 echo arch64
333 export CFLAGS+=" -DARCH64"
334 %endif
335
336 %ifarch x86_64
337 echo x86_64
338 export CFLAGS+=" -DARCH64"
339 %endif
340
341 %reconfigure --disable-static \
342                         --sysconfdir=%{_sysconfdir} \
343                         --localstatedir=%{_localstatedir} \
344                         --with-systemdsystemunitdir=%{_libpath}/systemd/system \
345                         --with-systemduserunitdir=%{_libpath}/systemd/user \
346                         --libexecdir=%{_libexecdir} \
347                         --enable-debug \
348                         --enable-pie \
349                         --enable-serial \
350                         --enable-input \
351                         --enable-usb=no \
352                         --enable-tools \
353                         --disable-bccmd \
354                         --enable-pcmcia=no \
355                         --enable-hid2hci=yes \
356                         --enable-alsa=no \
357                         --enable-gstreamer=no \
358                         --disable-dfutool \
359                         --disable-cups \
360                         --enable-health=yes \
361                         --enable-proximity=yes \
362                         --enable-tds=yes \
363                         --enable-dbusoob \
364                         --enable-test \
365                         --with-telephony=tizen \
366                         --enable-obex \
367                         --enable-mesh=yes \
368                         --enable-library \
369                         --enable-gatt \
370                         --enable-testing \
371                         --enable-experimental \
372                         --enable-autopair=no \
373                         --enable-hid=yes \
374                         --enable-bredr=yes \
375                         --enable-tizenunusedplugin=no \
376                         --disable-crypto-tests \
377                         --enable-external-ell
378
379 make %{?_smp_mflags} all V=1
380
381 %check
382 make check
383
384 %install
385 %make_install
386
387 %if %{unified} == true
388 pushd bredr
389 for FILE in bluetoothd; do mv "$FILE" "%{buildroot}%{_libexecdir}/bluetooth/$FILE.bredr"; done
390 popd
391
392 pushd le
393 for FILE in bluetoothd; do mv "$FILE" "%{buildroot}%{_libexecdir}/bluetooth/$FILE.le"; done
394 popd
395 %endif
396
397 # bluez-test
398 rm -rvf $RPM_BUILD_ROOT/%{_libdir}/gstreamer-*
399 #install --mode=0755 -D %{S:4} $RPM_BUILD_ROOT/usr/lib/udev/bluetooth.sh
400 %if %{unified} == true
401 install --mode=0644 -D %{S:7} $RPM_BUILD_ROOT/%{_sysconfdir}/modprobe.d/50-bluetooth.conf
402 %endif
403
404 # no idea why this is suddenly necessary...
405 install --mode 0755 -d $RPM_BUILD_ROOT/var/lib/bluetooth
406
407 install -D -m 0644 src/main_w.conf %{buildroot}%{_sysconfdir}/bluetooth/main.conf.wearable
408 install -D -m 0644 src/main_m.conf %{buildroot}%{_sysconfdir}/bluetooth/main.conf
409 install -D -m 0644 src/main_headless.conf %{buildroot}%{_sysconfdir}/bluetooth/main.conf.headless
410 install -D -m 0644 src/main_keyboard.conf %{buildroot}%{_sysconfdir}/bluetooth/main.conf.keyboard
411 install -D -m 0644 src/main_robot.conf %{buildroot}%{_sysconfdir}/bluetooth/main.conf.robot
412 install -D -m 0644 src/main_da.conf %{buildroot}%{_sysconfdir}/bluetooth/main.conf.da
413
414 #install -D -m 0644 src/org.bluez.service %{buildroot}%{_datadir}/dbus-1/system-services/org.bluez.service
415
416 install -D -m 0644 src/bluetooth.conf %{buildroot}%{_sysconfdir}/dbus-1/system.d/bluetooth.conf
417 install -D -m 0644 src/bluetooth_robot.conf %{buildroot}%{_sysconfdir}/dbus-1/system.d/bluetooth_robot.conf
418 #install -D -m 0644 profiles/audio/audio.conf %{buildroot}%{_sysconfdir}/bluetooth/audio.conf
419 #install -D -m 0644 profiles/network/network.conf %{buildroot}%{_sysconfdir}/bluetooth/network.conf
420
421 #install -D -m 0644 COPYING %{buildroot}%{_datadir}/license/bluez
422 #install -D -m 0644 COPYING %{buildroot}%{_datadir}/license/libbluetooth3
423 #install -D -m 0644 COPYING %{buildroot}%{_datadir}/license/libbluetooth-devel
424
425 #install -D -m 0755 %SOURCE101 %{buildroot}%{_bindir}/obex-root-setup
426 #install -D -m 0755 %SOURCE102 %{buildroot}%{_sysconfdir}/obex/root-setup.d/000_create-symlinks
427 #install -D -m 0755 %SOURCE103 %{buildroot}%{_bindir}/obex.sh
428 install -D -m 0755 tools/btiotest $RPM_BUILD_ROOT/%{_bindir}/
429 install -D -m 0755 tools/bluetooth-player $RPM_BUILD_ROOT/%{_bindir}/
430 #install -D -m 0755 tools/mpris-player $RPM_BUILD_ROOT/%{_bindir}/
431 install -D -m 0755 tools/btmgmt $RPM_BUILD_ROOT/%{_bindir}/
432 install -D -m 0755 tools/scotest $RPM_BUILD_ROOT/%{_bindir}/
433 install -D -m 0755 tools/bluemoon $RPM_BUILD_ROOT/%{_bindir}/
434 install -D -m 0755 attrib/gatttool $RPM_BUILD_ROOT/%{_bindir}/
435 install -D -m 0755 tools/meshctl $RPM_BUILD_ROOT/%{_bindir}/
436 install -D -m 0755 tools/mesh-cfgclient $RPM_BUILD_ROOT/%{_bindir}/
437
438 # mesh conf
439 install -D -m 0644 mesh/mesh-main.conf %{buildroot}%{_sysconfdir}/bluetooth/mesh-main.conf
440
441 install -D -m 0755 tools/obexctl %{buildroot}%{_bindir}/obexctl
442
443 install -D -m 0644 obexd/src/obex.service %{buildroot}%{_libpath}/systemd/system/
444
445 install -D -m 0644 src/bluetooth.service %{buildroot}%{_libpath}/systemd/system/bluez-start.service
446
447 %if %{unified} == true
448 %post -n bluez-extension-bredr
449 pushd %{_libexecdir}/bluetooth
450 for FILE in bluetoothd.bredr; do mv "$FILE" "${FILE%.bredr}"; done
451 popd
452 /sbin/ldconfig
453
454 %post -n bluez-extension-le
455 pushd %{_libexecdir}/bluetooth
456 for FILE in bluetoothd.le; do mv "$FILE" "${FILE%.le}"; done
457 popd
458 /sbin/ldconfig
459 %endif
460
461 %files
462 %manifest %{name}.manifest
463 %defattr(-, root, root)
464 %license COPYING
465 #%{_sysconfdir}/bluetooth/audio.conf
466 #%{_sysconfdir}/bluetooth/network.conf
467 #%{_sysconfdir}/bluetooth/rfcomm.conf
468 #%{_datadir}/man/*/*
469 %attr(750, network_fw, network_fw)%{_bindir}/hcitool
470 %{_bindir}/l2ping
471 %{_bindir}/obexctl
472 %{_bindir}/rfcomm
473 %{_bindir}/btsnoop
474 %{_bindir}/mpris-proxy
475 %{_bindir}/sdptool
476 %{_bindir}/ciptool
477 #%{_bindir}/dfutool
478 %{_bindir}/btmon
479 %{_bindir}/hcidump
480 %attr(750, network_fw, network_fw)%{_bindir}/btattach
481 %attr(750, network_fw, network_fw)%{_bindir}/hciattach
482 %attr(750, network_fw, network_fw)%{_bindir}/hciconfig
483 %attr(755, network_fw, network_fw)%{_libexecdir}/bluetooth/bluetoothd
484 %exclude %{_libexecdir}/bluetooth/bluetoothd.bredr
485 %exclude %{_libexecdir}/bluetooth/bluetoothd.le
486 %exclude %{_includedir}/bluetooth/*
487 %exclude %{_libdir}/pkgconfig/bluez.pc
488 #%{_bindir}/bccmd
489 #%{_sbindir}/hid2hci
490 %dir /usr/lib/udev
491 /usr/lib/udev/*
492 %{_unitdir}/bluez-start.service
493 %exclude %{_unitdir}/bluetooth.service
494
495 %if %{unified} == true
496 %files -n bluez-extension-bredr
497 %manifest %{name}.manifest
498 %defattr(-, root, root)
499 %{_libexecdir}/bluetooth/bluetoothd.bredr
500
501 %files -n bluez-extension-le
502 %manifest %{name}.manifest
503 %defattr(-, root, root)
504 %{_libexecdir}/bluetooth/bluetoothd.le
505 %config %{_sysconfdir}/dbus-1/system.d/bluetooth.conf
506 %dir /var/lib/bluetooth
507 %dir %{_sysconfdir}/modprobe.d
508 %config(noreplace) %{_sysconfdir}/modprobe.d/50-bluetooth.conf
509 %endif
510
511 %files mesh
512 %manifest %{name}.manifest
513 %defattr(-, root, root)
514 %license COPYING
515 %{_sysconfdir}/dbus-1/system.d/bluetooth-mesh.conf
516 %attr(755, network_fw, network_fw)%{_libexecdir}/bluetooth/bluetooth-meshd
517 %{_libpath}/systemd/system/bluetooth-mesh.service
518 %exclude %{_datadir}/dbus-1/system-services/org.bluez.mesh.service
519 %exclude /usr/lib/debug/*
520 %{_sysconfdir}/bluetooth/mesh-main.conf
521
522 %files -n obexd
523 %manifest %{name}.manifest
524 %defattr(-,root,root,-)
525 %{_libexecdir}/bluetooth/obexd
526 %{_libpath}/systemd/system/obex.service
527 %{_datadir}/dbus-1/system-services/org.bluez.obex.service
528 #%{_sysconfdir}/obex/root-setup.d/000_create-symlinks
529 #%{_bindir}/obex-root-setup
530 #%{_bindir}/obex.sh
531
532 %files tools
533 %{_bindir}/bluetoothctl
534 %{_bindir}/btmgmt
535 %{_bindir}/gatttool
536 %{_bindir}/bluemoon
537 %{_bindir}/hex2hcd
538 %{_bindir}/meshctl
539 %{_bindir}/mesh-cfgclient
540 %{_bindir}/bluetooth-player
541
542 %files test
543 %manifest %{name}.manifest
544 %defattr(-,root,root)
545 %{_libdir}/bluez/test/*
546 %{_bindir}/l2test
547 %{_bindir}/rctest
548 %{_bindir}/btiotest
549 #%{_bindir}/mpris-player
550 %{_bindir}/scotest
551 %{_bindir}/avtest
552 #%{_bindir}/btattach
553 %exclude /usr/lib/debug/*
554 %{_libdir}/libbluetooth.so*
555
556 %docs_package
557
558 %post profile_wearable
559 ln -sf main.conf.wearable %{_sysconfdir}/bluetooth/main.conf
560 %preun profile_wearable
561 rm %{_sysconfdir}/bluetooth/main.conf
562 %files profile_wearable
563 %manifest %{name}.manifest
564 %{_sysconfdir}/bluetooth/main.conf.wearable
565 %{_sysconfdir}/dbus-1/system.d/bluetooth.conf
566
567 %files profile_tv
568 %manifest %{name}.manifest
569 %{_sysconfdir}/bluetooth/main.conf
570 %exclude %{_datadir}/dbus-1/system-services/org.bluez.service
571 %{_sysconfdir}/dbus-1/system.d/bluetooth.conf
572
573 %files profile_common
574 %manifest %{name}.manifest
575 %{_sysconfdir}/bluetooth/main.conf
576 %{_sysconfdir}/dbus-1/system.d/bluetooth.conf
577
578 %post plugin-headless
579 ln -sf main.conf.headless %{_sysconfdir}/bluetooth/main.conf
580 %preun plugin-headless
581 rm %{_sysconfdir}/bluetooth/main.conf
582 %files plugin-headless
583 %manifest %{name}.manifest
584 %{_sysconfdir}/bluetooth/main.conf.headless
585
586 %post plugin-keyboard
587 ln -sf main.conf.keyboard %{_sysconfdir}/bluetooth/main.conf
588 %preun plugin-keyboard
589 rm %{_sysconfdir}/bluetooth/main.conf
590 %files plugin-keyboard
591 %manifest %{name}.manifest
592 %{_sysconfdir}/bluetooth/main.conf.keyboard
593
594 %post plugin-robot
595 ln -sf main.conf.robot %{_sysconfdir}/bluetooth/main.conf
596 mv %{_sysconfdir}/dbus-1/system.d/bluetooth_robot.conf %{_sysconfdir}/dbus-1/system.d/bluetooth.conf
597 %preun plugin-robot
598 rm %{_sysconfdir}/bluetooth/main.conf
599 %files plugin-robot
600 %manifest %{name}.manifest
601 %{_sysconfdir}/bluetooth/main.conf.robot
602 %{_sysconfdir}/dbus-1/system.d/bluetooth_robot.conf
603
604 %post plugin-da
605 ln -sf main.conf.da %{_sysconfdir}/bluetooth/main.conf
606 %preun plugin-da
607 rm %{_sysconfdir}/bluetooth/main.conf
608 %files plugin-da
609 %manifest %{name}.manifest
610 %{_sysconfdir}/bluetooth/main.conf.da
611
612 %changelog