summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichał Górny <mgorny@gentoo.org>2017-08-16 18:05:31 +0200
committerMichał Górny <mgorny@gentoo.org>2017-08-26 23:16:15 +0200
commit028e76a38749c38e3661a204a5aaa5962fd55410 (patch)
tree7f836ac9f6fbbe58e070ababdb5f99221d881f34
parentAdd post-postinst checks for a few missed cache updates (diff)
downloadportage-028e76a38749c38e3661a204a5aaa5962fd55410.tar.gz
portage-028e76a38749c38e3661a204a5aaa5962fd55410.tar.bz2
portage-028e76a38749c38e3661a204a5aaa5962fd55410.zip
Use ctime in cache post-postinst checks
Use ctime rather than mtime in cache post-postinst checks since mtime may be preserved from the original tarball, and therefore be 'long time ago'. ctime is more reliable in this regard. Reviewed-by: Zac Medico <zmedico@gentoo.org>
-rw-r--r--bin/postinst-qa-check.d/50gnome2-utils2
-rw-r--r--bin/postinst-qa-check.d/50xdg-utils4
2 files changed, 3 insertions, 3 deletions
diff --git a/bin/postinst-qa-check.d/50gnome2-utils b/bin/postinst-qa-check.d/50gnome2-utils
index 68e21cb74..4e7c6eb85 100644
--- a/bin/postinst-qa-check.d/50gnome2-utils
+++ b/bin/postinst-qa-check.d/50gnome2-utils
@@ -10,7 +10,7 @@ gnome2_icon_cache_check() {
# if the cache does not exist at all, we complain for any file
# otherwise, we look for files newer than the cache
[[ -f ${d}/icon-theme.cache ]] &&
- find_args+=( -newer "${d}"/icon-theme.cache )
+ find_args+=( -newercm "${d}"/icon-theme.cache )
# (use -mindepth 2 to easily skip the cache files)
while read -r -d $'\0' f; do
diff --git a/bin/postinst-qa-check.d/50xdg-utils b/bin/postinst-qa-check.d/50xdg-utils
index 4bc7bee9a..b0bb029bd 100644
--- a/bin/postinst-qa-check.d/50xdg-utils
+++ b/bin/postinst-qa-check.d/50xdg-utils
@@ -9,7 +9,7 @@ xdg_desktop_database_check() {
# if the cache does not exist at all, we complain for any file
# otherwise, we look for files newer than the cache
[[ -f ${d}/mimeinfo.cache ]] &&
- find_args+=( -newer "${d}"/mimeinfo.cache )
+ find_args+=( -newercm "${d}"/mimeinfo.cache )
# look for any .desktop files that are newer than the cache
# and that have any mime types defined
@@ -37,7 +37,7 @@ xdg_mimeinfo_database_check() {
# if the cache does not exist at all, we complain for any file
# otherwise, we look for files newer than the cache
[[ -f ${d}/mime.cache ]] &&
- find_args+=( -newer "${d}"/mime.cache )
+ find_args+=( -newercm "${d}"/mime.cache )
while read -r -d $'\0' f; do
files+=( "${f}" )