BuildRequires: pkgconfig(capi-network-connection)
BuildRequires: pkgconfig(alarm-service)
BuildRequires: pkgconfig(capi-content-mime-type)
-BuildRequires: pkgconfig(pkgmgr)
-#BuildRequires: pkgconfig(journal)
BuildRequires: pkgconfig(eventsystem)
BuildRequires: pkgconfig(libsoup-2.4)
BuildRequires: pkgconfig(capi-network-tethering)
BuildRequires: pkgconfig(storage)
BuildRequires: pkgconfig(capi-system-info)
BuildRequires: pkgconfig(capi-appfw-app-control)
+BuildRequires: pkgconfig(gmock)
Requires(post): /usr/bin/vconftool
Requires(post): /sbin/ldconfig
%description plugin-headed
This package is Bluetooth plugin to manage UI and syspopup
+%package -n bluetooth-haltests
+Summary: HAL Test package for bluetooth OAL
+Group: TO_BE/FILLED
+Requires: %{name} = %{version}-%{release}
+
+%description -n bluetooth-haltests
+This package is C-API test application.
+
%prep
%setup -q
cp %{SOURCE1001} .
export CFLAGS="$CFLAGS -DTIZEN_FEATURE_BT_IPSP"
export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE"
export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
+export CFLAGS="$CFLAGS -DTIZEN_GATT_CLIENT"
%define _servicefile packaging/bluetooth-frwk-common.service
%define _servicedir starter.target.wants
export CXXFLAGS="$CXXFLAGS_DEFAULT -DTIZEN_FEATURE_BT_RFCOMM_DIRECT"
export FFLAGS="$FFLAGS_DEFAULT -DTIZEN_FEATURE_BT_RFCOMM_DIRECT"
+%ifarch aarch64
+echo arch64
+export CFLAGS+=" -DARCH64"
+export CXXFLAGS+=" -DARCH64"
+export FFLAGS+=" -DARCH64"
+%endif
+
cmake . -DCMAKE_INSTALL_PREFIX=/usr \
-DCMAKE_LIB_DIR=%{_libdir} \
-DTZ_SYS_USER_GROUP=%TZ_SYS_USER_GROUP \
mkdir -p %{buildroot}%{_unitdir}/starter.target.wants
mkdir -p %{buildroot}%{_unitdir}/multi-user.target.wants
+mkdir -p %{buildroot}/%{_prefix}/lib/udev/rules.d
+
+cp packaging/99-bluetooth-rfkill.rules %{buildroot}/%{_prefix}/lib/udev/rules.d/99-bluetooth-rfkill.rules
# extension-emulator
%ifarch %{ix86} x86_64
# common
install -m 0644 packaging/bluetooth-frwk-common.service %{buildroot}%{_unitdir}/bluetooth-frwk.service.common
+# bt-core
+install -m 0644 bt-core/bluetooth-frwk-core.service %{buildroot}%{_unitdir}/bluetooth-frwk-core.service
+
+
ln -s ../bluetooth-frwk.service %{buildroot}%{_unitdir}/multi-user.target.wants/bluetooth-frwk.service
ln -s ../bluetooth-frwk.service %{buildroot}%{_unitdir}/starter.target.wants/bluetooth-frwk.service
+%post core
+mkdir -p %{_sysconfdir}/systemd/default-extra-dependencies/ignore-units.d
+ln -sf %{_libdir}/systemd/system/bluetooth-frwk-core.service %{_libdir}/systemd/system/multi-user.target.wants/bluetooth-frwk-core.service
+ln -sf %{_libdir}/systemd/system/bluetooth-frwk-core.service %{_sysconfdir}/systemd/default-extra-dependencies/ignore-units.d/
+
+
%postun -p /sbin/ldconfig
%post service
/usr/bin/chsmack -a '_' %{_varlibdir}/bluetooth/auto-pair-blacklist
-/usr/bin/chown 5001:100 %{_varlibdir}/bluetooth/auto-pair-blacklist
+/usr/bin/chown network_fw:network_fw %{_varlibdir}/bluetooth/auto-pair-blacklist
%files
%manifest %{name}.manifest
%{_includedir}/bt-service/bluetooth-scmst-api.h
%{_includedir}/bt-service/bluetooth-ipsp-api.h
%{_includedir}/bt-service/bluetooth-gatt-server-api.h
+%{_includedir}/bt-service/bluetooth-gatt-client-api.h
%{_libdir}/pkgconfig/bluetooth-api.pc
%{_libdir}/libbluetooth-api.so
%{_bindir}/bluetooth-frwk-test
%{_varlibdir}/bluetooth
%{_prefix}/etc/bluetooth
-%attr(-,owner,users) %{_varlibdir}/bluetooth/auto-pair-blacklist
+%attr(-,network_fw,network_fw) %{_varlibdir}/bluetooth/auto-pair-blacklist
%files httpproxy
%manifest %{name}.manifest
%manifest %{name}.manifest
%license LICENSE
%defattr(-, root, root)
+%{_unitdir}/bluetooth-frwk-core.service
%{_datadir}/dbus-1/system-services/org.projectx.bt_core.service
%{_bindir}/bt-core
%{_sysconfdir}/dbus-1/system.d/bluetooth-frwk-core.conf
+%{_prefix}/lib/udev/rules.d/99-bluetooth-rfkill.rules
%files test
%manifest %{name}.manifest
popd
%files profile_common
%license LICENSE
-%{_unitdir}/starter.target.wants/bluetooth-frwk.service
+%{_unitdir}/multi-user.target.wants/bluetooth-frwk.service
+%exclude %{_unitdir}/starter.target.wants/bluetooth-frwk.service
%{_unitdir}/bluetooth-frwk.service.common
%{_datadir}/dbus-1/system-services/org.projectx.bt.service
%files oal
%manifest %{name}.manifest
+%defattr(-, root, root)
%{_libdir}/libbt-oal.so*
+%{_sysconfdir}/dbus-1/system.d/bluetooth-frwk-gap-agent.conf
%if %{bt_bluez_hal} == ENABLED
-%manifest %{name}.manifest
%{_libdir}/libbluetooth.default.so*
%endif
+
+%files -n bluetooth-haltests
+%manifest %{name}.manifest
+%{_bindir}/bluetooth-haltests