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