summaryrefslogtreecommitdiff
path: root/config
diff options
context:
space:
mode:
authorFrank Ch. Eigler <fche@redhat.com>2020-10-30 19:14:02 -0400
committerFrank Ch. Eigler <fche@redhat.com>2020-10-30 19:38:42 -0400
commitb256093ad9a8b4972ae02bece266adad8a3c6dbd (patch)
tree501a8b4e815559fa9c94b1d9dd675d6835bf4ab1 /config
parent736cd2e2b57bbcb950da8bd255e4aa72302dd78c (diff)
downloadelfutils-b256093ad9a8b4972ae02bece266adad8a3c6dbd.tar.gz
elfutils.spec.in: fix debuginfod state/config file flags
During a test upgrade of an RPM based on this spec file, it was observed that, er, the /var/cache/.../debuginfod.sqlite file was zeroed. Whoops! We don't want to lose this data. Removed the %verify attributes and added %ghost for the sqlite database. Signed-off-by: Frank Ch. Eigler <fche@redhat.com>
Diffstat (limited to 'config')
-rw-r--r--config/ChangeLog5
-rw-r--r--config/elfutils.spec.in8
2 files changed, 10 insertions, 3 deletions
diff --git a/config/ChangeLog b/config/ChangeLog
index f93bbfd7..d280511d 100644
--- a/config/ChangeLog
+++ b/config/ChangeLog
@@ -1,3 +1,8 @@
+2020-10-30 Frank Ch. Eigler <fche@redhat.com>
+
+ * elfutils.spec.in: Fix debuginfod config/state file attributes
+ for non-lossy updates.
+
2020-10-08 Frank Ch. Eigler <fche@redhat.com>
* Makefile.am (uninstall-local): Uninstall the new profile.d files.
diff --git a/config/elfutils.spec.in b/config/elfutils.spec.in
index 170c95e5..3caca9a6 100644
--- a/config/elfutils.spec.in
+++ b/config/elfutils.spec.in
@@ -191,6 +191,8 @@ mkdir -p ${RPM_BUILD_ROOT}%{_prefix}
%make_install
chmod +x ${RPM_BUILD_ROOT}%{_prefix}/%{_lib}/lib*.so*
+mkdir -p ${RPM_BUILD_ROOT}%{_localstatedir}/cache/debuginfod
+touch ${RPM_BUILD_ROOT}%{_localstatedir}/cache/debuginfod/debuginfod.sqlite
# XXX Nuke unpackaged files
( cd ${RPM_BUILD_ROOT}
@@ -296,7 +298,7 @@ fi
%{_libdir}/libdebuginfod.so.*
%{_bindir}/debuginfod-find
%{_mandir}/man1/debuginfod-find.1*
-%config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/profile.d/*
+%config(noreplace) %{_sysconfdir}/profile.d/*
%files debuginfod-client-devel
%defattr(-,root,root)
@@ -308,13 +310,13 @@ fi
%files debuginfod
%defattr(-,root,root)
%{_bindir}/debuginfod
-%config(noreplace) %verify(not md5 size mtime) %{_sysconfdir}/sysconfig/debuginfod
+%config(noreplace) %{_sysconfdir}/sysconfig/debuginfod
%{_unitdir}/debuginfod.service
%{_sysconfdir}/sysconfig/debuginfod
%{_mandir}/man8/debuginfod.8*
%dir %attr(0700,debuginfod,debuginfod) %{_localstatedir}/cache/debuginfod
-%verify(not md5 size mtime) %attr(0600,debuginfod,debuginfod) %{_localstatedir}/cache/debuginfod/debuginfod.sqlite
+%ghost %attr(0600,debuginfod,debuginfod) %{_localstatedir}/cache/debuginfod/debuginfod.sqlite
%pre debuginfod
getent group debuginfod >/dev/null || groupadd -r debuginfod