1 diff -Naurp pacman-3.5.4/lib/libalpm/add.c pacman-3.5.4-run-pacman.d/lib/libalpm/add.c
2 --- pacman-3.5.4/lib/libalpm/add.c 2011-06-29 00:37:46.000000000 +0200
3 +++ pacman-3.5.4-run-pacman.d/lib/libalpm/add.c 2014-08-07 12:30:13.852075618 +0200
4 @@ -750,6 +750,8 @@ int _alpm_upgrade_packages(pmtrans_t *tr
5 _alpm_ldconfig(handle->root);
8 + _alpm_run_pacman_d(handle->root);
13 diff -Naurp pacman-3.5.4/lib/libalpm/remove.c pacman-3.5.4-run-pacman.d/lib/libalpm/remove.c
14 --- pacman-3.5.4/lib/libalpm/remove.c 2011-05-16 18:43:31.000000000 +0200
15 +++ pacman-3.5.4-run-pacman.d/lib/libalpm/remove.c 2014-08-07 12:30:27.435076005 +0200
16 @@ -465,6 +465,8 @@ int _alpm_remove_packages(pmtrans_t *tra
17 /* run ldconfig if it exists */
18 _alpm_ldconfig(handle->root);
20 + _alpm_run_pacman_d(handle->root);
25 diff -Naurp pacman-3.5.4/lib/libalpm/util.c pacman-3.5.4-run-pacman.d/lib/libalpm/util.c
26 --- pacman-3.5.4/lib/libalpm/util.c 2011-07-06 05:13:03.000000000 +0200
27 +++ pacman-3.5.4-run-pacman.d/lib/libalpm/util.c 2014-08-07 12:33:19.861080930 +0200
28 @@ -553,6 +553,21 @@ int _alpm_ldconfig(const char *root)
32 +int _alpm_run_pacman_d(const char *root)
34 + char line[PATH_MAX];
36 + _alpm_log(PM_LOG_DEBUG, "running run-parts pacman.d\n");
38 + snprintf(line, PATH_MAX, "%sbin/run-parts", root);
39 + if(access(line, X_OK) == 0) {
40 + char *argv[] = { "run-parts", "/etc/pacman.d", NULL };
41 + _alpm_run_chroot(root, "/bin/run-parts", argv);
47 /* Helper function for comparing strings using the
48 * alpm "compare func" signature */
49 int _alpm_str_cmp(const void *s1, const void *s2)
50 diff -Naurp pacman-3.5.4/lib/libalpm/util.h pacman-3.5.4-run-pacman.d/lib/libalpm/util.h
51 --- pacman-3.5.4/lib/libalpm/util.h 2011-07-06 05:13:03.000000000 +0200
52 +++ pacman-3.5.4-run-pacman.d/lib/libalpm/util.h 2014-08-07 12:33:48.720081754 +0200
53 @@ -91,6 +91,7 @@ int _alpm_rmrf(const char *path);
54 int _alpm_logaction(int usesyslog, FILE *f, const char *fmt, va_list args);
55 int _alpm_run_chroot(const char *root, const char *path, char *const argv[]);
56 int _alpm_ldconfig(const char *root);
57 +int _alpm_run_pacman_d(const char *root);
58 int _alpm_str_cmp(const void *s1, const void *s2);
59 char *_alpm_filecache_find(const char *filename);
60 const char *_alpm_filecache_setup(void);