-# test_type : one of 'GTEST'
-%define test_type GTEST
-
Name: capi-ui-autofill
Summary: Autofill Library
Version: 0.1.45
License: Apache-2.0
Source0: %{name}-%{version}.tar.gz
BuildRequires: cmake
-#%if "%{test_type}" == "GTEST"
-BuildRequires: pkgconfig(gmock)
-#%endif
BuildRequires: tidl
BuildRequires: pkgconfig(libtzplatform-config)
BuildRequires: pkgconfig(capi-base-common)
BuildRequires: pkgconfig(cynara-session)
BuildRequires: pkgconfig(capi-appfw-app-manager)
BuildRequires: pkgconfig(capi-appfw-preference)
+BuildRequires: pkgconfig(gmock)
+
Requires: org.tizen.autofilld
Requires(post): /sbin/ldconfig
Requires(postun): /sbin/ldconfig
%description -n capi-ui-autofill-common-devel
Autofill Common Library (Development)
-%if 0%{?gcov:1}
-%package -n capi-ui-autofill-common-gcov
-Summary: Autofill Common Library (gcov)
-Group: Graphics & UI Framework/Input
-%description -n capi-ui-autofill-common-gcov
-Autofill Common gcov objects
-%endif
-
%package -n capi-ui-autofill-service
Summary: Autofill Service Library
Group: Graphics & UI Framework/Input
%description -n capi-ui-autofill-service-devel
Autofill Service Library (Development)
-%if 0%{?gcov:1}
-%package -n capi-ui-autofill-service-gcov
-Summary: Autofill Service Library (gcov)
-Group: Graphics & UI Framework/Input
-%description -n capi-ui-autofill-service-gcov
-Autofill Service gcov objects
-%endif
-
%package -n capi-ui-autofill-manager
Summary: Autofill Manager Library
Group: Graphics & UI Framework/Input
%description -n capi-ui-autofill-manager-devel
Autofill Manager Library (Development)
-%if 0%{?gcov:1}
-%package -n capi-ui-autofill-manager-gcov
-Summary: Autofill Manager Library (gcov)
-Group: Graphics & UI Framework/Input
-%description -n capi-ui-autofill-manager-gcov
-Autofill Manager gcov objects
-%endif
-
%prep
%setup -q
%cmake . -DFULLVER=%{version} -DMAJORVER=${MAJORVER} -DTEST_TYPE=%{test_type}
make %{?jobs:-j%jobs}
+%install
+rm -rf %{buildroot}
+%make_install
+
%if 0%{?gcov:1}
-mkdir -p gcov-obj
find . -name '*_proxy.c.gcno' -exec rm {} \;
find . -name '*_stub.c.gcno' -exec rm {} \;
-find . -name '*.gcno' -exec cp '{}' gcov-obj ';'
-%endif
-%install
-rm -rf %{buildroot}
-%make_install
+find . -name '*.gcno' | tar cf %{name}-gcov.tar -T -
+install -d -m 755 %{buildroot}%{_datadir}/gcov/obj
+tar xf %{name}-gcov.tar -C %{buildroot}%{_datadir}/gcov/obj
+%endif
%check
ctest --output-on-failure %{?_smp_mflags}
genhtml gcov.info
%endif
-%if 0%{?gcov:1}
-mkdir -p %{buildroot}%{_datadir}/gcov/obj
-install -m 0644 gcov-obj/* %{buildroot}%{_datadir}/gcov/obj
-%endif
-
%post
/sbin/ldconfig
%if 0%{?gcov:1}
%files gcov
-%{_datadir}/gcov/obj/*
-
-%files -n capi-ui-autofill-common-gcov
-%{_datadir}/gcov/obj/*
-
-%files -n capi-ui-autofill-service-gcov
-%{_datadir}/gcov/obj/*
+%{_datadir}/gcov/*
-%files -n capi-ui-autofill-manager-gcov
-%{_datadir}/gcov/obj/*
%endif