Location setting restriction to support DPM
[platform/core/api/location-manager.git] / packaging / capi-location-manager.spec
1 Name: capi-location-manager
2 Summary: A Location Manager library in Tizen Native API
3 Version: 0.7.2
4 Release: 1
5 Group: Location/API
6 License: Apache-2.0
7 Source0: %{name}-%{version}.tar.gz
8 Source1001: %{name}.manifest
9 BuildRequires: cmake
10 BuildRequires: pkgconfig(dlog)
11 BuildRequires: pkgconfig(lbs-location)
12 BuildRequires: pkgconfig(capi-base-common)
13 BuildRequires: pkgconfig(capi-system-info)
14 BuildRequires: pkgconfig(vconf)
15 BuildRequires: pkgconfig(libtzplatform-config)
16 Requires(post): /sbin/ldconfig
17 Requires(postun): /sbin/ldconfig
18
19 %description
20 A Location Manager library in Tizen Native API
21
22
23 %package devel
24 Summary:  A Location Manager library in Tizen Native API (Development)
25 Group:    Location/Development
26 Requires: %{name} = %{version}-%{release}
27
28 %description devel
29 A Location Manager library in Tizen Native API (Development)
30
31
32 %prep
33 %setup -q
34 cp %{SOURCE1001} .
35
36 %build
37
38 export CFLAGS="$CFLAGS -DTIZEN_DEBUG_ENABLE"
39 export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE"
40 export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
41
42 MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'`
43 cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DLIBDIR=%{_libdir} -DINCLUDEDIR=%{_includedir} \
44 -DFULLVER=%{version} -DMAJORVER=${MAJORVER} -DTZ_SYS_RO_PACKAGES=%{TZ_SYS_RO_PACKAGES} -DTZ_SYS_RW_APP=%{TZ_SYS_RW_APP} \
45
46 make %{?jobs:-j%jobs}
47
48 %install
49 rm -rf %{buildroot}
50 %make_install
51
52 #mkdir -p %{buildroot}/usr/share/license
53 #cp LICENSE %{buildroot}/usr/share/license/%{name}
54
55 %post -p /sbin/ldconfig
56
57 %postun -p /sbin/ldconfig
58
59 %files
60 %manifest %{name}.manifest
61 %license LICENSE
62 %{_libdir}/libcapi-location-manager.so.*
63
64 %files devel
65 %{_includedir}/location/*.h
66 %{_libdir}/pkgconfig/*.pc
67 %{_libdir}/libcapi-location-manager.so
68
69
70 %if 1
71 %package test
72 Summary:    Test application of Location Manager
73 Group:      Location/Testing
74 Requires: %{name} = %{version}-%{release}
75
76 %description test
77 Test application of Location Manager
78
79 %files test
80 %manifest test/capi-location-manager-test.manifest
81 %{TZ_SYS_RO_PACKAGES}/capi-location-manager-test.xml
82 %{TZ_SYS_RW_APP}/test/location/location_test
83 %endif