Name: capi-media-video-util
Summary: A Video Utility library in Tizen Native API
-Version: 0.1.12
+Version: 0.1.16
Release: 0
Group: System/Libraries
License: Apache-2.0
%description
A Video Utility library in Tizen Native API
-
%package devel
Summary: A Video Utility library in Tizen Native API (Developement)
Group: TO_BE_FILLED
%description devel
A Video Utility library in Tizen Native API (Developement)
+%if 0%{?gcov:1}
+%package gcov
+Summary: Line Coverage of Video Utility library in Tizen C API
+Group: Development/Multimedia
+
+%description gcov
+Collection of files related to Line Coverage. It is tested as gcov for a video utility library in Tizen native API
+%endif
+
%prep
%setup -q
cp %{SOURCE1001} .
%build
%if 0%{?gcov:1}
-export CFLAGS+=" -fprofile-arcs -ftest-coverage"
-export CXXFLAGS+=" -fprofile-arcs -ftest-coverage"
-export FFLAGS+=" -fprofile-arcs -ftest-coverage"
+export CFLAGS+=" -DTIZEN_EXCLUDE_COVERAGE -fprofile-arcs -ftest-coverage"
+export CXXFLAGS+=" -DTIZEN_EXCLUDE_COVERAG -fprofile-arcs -ftest-coverage"
+export FFLAGS+=" -DTIZEN_EXCLUDE_COVERAGE -fprofile-arcs -ftest-coverage"
export LDFLAGS+=" -lgcov"
%endif
MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'`
%cmake . -DFULLVER=%{version} -DMAJORVER=${MAJORVER}
make %{?jobs:-j%jobs}
+%if 0%{?gcov:1}
+mkdir -p gcov-obj
+find . -name '*.gcno' -exec cp '{}' gcov-obj ';'
+%endif
%install
%make_install
mkdir -p %{buildroot}%{_bindir}
cp test/video_util_test %{buildroot}%{_bindir}
+%if 0%{?gcov:1}
+mkdir -p %{buildroot}%{_datadir}/gcov/obj
+install -m 0644 gcov-obj/* %{buildroot}%{_datadir}/gcov/obj
+%endif
%post
%{_libdir}/pkgconfig/*.pc
%{_includedir}/media/*.h
+%if 0%{?gcov:1}
+%files gcov
+%{_datadir}/gcov/obj/*
+%endif