Not enable BT on booting time in factory mode
[platform/core/connectivity/bluetooth-frwk.git] / packaging / bluetooth-frwk.spec
1 # Do not create provides from emulator .so files because the main package
2 # should anchor any reverse-dependencies
3 %global __provides_exclude_from ^(.*\\.emulator)$
4
5 %bcond_with x
6 %define _dumpdir /opt/etc/dump.d/module.d
7 %define _varlibdir /opt/var/lib
8
9 Name:       bluetooth-frwk
10 Summary:    Bluetooth framework for BlueZ and Obexd. This package is Bluetooth framework based on BlueZ and Obexd stack.
11 Version:    0.3.0
12 Release:    1
13 Group:      Network & Connectivity/Bluetooth
14 License:    Apache-2.0
15 Source0:    %{name}-%{version}.tar.gz
16 Source1001: bluetooth-frwk.manifest
17
18 Requires: bluetooth-tools
19
20 %define bt_bluez_hal ENABLED
21 %define bt_gatt_client_fd ENABLED
22 %define bt_permanent_log DISABLED
23 %define bt_http_proxy DISABLED
24 %define bt_factory_mode DISABLED
25
26 BuildRequires:  pkgconfig(aul)
27 %if %{bt_factory_mode} == ENABLED
28 BuildRequires:  pkgconfig(bincfg)
29 %endif
30 BuildRequires:  pkgconfig(dlog)
31 BuildRequires:  pkgconfig(glib-2.0)
32 BuildRequires:  pkgconfig(gio-2.0)
33 BuildRequires:  pkgconfig(gio-unix-2.0)
34 BuildRequires:  pkgconfig(syspopup-caller)
35 BuildRequires:  pkgconfig(vconf)
36 BuildRequires:  pkgconfig(libxml-2.0)
37 BuildRequires:  pkgconfig(capi-network-connection)
38 BuildRequires:  pkgconfig(alarm-service)
39 BuildRequires:  pkgconfig(capi-content-mime-type)
40 BuildRequires:  pkgconfig(eventsystem)
41 %if %{bt_http_proxy} == ENABLED
42 BuildRequires:  pkgconfig(libsoup-2.4)
43 %endif
44 BuildRequires:  pkgconfig(capi-network-tethering)
45 BuildRequires:  cmake
46 BuildRequires:  pkgconfig(cynara-client)
47 BuildRequires:  pkgconfig(cynara-creds-gdbus)
48 BuildRequires:  pkgconfig(libtzplatform-config)
49 BuildRequires:  pkgconfig(storage)
50 BuildRequires:  pkgconfig(capi-system-info)
51 BuildRequires:  pkgconfig(capi-appfw-app-control)
52 BuildRequires:  pkgconfig(gmock)
53 BuildRequires:  pkgconfig(libactd)
54 BuildRequires:  pkgconfig(libsystemd-daemon)
55
56 Requires(post): /usr/bin/vconftool
57 Requires(post): /sbin/ldconfig
58 Requires(postun): /sbin/ldconfig
59
60 %description
61 Bluetooth framework for BlueZ and Obexd. This package is Bluetooth framework based on BlueZ and Obexd stack.
62  This package contains API set for BT GAP, BT SDP, and BT RFCOMM.
63
64 %package profile_common
65 Summary:    bluetooth-frwk service and conf files for common profile
66 Requires:   %{name} = %{version}-%{release}
67 Conflicts:  %{name}-profile_mobile
68 Conflicts:  %{name}-profile_wearable
69 Conflicts:  %{name}-profile_tv
70 Conflicts:  %{name}-profile_ivi
71 %description profile_common
72 Bluetooth framework configuration and service files for Tizen common profile
73
74 %package profile_mobile
75 Summary:    bluetooth-frwk service and conf files for mobile profile
76 Requires:   %{name} = %{version}-%{release}
77 Conflicts:  %{name}-profile_common
78 Conflicts:  %{name}-profile_wearable
79 Conflicts:  %{name}-profile_tv
80 Conflicts:  %{name}-profile_ivi
81 %description profile_mobile
82 Bluetooth framework configuration and service files for Tizen mobile profile
83
84 # extension-TM1
85 %ifarch %{ix86} || %{arm}
86 %package extension-TM1
87 Summary:    bluetooth-frwk service and conf files for mobile TM1
88 Requires:   %{name}-profile_mobile = %{version}-%{release}
89 %description extension-TM1
90 Bluetooth framework configuration and service files for Tizen mobile TM1
91 %endif
92
93 %package profile_wearable
94 Summary:    bluetooth-frwk service and conf files for wearable profile
95 Requires:   %{name} = %{version}-%{release}
96 Conflicts:  %{name}-profile_mobile
97 Conflicts:  %{name}-profile_common
98 Conflicts:  %{name}-profile_tv
99 Conflicts:  %{name}-profile_ivi
100 %description profile_wearable
101 Bluetooth framework configuration and service files for Tizen wearable profile
102
103 %package profile_tv
104 Summary:    bluetooth-frwk service and conf files for tv profile
105 Requires:   %{name} = %{version}-%{release}
106 Conflicts:  %{name}-profile_mobile
107 Conflicts:  %{name}-profile_wearable
108 Conflicts:  %{name}-profile_common
109 Conflicts:  %{name}-profile_ivi
110 %description profile_tv
111 Bluetooth framework configuration and service files for Tizen tv profile
112
113 %package profile_ivi
114 Summary:    bluetooth-frwk service and conf files for ivi profile
115 Requires:   %{name} = %{version}-%{release}
116 Conflicts:  %{name}-profile_mobile
117 Conflicts:  %{name}-profile_wearable
118 Conflicts:  %{name}-profile_tv
119 Conflicts:  %{name}-profile_common
120 %description profile_ivi
121 Bluetooth framework configuration and service files for Tizen ivi profile
122
123 %ifarch %{ix86} x86_64
124 %package extension-emulator
125 Summary:    bluetooth-frwk service and conf files for emulator
126 Requires:   %{name} = %{version}-%{release}
127 %description extension-emulator
128 bluetooth-frwk service and conf files for emulator
129 %endif // ifarch %{ix86} x86_64
130
131 %package devel
132 Summary:    Bluetooth framework for BlueZ and Obexd
133 Group:      Development/Libraries
134 Requires:   %{name} = %{version}-%{release}
135
136 %description devel
137 This package is development files for Bluetooth framework based on BlueZ and Obexd stack.
138 This package contains API set for BT GAP, BT SDP, and BT RFCOMM.
139
140 %package service
141 Summary:    Bluetooth Service daemon
142 Group:      Network & Connectivity/Bluetooth
143 Requires:   %{name} = %{version}-%{release}
144
145 %description service
146 This package is Bluetooth Service daemon to manage BT services.
147
148 %if %{bt_http_proxy} == ENABLED
149 %package httpproxy
150 Summary:    Bluetooth HTTP Proxy Service daemon
151 Group:      Network & Connectivity/Bluetooth
152 Requires:   %{name} = %{version}-%{release}
153
154 %description httpproxy
155 This package is Bluetooth HTTP Proxy Service daemon
156 %endif
157
158 %package otp
159 Summary:    Bluetooth OTP Service daemon
160 Group:      Network & Connectivity/Bluetooth
161 Requires:   %{name} = %{version}-%{release}
162
163 %description otp
164 This package is Bluetooth OTP Service daemon
165
166 %package core
167 Summary:    Bluetooth Core daemon
168 Group:      Network & Connectivity/Bluetooth
169 Requires:   %{name} = %{version}-%{release}
170
171 %description core
172 This package is Bluetooth core daemon to manage activation / deactivation.
173
174 %package test
175 Summary:    Bluetooth test application
176 Group:      Network & Connectivity/Bluetooth
177 Requires:   %{name} = %{version}-%{release}
178
179 %description test
180 This package is Bluetooth test application.
181
182 %package oal
183 Summary:    Bluetooth OAL
184 Group:      Network & Connectivity/Bluetooth
185 Requires:   %{name} = %{version}-%{release}
186
187 %description oal
188 This package is BT stack common interface.
189
190 %package plugin-headed
191 Summary:    Bluetooth plugin Headed
192 Group:      Network & Connectivity/Bluetooth
193 Requires:   %{name} = %{version}-%{release}
194
195 %description plugin-headed
196 This package is Bluetooth plugin to manage UI and syspopup
197
198 %package -n bluetooth-haltests
199 Summary: HAL Test package for bluetooth OAL
200 Group:   TO_BE/FILLED
201 Requires: %{name} = %{version}-%{release}
202
203 %description -n bluetooth-haltests
204 This package is C-API test application.
205
206 %prep
207 %setup -q
208 cp %{SOURCE1001} .
209
210
211 %build
212 export CFLAGS="$CFLAGS -DTIZEN_DEBUG_ENABLE"
213 export CFLAGS="$CFLAGS -DTIZEN_FEATURE_BT_OBEX"
214 export CFLAGS="$CFLAGS -DTIZEN_FEATURE_BT_PAN_NAP"
215 export CFLAGS="$CFLAGS -DTIZEN_FEATURE_BT_IPSP"
216 export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE"
217 export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
218 export CFLAGS="$CFLAGS -DTIZEN_GATT_CLIENT"
219 export CFLAGS="$CFLAGS -DTIZEN_FEATURE_ACTD"
220
221 %define _servicefile packaging/bluetooth-frwk-common.service
222 %define _servicedir starter.target.wants
223
224 %if "%{?profile}" == "mobile"
225 export CFLAGS="$CFLAGS -DTIZEN_FEATURE_NETWORK_TETHERING_ENABLE -DTIZEN_FEATURE_FLIGHTMODE_ENABLED -DTIZEN_PROFILE_MOBILE -DTIZEN_FEATURE_TELEPHONY_ENABLED"
226 %if "%{?tizen_target_name}" == "TM1"
227 %define _servicefile packaging/bluetooth-frwk-mobile-sprd.service
228 %else
229 %define _servicefile packaging/bluetooth-frwk-mobile.service
230 %endif
231 %define _servicedir multi-user.target.wants
232 %endif
233
234 %if "%{?profile}" == "wearable"
235 export CFLAGS="$CFLAGS -DTIZEN_PROFILE_WEARABLE -DTIZEN_FEATURE_FLIGHTMODE_ENABLED"
236 %define _servicefile packaging/bluetooth-frwk-wearable.service
237 %define _servicedir multi-user.target.wants
238 %endif
239
240 %if "%{?profile}" == "tv"
241 export CFLAGS="$CFLAGS -DUSB_BLUETOOTH -DTIZEN_TV -DAUTO_ACCEPT"
242 %define _servicefile packaging/bluetooth-frwk-tv.service
243 %define _servicedir multi-user.target.wants
244 %endif
245
246 %if "%{?profile}" == "ivi"
247 export CFLAGS="$CFLAGS -DTIZEN_PROFILE_IVI"
248 %define _servicefile packaging/bluetooth-frwk-wearable.service
249 %define _servicedir multi-user.target.wants
250 %endif
251
252 %ifarch x86_64
253 #export CFLAGS="$CFLAGS -Wall -g -fvisibility=hidden -fPIC"
254 export CFLAGS="$CFLAGS -fpie"
255 export CFLAGS+=" -DARCH64"
256 export CXXFLAGS+=" -DARCH64"
257 export FFLAGS+=" -DARCH64"
258 %else
259 export CFLAGS="$CFLAGS -fpie"
260 export LDFLAGS="$CFLAGS -pie"
261 %endif
262
263 %if %{bt_bluez_hal} == ENABLED
264 export CFLAGS="$CFLAGS -DTIZEN_FEATURE_BT_RFCOMM_DIRECT -DTIZEN_BT_HAL"
265 %else
266 export CFLAGS="$CFLAGS -DTIZEN_FEATURE_BT_RFCOMM_DIRECT"
267 %endif
268 export LDFLAGS="$CFLAGS -Wl,--rpath=%{_libdir} -Wl,--as-needed -Wl,--unresolved-symbols=ignore-in-shared-libs"
269
270 %if %{bt_gatt_client_fd} == DISABLED
271 export CFLAGS="$CFLAGS -DTIZEN_FEATURE_BT_GATT_CLIENT_FD_DISABLE"
272 %endif
273
274 %if %{bt_permanent_log} == ENABLED
275 export CFLAGS="$CFLAGS -DTIZEN_FEATURE_BT_PERMANENT_LOG"
276 %endif
277
278 %if %{bt_http_proxy} == ENABLED
279 export CFLAGS="$CFLAGS -DTIZEN_FEATURE_BT_HTTP_PROXY"
280 %endif
281
282 %if %{bt_factory_mode} == ENABLED
283 export CFLAGS="$CFLAGS -DTIZEN_FEATURE_BT_FACTORY_MODE"
284 %endif
285
286 %ifarch %{ix86} x86_64
287 export CFLAGS+=" -DTIZEN_TEST_EMUL"
288 export CXXFLAGS+=" -DTIZEN_TEST_EMUL"
289 export FFLAGS+=" -DTIZEN_TEST_EMUL"
290 %endif
291
292 %if %{bt_bluez_hal} == ENABLED
293 export BT_INCLUDE_OAL_BLUEZ=ENABLED
294 export CFLAGS="$CFLAGS -DTIZEN_BT_INCLUDE_OAL_BLUEZ"
295 %else
296 export BT_INCLUDE_OAL_BLUEZ=DISABLED
297 %endif
298
299 export CFLAGS_DEFAULT="$CFLAGS"
300 export CXXFLAGS_DEFAULT="$CXXFLAGS"
301 export FFLAGS_DEFAULT="$FFLAGS"
302
303 # extension-TM1
304 %ifarch %{ix86} || %{arm}
305 mkdir -p tm1
306 export CFLAGS="$CFLAGS_DEFAULT -DTIZEN_FEATURE_RADIO -DTIZEN_FEATURE_BT_RFCOMM_DIRECT"
307 export CXXFLAGS="$CXXFLAGS_DEFAULT -DTIZEN_FEATURE_RADIO -DTIZEN_FEATURE_BT_RFCOMM_DIRECT"
308 export FFLAGS="$FFLAGS_DEFAULT -DTIZEN_FEATURE_RADIO -DTIZEN_FEATURE_BT_RFCOMM_DIRECT"
309
310 cmake . -DCMAKE_INSTALL_PREFIX=/usr \
311 -DCMAKE_LIB_DIR=%{_libdir} \
312 -DTZ_SYS_USER_GROUP=%TZ_SYS_USER_GROUP \
313 -DTZ_SYS_DEFAULT_USER=%TZ_SYS_DEFAULT_USER \
314         -DLIBNOTIFY_SUPPORT=Off \
315         -DLIBNOTIFICATION_SUPPORT=Off
316 make %{?_smp_mflags}
317
318 %cmake
319
320 %make_install
321 cp %{buildroot}%{_bindir}/bt-core tm1/bt-core.tm1
322 %endif
323
324 # extension-emulator
325 %ifarch %{ix86} x86_64
326 export CFLAGS="${CFLAGS} -DTIZEN_TEST_EMUL -DTIZEN_FEATURE_BT_RFCOMM_DIRECT"
327 export CXXFLAGS="${CXXFLAGS} -DTIZEN_TEST_EMUL -DTIZEN_FEATURE_BT_RFCOMM_DIRECT"
328 export FFLAGS="${FFLAGS} -DTIZEN_TEST_EMUL -DTIZEN_FEATURE_BT_RFCOMM_DIRECT"
329
330 mkdir -p build_emulator
331
332 cmake . -DCMAKE_INSTALL_PREFIX=/usr \
333 -DCMAKE_LIB_DIR=%{_libdir} \
334 -DTZ_SYS_USER_GROUP=%TZ_SYS_USER_GROUP \
335 -DTZ_SYS_DEFAULT_USER=%TZ_SYS_DEFAULT_USER \
336         -DLIBNOTIFY_SUPPORT=Off \
337         -DLIBNOTIFICATION_SUPPORT=Off
338 make %{?_smp_mflags}
339
340 %cmake
341
342 %make_install
343 cp %{buildroot}%{_libdir}/libbluetooth-api.so* build_emulator/
344 pushd build_emulator/
345 for FILE in libbluetooth-api.so*; do mv "${FILE}" "${FILE}.emulator"; done
346 popd
347 %endif
348
349 # non-extension-TM1 / non-extension-emulator
350
351 export CFLAGS="$CFLAGS_DEFAULT -DTIZEN_FEATURE_BT_RFCOMM_DIRECT"
352 export CXXFLAGS="$CXXFLAGS_DEFAULT -DTIZEN_FEATURE_BT_RFCOMM_DIRECT"
353 export FFLAGS="$FFLAGS_DEFAULT -DTIZEN_FEATURE_BT_RFCOMM_DIRECT"
354
355 %ifarch aarch64
356 echo arch64
357 export CFLAGS+=" -DARCH64"
358 export CXXFLAGS+=" -DARCH64"
359 export FFLAGS+=" -DARCH64"
360 %endif
361
362 cmake . -DCMAKE_INSTALL_PREFIX=/usr \
363 -DCMAKE_LIB_DIR=%{_libdir} \
364 -DTZ_SYS_USER_GROUP=%TZ_SYS_USER_GROUP \
365 -DTZ_SYS_DEFAULT_USER=%TZ_SYS_DEFAULT_USER \
366         -DLIBNOTIFY_SUPPORT=Off \
367         -DLIBNOTIFICATION_SUPPORT=Off
368 make %{?_smp_mflags}
369
370 %cmake
371
372 %install
373 rm -rf %{buildroot}
374 %make_install
375
376 mkdir -p %{buildroot}%{_unitdir}/starter.target.wants
377 mkdir -p %{buildroot}%{_unitdir}/delayed.target.wants
378 mkdir -p %{buildroot}%{_unitdir}/multi-user.target.wants
379 mkdir -p %{buildroot}/%{_prefix}/lib/udev/rules.d
380
381 cp packaging/99-bluetooth-rfkill.rules %{buildroot}/%{_prefix}/lib/udev/rules.d/99-bluetooth-rfkill.rules
382
383 # extension-emulator
384 %ifarch %{ix86} x86_64
385 cp build_emulator/libbluetooth-api.so*.emulator %{buildroot}%{_libdir}/
386 #mv %{buildroot}/%{_bindir}/bt-service-emul %{buildroot}/%{_bindir}/bt-service
387 %endif
388
389 # Rename the postfix (.mobile, .tv, ..) at post script
390 # mobile
391 install -m 0644 packaging/bluetooth-frwk-mobile.service %{buildroot}%{_unitdir}/bluetooth-frwk.service.mobile
392
393 # extension-TM1
394 %ifarch %{ix86} || %{arm}
395 cp tm1/bt-core.tm1 %{buildroot}%{_bindir}/
396 install -m 0644 packaging/bluetooth-frwk-mobile-sprd.service %{buildroot}%{_unitdir}/bluetooth-frwk.service.tm1
397 %endif
398
399 # wearable / ivi
400 install -m 0644 packaging/bluetooth-frwk-wearable.service %{buildroot}%{_unitdir}/bluetooth-frwk.service.wearable
401 # On IVI bt-service needs to be run as 'app' even if there is a 'guest' user.
402 cp %{buildroot}%{_datadir}/dbus-1/system-services/org.projectx.bt.service %{buildroot}%{_datadir}/dbus-1/system-services/org.projectx.bt.service.ivi
403 sed -i 's/%TZ_SYS_DEFAULT_USER/app/' %{buildroot}%{_datadir}/dbus-1/system-services/org.projectx.bt.service.ivi
404
405 # tv
406 install -m 0644 packaging/bluetooth-frwk-tv.service %{buildroot}%{_unitdir}/bluetooth-frwk.service.tv
407
408 # common
409 install -m 0644 packaging/bluetooth-frwk-common.service %{buildroot}%{_unitdir}/bluetooth-frwk.service.common
410
411 # bt-core
412 install -m 0644 bt-core/bluetooth-frwk-core.service %{buildroot}%{_unitdir}/bluetooth-frwk-core.service
413
414 ln -s ../bluetooth-frwk.service %{buildroot}%{_unitdir}/multi-user.target.wants/bluetooth-frwk.service
415 ln -s ../bluetooth-frwk.service %{buildroot}%{_unitdir}/starter.target.wants/bluetooth-frwk.service
416
417 %postun -p /sbin/ldconfig
418
419 %post service
420 /usr/bin/chsmack -a '_' %{_varlibdir}/bluetooth/auto-pair-blacklist
421 /usr/bin/chown network_fw:network_fw %{_varlibdir}/bluetooth/auto-pair-blacklist
422
423 %files
424 %manifest %{name}.manifest
425 %license LICENSE
426 %defattr(-, root, root)
427 %{_libdir}/libbluetooth-api.so.*
428 %exclude %{_libdir}/libbluetooth-api.so*.emulator
429
430 %files devel
431 %defattr(-, root, root)
432 %{_includedir}/bt-service/bluetooth-api.h
433 %{_includedir}/bt-service/bluetooth-hid-api.h
434 %{_includedir}/bt-service/bluetooth-audio-api.h
435 %{_includedir}/bt-service/bluetooth-telephony-api.h
436 %{_includedir}/bt-service/bluetooth-media-control.h
437 %{_includedir}/bt-service/bluetooth-scmst-api.h
438 %{_includedir}/bt-service/bluetooth-ipsp-api.h
439 %{_includedir}/bt-service/bluetooth-gatt-server-api.h
440 %{_includedir}/bt-service/bluetooth-gatt-client-api.h
441 %{_libdir}/pkgconfig/bluetooth-api.pc
442 %{_libdir}/libbluetooth-api.so
443
444 # extension-emulator
445 %ifarch %{ix86} x86_64
446 %post extension-emulator
447 pushd %{_libdir}
448 for FILE in libbluetooth-api.so*.emulator; do mv "${FILE}" "${FILE%.emulator}"; done
449 popd
450 %preun extension-emulator
451 pushd %{_libdir}
452 for FILE in libbluetooth-api.so*; do mv "${FILE}" "${FILE}.emulator"; done
453 popd
454 %files extension-emulator
455 %manifest %{name}.manifest
456 %defattr(-, root, root)
457 %{_libdir}/libbluetooth-api.so.*.emulator
458 %{_libdir}/libbluetooth-api.so.emulator
459 %endif
460
461 %files service
462 %manifest %{name}.manifest
463 %license LICENSE
464 %defattr(-, root, root)
465 %{_bindir}/bt-service
466 %{_sysconfdir}/dbus-1/system.d/bluetooth-frwk-service.conf
467 %{_bindir}/bluetooth-frwk-test
468 %{_varlibdir}/bluetooth
469 %{_prefix}/etc/bluetooth
470 %attr(-,network_fw,network_fw) %{_varlibdir}/bluetooth/auto-pair-blacklist
471
472 %if %{bt_http_proxy} == ENABLED
473 %files httpproxy
474 %manifest %{name}.manifest
475 %license LICENSE
476 %defattr(-, root, root)
477 %{_bindir}/bt-httpproxy
478 %{_datadir}/dbus-1/system-services/org.projectx.httpproxy.service
479 %{_sysconfdir}/dbus-1/system.d/bluetooth-frwk-httpproxy.conf
480 %endif
481
482 %files otp
483 %manifest %{name}.manifest
484 %license LICENSE
485 %defattr(-, root, root)
486 %{_bindir}/bt-otp
487 %{_datadir}/dbus-1/system-services/org.projectx.otp.service
488 %{_sysconfdir}/dbus-1/system.d/bluetooth-frwk-otp.conf
489
490 %files core
491 %manifest %{name}.manifest
492 %license LICENSE
493 %defattr(-, root, root)
494 %{_unitdir}/bluetooth-frwk-core.service
495 %{_datadir}/dbus-1/system-services/org.projectx.bt_core.service
496 %{_bindir}/bt-core
497 %{_sysconfdir}/dbus-1/system.d/bluetooth-frwk-core.conf
498 %{_prefix}/lib/udev/rules.d/99-bluetooth-rfkill.rules
499
500 %files test
501 %manifest %{name}.manifest
502 %license LICENSE
503 %defattr(-, root, root)
504 %{_bindir}/bluetooth-frwk-test
505 #%{_bindir}/bluetooth-gatt-test
506 #%{_bindir}/bluetooth-advertising-test
507
508 %files plugin-headed
509 %manifest %{name}.manifest
510 %license LICENSE
511 %defattr(-, root, root)
512 %{_libdir}/bt-plugin-headed.so
513
514 %post profile_common
515 pushd %{_unitdir}
516 mv bluetooth-frwk.service.common bluetooth-frwk.service
517 popd
518 %preun profile_common
519 pushd %{_unitdir}
520 mv bluetooth-frwk.service bluetooth-frwk.service.common
521 popd
522 %files profile_common
523 %license LICENSE
524 %{_unitdir}/multi-user.target.wants/bluetooth-frwk.service
525 %exclude %{_unitdir}/starter.target.wants/bluetooth-frwk.service
526 %{_unitdir}/bluetooth-frwk.service.common
527 %{_datadir}/dbus-1/system-services/org.projectx.bt.service
528
529 %post profile_mobile
530 pushd %{_unitdir}
531 mv bluetooth-frwk.service.mobile bluetooth-frwk.service
532 popd
533 %preun profile_mobile
534 pushd %{_unitdir}
535 mv bluetooth-frwk.service bluetooth-frwk.service.mobile
536 popd
537 %files profile_mobile
538 %license LICENSE
539 %{_unitdir}/multi-user.target.wants/bluetooth-frwk.service
540 %{_unitdir}/bluetooth-frwk.service.mobile
541 %{_datadir}/dbus-1/system-services/org.projectx.bt.service
542
543 # extension-TM1
544 %ifarch %{ix86} || %{arm}
545 %post extension-TM1
546 pushd %{_unitdir}
547 mv bluetooth-frwk.service.tm1 bluetooth-frwk.service
548 popd
549 pushd %{_bindir}
550 mv bt-core.tm1 bt-core
551 popd
552 %preun extension-TM1
553 pushd %{_unitdir}
554 mv bluetooth-frwk.service bluetooth-frwk.service.tm1
555 popd
556 pushd %{_bindir}
557 mv bt-core bt-core.tm1
558 popd
559 %files extension-TM1
560 %{_unitdir}/bluetooth-frwk.service.tm1
561 %license LICENSE
562 %defattr(-, root, root)
563 %{_bindir}/bt-core.tm1
564 %endif
565
566 %post profile_wearable
567 pushd %{_unitdir}
568 mv bluetooth-frwk.service.wearable bluetooth-frwk.service
569 popd
570 %preun profile_wearable
571 pushd %{_unitdir}
572 mv bluetooth-frwk.service bluetooth-frwk.service.wearable
573 popd
574 %files profile_wearable
575 %license LICENSE
576 %{_unitdir}/multi-user.target.wants/bluetooth-frwk.service
577 %{_unitdir}/bluetooth-frwk.service.wearable
578 %{_datadir}/dbus-1/system-services/org.projectx.bt.service
579
580 %post profile_tv
581 pushd %{_unitdir}
582 mv bluetooth-frwk.service.tv bluetooth-frwk.service
583 popd
584 %preun profile_tv
585 pushd %{_unitdir}
586 mv bluetooth-frwk.service bluetooth-frwk.service.tv
587 popd
588 %files profile_tv
589 %license LICENSE
590 %{_unitdir}/multi-user.target.wants/bluetooth-frwk.service
591 %{_unitdir}/bluetooth-frwk.service.tv
592 %{_datadir}/dbus-1/system-services/org.projectx.bt.service
593
594 # Note: ivi reuses bluetooth-frwk.service.wearable
595 %post profile_ivi
596 pushd %{_unitdir}
597 mv bluetooth-frwk.service.wearable bluetooth-frwk.service
598 popd
599 pushd %{_datadir}/dbus-1/system-services
600 mv org.projectx.bt.service.ivi org.projectx.bt.service
601 popd
602 %preun profile_ivi
603 pushd %{_unitdir}
604 mv bluetooth-frwk.service bluetooth-frwk.service.wearable
605 popd
606 pushd %{_datadir}/dbus-1/system-services
607 mv org.projectx.bt.service org.projectx.bt.service.ivi
608 popd
609 %files profile_ivi
610 %license LICENSE
611 %{_unitdir}/multi-user.target.wants/bluetooth-frwk.service
612 %{_unitdir}/bluetooth-frwk.service.wearable
613 %{_datadir}/dbus-1/system-services/org.projectx.bt.service.ivi
614
615 %files oal
616 %manifest %{name}.manifest
617 %defattr(-, root, root)
618 %{_libdir}/libbt-oal.so*
619 %{_sysconfdir}/dbus-1/system.d/bluetooth-frwk-gap-agent.conf
620
621 %if %{bt_bluez_hal} == ENABLED
622 %{_libdir}/libbluetooth.default.so*
623 %endif
624
625 %files -n bluetooth-haltests
626 %manifest %{name}.manifest
627 %{_bindir}/bluetooth-haltests