Name: appcore-widget
Summary: Widget Application
-Version: 1.2.13
+Version: 1.3.11
Release: 1
Group: Application Framework/Libraries
License: Apache-2.0
BuildRequires: pkgconfig(aul)
BuildRequires: pkgconfig(dlog)
BuildRequires: pkgconfig(elementary)
-BuildRequires: pkgconfig(vconf)
-BuildRequires: pkgconfig(vconf-internal-keys)
BuildRequires: pkgconfig(appcore-common)
BuildRequires: pkgconfig(capi-appfw-app-common)
BuildRequires: pkgconfig(widget_service)
BuildRequires: pkgconfig(ecore-wl2)
BuildRequires: pkgconfig(appcore-multiwindow)
BuildRequires: pkgconfig(screen_connector_provider)
+BuildRequires: pkgconfig(gmock)
BuildRequires: cmake
+%if 0%{?gcov:1}
+BuildRequires: lcov
+BuildRequires: zip
+%endif
+
%description
Widget base
%description -n capi-appfw-widget-application-devel
widget application (development files)
+%package -n appcore_widget_unittests
+Summary: GTest for appcore-widget
+Group: Development/Libraries
+%description -n appcore_widget_unittests
+GTest for appcore-widget
+
+
+%if 0%{?gcov:1}
+%package gcov
+Summary: Widget application API(gcov)
+Group: Application Framework/Libraries
+
+%description gcov
+gcov objects of a widget application library
+%endif
+
%prep
%setup -q
%build
+%if 0%{?gcov:1}
+export CFLAGS+=" -fprofile-arcs -ftest-coverage"
+export CXXFLAGS+=" -fprofile-arcs -ftest-coverage"
+export FFLAGS+=" -fprofile-arcs -ftest-coverage"
+export LDFLAGS+=" -lgcov"
+%endif
+
export CFLAGS+=" -DEFL_BETA_API_SUPPORT "
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
rm -rf %{buildroot}
%make_install
+%if 0%{?gcov:1}
+mkdir -p %{buildroot}%{_datadir}/gcov/obj
+install -m 0644 gcov-obj/* %{buildroot}%{_datadir}/gcov/obj
+%endif
+
mkdir -p %{buildroot}%{_libdir}/pkgconfig
cp capi-appfw-widget-application.pc %{buildroot}%{_libdir}/pkgconfig
+%check
+export LD_LIBRARY_PATH=../../src/base:../../src/efl_base
+ctest -V
+%if 0%{?gcov:1}
+lcov -c --ignore-errors graph --no-external -q -d . -o appcore-widget.info
+genhtml appcore-widget.info -o appcore-widget.out
+zip -r appcore-widget.zip appcore-widget.out
+install -m 0644 appcore-widget.zip %{buildroot}%{_datadir}/gcov/
+%endif
+
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%{_libdir}/pkgconfig/capi-appfw-widget-application.pc
%{_libdir}/libcapi-appfw-widget-application.so
+%if 0%{?gcov:1}
+%files gcov
+%{_datadir}/gcov/*
+%endif