Name: capi-network-ua Summary: User Awareness Framework CAPI Version: 0.7.3 Release: 1 License: Apache-2.0 Source0: %{name}-%{version}.tar.gz BuildRequires: cmake BuildRequires: pkgconfig(dlog) BuildRequires: pkgconfig(glib-2.0) BuildRequires: pkgconfig(ua-api) %if 0%{?suspend_resume_test:1} BuildRequires: pkgconfig(deviced) BuildRequires: pkgconfig(power-defs) %endif %define _confdir /opt/data %description Activity API Library %package devel Summary: User Awareness Framework CAPI (devel) Requires: %{name} = %{version} %description devel User Awareness Framework CAPI %package test Summary: User Awareness Framework test application Group: TO_BE/FILLED Requires: %{name} = %{version}-%{release} %description test This package is for User Awareness Framework CAPI test application %if 0%{?gcov:1} %package gcov Summary: A User Awareness gcov Tool Group: Network & Connectivity/Development %description gcov User Awareness gcov objects %endif %prep %setup -q %build %if 0%{?gcov:1} export LDFLAGS+=" -lgcov" %endif MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'` cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} \ -DLIB_INSTALL_DIR=%{_libdir} \ -DBIN_INSTALL_DIR=%{_bindir} \ -DINCLUDE_INSTALL_DIR=%{_includedir} \ -DLIB_PATH=%{_lib} \ -DSUSPEND_RESUME_TEST=%{?suspend_resume_test:1}%{!?suspend_resume_test:0} \ -DFULLVER=%{version} \ -DMAJORVER=${MAJORVER} \ -DBUILD_GCOV=%{?gcov:1}%{!?gcov:0} make %{?jobs:-j%jobs} %if 0%{?gcov:1} mkdir -p gcov-obj find . -name '*.gcno' -exec cp '{}' gcov-obj ';' %endif %install %make_install %if 0%{?gcov:1} mkdir -p %{buildroot}%{_datadir}/gcov/obj install -m 0644 gcov-obj/* %{buildroot}%{_datadir}/gcov/obj %endif %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files %manifest %{name}.manifest %defattr(-,root,root,-) %license LICENSE %attr(644,-,-) %{_libdir}/lib%{name}.so %attr(644,-,-) %{_libdir}/lib%{name}.so.* %files devel %manifest %{name}-devel.manifest %defattr(-,root,root,-) %{_libdir}/pkgconfig/%{name}.pc %{_includedir}/* %files test %manifest %{name}.manifest %attr(777,network_fw,network_fw) %{_bindir}/ua-test %if 0%{?gcov:1} %files gcov %{_datadir}/gcov/obj/* %endif