From: Seungbae Shin Date: Mon, 8 Jul 2019 05:23:05 +0000 (+0900) Subject: Add gcov package for line coverage automation X-Git-Tag: accepted/tizen/5.5/unified/20191031.031838^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fheads%2Ftizen_5.5_wearable_hotfix;p=platform%2Fcore%2Fapi%2Ftone-player.git Add gcov package for line coverage automation [Version] 0.2.2 [Issue Type] Coverage Change-Id: I05d3e74ec139f771bece4f04bbd6a74b37f77c28 --- diff --git a/packaging/capi-media-tone-player.spec b/packaging/capi-media-tone-player.spec index e7db262..5f07d5e 100755 --- a/packaging/capi-media-tone-player.spec +++ b/packaging/capi-media-tone-player.spec @@ -1,6 +1,6 @@ Name: capi-media-tone-player Summary: A tone player library in Tizen C API -Version: 0.2.1 +Version: 0.2.2 Release: 0 Group: Multimedia/API License: Apache-2.0 @@ -24,7 +24,14 @@ Requires: %{name} = %{version}-%{release} %description devel %devel_desc +%if 0%{?gcov:1} +%package gcov +Summary: Line Coverage files +Group: Development/Multimedia +%description gcov +Collection of files related to line coverage using gcov. +%endif %prep %setup -q @@ -45,9 +52,19 @@ export LDFLAGS+=" -lgcov" 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 @@ -64,3 +81,8 @@ make %{?jobs:-j%jobs} %{_includedir}/media/*.h %{_libdir}/pkgconfig/*.pc %{_libdir}/libcapi-media-tone-player.so + +%if 0%{?gcov:1} +%files gcov +%{_datadir}/gcov/obj/* +%endif