summaryrefslogtreecommitdiff
path: root/packaging
diff options
context:
space:
mode:
authorYunmi Ha <yunmi.ha@samsung.com>2021-08-11 16:37:23 +0900
committerYunmi Ha <yunmi.ha@samsung.com>2021-08-11 16:37:23 +0900
commit69319b9a5ae8fb66d479a64f70bde12cdeb45570 (patch)
tree85c5a117b6b664878b0c1f00e79106e21b1a7f57 /packaging
parentcbe6be9fcfdae70a4835eed29c6b37c9eac7edb3 (diff)
downloadsystem-info-69319b9a5ae8fb66d479a64f70bde12cdeb45570.tar.gz
system-info-69319b9a5ae8fb66d479a64f70bde12cdeb45570.tar.bz2
system-info-69319b9a5ae8fb66d479a64f70bde12cdeb45570.zip
Fix gbs build home creation with incorrect permissionssubmit/tizen/20210812.054845accepted/tizen/unified/20210817.123212
A gcda file is created when binary system_info_init_db is executed. At this time, the home directory is not created yet, so the home directory is created and the gcda file is created under it. But home directory with wrong permissions due to umask set to 0222 in the binary So, when build with gcov, set the home directory to the correct permissions Change-Id: Id7bac84bbfcd284e55f294ecc41ec826e904616c Signed-off-by: Yunmi Ha <yunmi.ha@samsung.com>
Diffstat (limited to 'packaging')
-rw-r--r--packaging/capi-system-info.spec9
1 files changed, 9 insertions, 0 deletions
diff --git a/packaging/capi-system-info.spec b/packaging/capi-system-info.spec
index 18f85bb..b2ae0af 100644
--- a/packaging/capi-system-info.spec
+++ b/packaging/capi-system-info.spec
@@ -111,6 +111,15 @@ install -m 0644 gcov-obj/* %{buildroot}%{_datadir}/gcov/obj
/usr/bin/system_info_init_db
/sbin/ldconfig
+%if 0%{?gcov:1}
+# A gcda file is created when binary system_info_init_db is executed.
+# At this time, the home directory is not created yet,
+# so the home directory is created and the gcda file is created under it.
+# But home directory with wrong permissions due to umask set to 0222 in the binary
+# So, when build with gcov, set the home directory to the correct permissions
+[ -d /home/abuild ] && chmod 755 /home/abuild
+%endif
+
%postun -p /sbin/ldconfig
%files