d85e002d4ee6c0f850ccdbb4be7ad7d9dbf675af
[platform/core/api/connection.git] / packaging / capi-network-connection.spec
1 Name:           capi-network-connection
2 Summary:        Network Connection library in TIZEN C API
3 Version:        1.0.83
4 Release:        1
5 Group:          System/Network
6 License:        Apache-2.0
7 Source0:        %{name}-%{version}.tar.gz
8 BuildRequires:  cmake
9 BuildRequires:  pkgconfig(dlog)
10 BuildRequires:  pkgconfig(vconf)
11 BuildRequires:  pkgconfig(network)
12 BuildRequires:  pkgconfig(glib-2.0)
13 BuildRequires:  pkgconfig(capi-base-common)
14 BuildRequires:  pkgconfig(capi-system-info)
15 Requires(post):         /sbin/ldconfig
16 Requires(postun):       /sbin/ldconfig
17
18 %description
19 Network Connection library in Tizen C API
20
21 %package devel
22 Summary:        Network Connection library in Tizen C API (Development)
23 Group:          System/Network
24 Requires:       %{name} = %{version}-%{release}
25
26 %description devel
27 Network Connection library in Tizen C API (Development)
28
29 %prep
30 %setup -q
31
32
33 %build
34 export CFLAGS+=' -Wno-unused-local-typedefs -fprofile-arcs -ftest-coverage'
35 export LDFLAGS+=' -lgcov'
36 MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'`
37 cmake -DCMAKE_INSTALL_PREFIX=/usr -DFULLVER=%{version} -DMAJORVER=${MAJORVER} \
38         -DLIB_PATH=%{_lib} \
39 %if 0%{?model_build_feature_network_dsds} == 1
40         -DTIZEN_DUALSIM_ENABLE=1 \
41 %endif
42 %if "%{profile}" == "wearable"
43         -DTIZEN_WEARABLE=1 \
44 %else
45 %if "%{profile}" == "mobile"
46         -DTIZEN_MOBILE=1 \
47 %else
48 %if "%{profile}" == "tv"
49         -DTIZEN_TV=1 \
50 %endif
51 %endif
52 %endif
53         .
54
55 make %{?_smp_mflags}
56
57
58 %install
59 %make_install
60
61 #License
62 mkdir -p %{buildroot}%{_datadir}/license
63 cp LICENSE %{buildroot}%{_datadir}/license/capi-network-connection
64
65 %post -p /sbin/ldconfig
66
67 %postun -p /sbin/ldconfig
68
69
70 %files
71 %manifest capi-network-connection.manifest
72 %attr(644,-,-) %{_libdir}/libcapi-network-connection.so.*
73 %{_datadir}/license/capi-network-connection
74 %{_bindir}/connection_test
75
76 %files devel
77 %{_includedir}/network/*.h
78 %{_libdir}/pkgconfig/*.pc
79 %{_libdir}/libcapi-network-connection.so