32 lines
1020 B
Diff
32 lines
1020 B
Diff
|
From c9ddb9648b3b810aa50fc238edb5fe55df9643b6 Mon Sep 17 00:00:00 2001
|
||
|
From: "Richard W.M. Jones" <rjones@redhat.com>
|
||
|
Date: Fri, 29 Apr 2022 15:24:41 +0100
|
||
|
Subject: [PATCH 03/12] pacman: Fix database mtime detection
|
||
|
|
||
|
There is no "core.db" file on Artix, it may exist on Arch. However
|
||
|
a better way to detect this is to check the mtime of the containing
|
||
|
directory.
|
||
|
---
|
||
|
src/ph_pacman.ml | 5 ++++-
|
||
|
1 file changed, 4 insertions(+), 1 deletion(-)
|
||
|
|
||
|
diff --git a/src/ph_pacman.ml b/src/ph_pacman.ml
|
||
|
index 4a1c669..d9ecb29 100644
|
||
|
--- a/src/ph_pacman.ml
|
||
|
+++ b/src/ph_pacman.ml
|
||
|
@@ -129,7 +129,10 @@ let pacman_package_name pkg =
|
||
|
pac.name
|
||
|
|
||
|
let pacman_get_package_database_mtime () =
|
||
|
- (lstat "/var/lib/pacman/sync/core.db" (* XXX? *) ).st_mtime
|
||
|
+ (* This directory changes mtime when packages get installed/reinstalled.
|
||
|
+ * The directory itself contains several *.db files with different names.
|
||
|
+ *)
|
||
|
+ (lstat "/var/lib/pacman/sync/").st_mtime
|
||
|
|
||
|
let pacman_get_all_requires pkgs =
|
||
|
let cmd = sprintf "\
|
||
|
--
|
||
|
2.37.3
|
||
|
|