From 6f4d963e1a2e2a4ac870f8f65a45ff0071fe7cf6 Mon Sep 17 00:00:00 2001 From: Jihoon Kim Date: Tue, 19 Mar 2024 10:55:44 +0900 Subject: [PATCH] Add option to execute unittest in building package Change-Id: I29c5de4eaeb9abd116a4aa26efa26d9d3bcf60fb Signed-off-by: Jihoon Kim --- packaging/capi-ui-sticker.spec | 2 ++ 1 file changed, 2 insertions(+) diff --git a/packaging/capi-ui-sticker.spec b/packaging/capi-ui-sticker.spec index 99bc0c4..031c8a9 100644 --- a/packaging/capi-ui-sticker.spec +++ b/packaging/capi-ui-sticker.spec @@ -183,12 +183,14 @@ install -m 0644 %SOURCE3 %{buildroot}%{_sysconfdir}/dbus-1/system.d/capi-ui-stic %check %if 0%{?gcov:1} +%if 0%{?run_unittest:1} ctest --output-on-failure %{?_smp_mflags} lcov -c --ignore-errors mismatch,graph,unused --no-external -q -d . -o capi-ui-sticker.info genhtml capi-ui-sticker.info -o capi-ui-sticker.out zip -r capi-ui-sticker.zip capi-ui-sticker.out capi-ui-sticker.info install -m 0644 capi-ui-sticker.zip %{buildroot}%{_datadir}/gcov %endif +%endif %post /sbin/ldconfig -- 2.7.4