Merge "Update deprecated libprivilege-control API functions." into tizen
[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): vconf
13 Requires(post): coreutils
14 Requires(post): sqlite
15 Requires(post): smack
16 BuildRequires:  cmake
17 BuildRequires:  gettext-tools
18 BuildRequires:  pkgconfig(appcore-efl)
19 BuildRequires:  pkgconfig(bluetooth-api)
20 BuildRequires:  pkgconfig(glib-2.0)
21 BuildRequires:  pkgconfig(aul)
22 BuildRequires:  pkgconfig(dlog)
23 BuildRequires:  pkgconfig(calendar-service2)
24 BuildRequires:  pkgconfig(contacts-service2)
25 BuildRequires:  pkgconfig(vconf)
26 BuildRequires:  pkgconfig(syspopup-caller)
27 BuildRequires:  pkgconfig(pmapi)
28 BuildRequires:  pkgconfig(sysman)
29 BuildRequires:  pkgconfig(notification)
30 BuildRequires:  pkgconfig(appsvc)
31 BuildRequires:  pkgconfig(db-util)
32 BuildRequires:  pkgconfig(libprivilege-control)
33 BuildRequires:  pkgconfig(capi-content-media-content)
34 BuildRequires:  pkgconfig(libtzplatform-config)
35
36 %description
37 Bluetooth File Share Agent
38
39 %package -n libbluetooth-share
40 Summary:    Bluetooth share library
41 Group:      Development/Libraries
42 Requires:   %{name} = %{version}-%{release}
43
44 %description -n libbluetooth-share
45 Bluetooth share library
46
47 %package -n libbluetooth-share-devel
48 Summary:    Development package for libbluetooth-share
49 Group:      Development/Libraries
50 Requires:   %{name} = %{version}-%{release}
51
52 %description -n libbluetooth-share-devel
53 Development package for libbluetooth-share
54
55 %prep
56 %setup -q
57 cp %{SOURCE1001} %{SOURCE1002} %{SOURCE1003} .
58
59 %build
60 export CFLAGS+=" -fpie -fvisibility=hidden"
61 export LDFLAGS+=" -Wl,--rpath=/usr/%{_libdir} -Wl,--as-needed -Wl,--unresolved-symbols=ignore-in-shared-libs -pie"
62
63 %cmake . \
64         -DTZ_SYS_ETC=%{TZ_SYS_ETC}
65 make
66
67 %install
68 %make_install
69 mkdir -p  %{buildroot}%{TZ_SYS_SHARE}/bt-ftp
70 install -D -m 0755 %{SOURCE1004} %{buildroot}%{TZ_SYS_SHARE}/%{name}/ressources/init_db.sh
71
72 %post -n libbluetooth-share-devel -p /sbin/ldconfig
73
74 %post -n libbluetooth-share -p /sbin/ldconfig
75
76 %postun -n libbluetooth-share-devel -p /sbin/ldconfig
77
78 %postun -n libbluetooth-share -p /sbin/ldconfig
79
80 %files
81 %manifest %{name}.manifest
82 %config %{TZ_SYS_ETC}/smack/accesses.d/bluetooth-share.rule
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