Add gcov environment 92/190292/1
authorSeokHoon Lee <andy.shlee@samsung.com>
Mon, 1 Oct 2018 00:46:26 +0000 (09:46 +0900)
committerSeokHoon Lee <andy.shlee@samsung.com>
Mon, 1 Oct 2018 00:46:45 +0000 (09:46 +0900)
Signed-off-by: SeokHoon Lee <andy.shlee@samsung.com>
Change-Id: Ic821a5677b3d33818998963c1d04e4e66f978ccd

packaging/capi-media-player.spec

index f26e671..9e913cc 100644 (file)
@@ -73,6 +73,13 @@ export CXXFLAGS="$CXXFLAGS -DTIZEN_DEBUG_ENABLE"
 export FFLAGS="$FFLAGS -DTIZEN_DEBUG_ENABLE"
 %endif
 export CFLAGS+=" -DEFL_BETA_API_SUPPORT -DPATH_LIBDIR=\\\"%{_libdir}\\\""
+
+%if 0%{?gcov:1}
+export CFLAGS+=" -fprofile-arcs -ftest-coverage"
+export CXXFLAGS+=" -fprofile-arcs -ftest-coverage"
+export LDFLAGS+=" -lgcov"
+%endif
+
 MAJORVER=`echo %{version} | awk 'BEGIN {FS="."}{print $1}'`
 %cmake . -DCMAKE_INSTALL_PREFIX=%{_prefix} -DFULLVER=%{version} -DMAJORVER=${MAJORVER} \
 %if "%{TIZEN_PRODUCT_TV}" == "1"