Remove contact dependency
[platform/core/connectivity/bluetooth-share.git] / packaging / bluetooth-share.spec
1 Name:       bluetooth-share
2 Summary:    Bluetooth file share Agent
3 Version:    0.0.47
4 Release:    0
5 Group:      Network & Connectivity/Bluetooth
6 License:    Apache-2.0
7 Source0:    %{name}-%{version}.tar.gz
8 Source1001: %{name}.manifest
9 Source1002: libbluetooth-share.manifest
10 Source1003: libbluetooth-share-devel.manifest
11 Source1004: init_db.sh
12 Requires(post): coreutils
13 Requires(post): sqlite
14 Requires(post): smack
15 BuildRequires:  cmake
16 BuildRequires:  gettext-tools
17 BuildRequires:  pkgconfig(appcore-efl)
18 BuildRequires:  pkgconfig(bluetooth-api)
19 BuildRequires:  pkgconfig(glib-2.0)
20 BuildRequires:  pkgconfig(dlog)
21 # Same check as in tizen-extensions-crosswalk. A per-package or global
22 # bcond would be better, but for now let's follow Crosswalk's approach.
23 #%if "%{profile}" == "mobile"
24 #BuildRequires:  pkgconfig(calendar-service2)
25 #BuildRequires:  pkgconfig(contacts-service2)
26 #%endif
27 BuildRequires:  pkgconfig(vconf)
28 BuildRequires:  pkgconfig(pmapi)
29 BuildRequires:  pkgconfig(sysman)
30 BuildRequires:  pkgconfig(notification)
31 BuildRequires:  pkgconfig(appsvc)
32 BuildRequires:  pkgconfig(db-util)
33 BuildRequires:  pkgconfig(libprivilege-control)
34 BuildRequires:  pkgconfig(capi-content-media-content)
35 BuildRequires:  pkgconfig(libtzplatform-config)
36
37 %description
38 Bluetooth File Share Agent
39
40 %package -n libbluetooth-share
41 Summary:    Bluetooth share library
42 Group:      Development/Libraries
43 Requires:   %{name} = %{version}-%{release}
44
45 %description -n libbluetooth-share
46 Bluetooth share library
47
48 %package -n libbluetooth-share-devel
49 Summary:    Development package for libbluetooth-share
50 Group:      Development/Libraries
51 Requires:   %{name} = %{version}-%{release}
52
53 %description -n libbluetooth-share-devel
54 Development package for libbluetooth-share
55
56 %prep
57 %setup -q
58 cp %{SOURCE1001} %{SOURCE1002} %{SOURCE1003} .
59
60 %build
61 export CFLAGS+=" -fpie -fvisibility=hidden"
62 export LDFLAGS+=" -Wl,--rpath=/usr/%{_libdir} -Wl,--as-needed -Wl,--unresolved-symbols=ignore-in-shared-libs -pie"
63
64 %cmake . \
65         -DTZ_SYS_ETC=%{TZ_SYS_ETC}
66 make
67
68 %install
69 %make_install
70 mkdir -p  %{buildroot}%{TZ_SYS_SHARE}/bt-ftp
71 install -D -m 0755 %{SOURCE1004} %{buildroot}%{TZ_SYS_SHARE}/%{name}/ressources/init_db.sh
72
73 %post -n libbluetooth-share-devel -p /sbin/ldconfig
74
75 %post -n libbluetooth-share -p /sbin/ldconfig
76
77 %postun -n libbluetooth-share-devel -p /sbin/ldconfig
78
79 %postun -n libbluetooth-share -p /sbin/ldconfig
80
81 %files
82 %manifest %{name}.manifest
83 %defattr(-,root,root,-)
84 %{_bindir}/bluetooth-share
85 %{_datadir}/dbus-1/system-services/org.bluetooth.share.service
86 %{TZ_SYS_SHARE}/bt-ftp
87 %{TZ_SYS_SHARE}/%{name}
88
89 %files -n libbluetooth-share
90 %manifest libbluetooth-share.manifest
91 %defattr(-, root, root)
92 %{_libdir}/libbluetooth-share-api.so.0.*
93
94 %files -n libbluetooth-share-devel
95 %manifest libbluetooth-share-devel.manifest
96 %defattr(-, root, root)
97 %{_includedir}/bluetooth-share-api/bluetooth-share-api.h
98 %{_libdir}/libbluetooth-share-api.so
99 %{_libdir}/pkgconfig/bluetooth-share-api.pc