Luke Kenneth Casson Leighton wrote
as an example, 80% of all debian postinst (post install) packages
on my computer result in the running of update-menus.
you don't need to change the whole of the packages to implement the above
just add a few diverts, create some specific locks , and check on exit of APT
example:
$ dpkg-divert --rename /usr/bin/update-menus
--------- file /usr/bin/update-menus
#!/bin/sh
touch /var/lock/post-update-menus
-------- file /etc/apt/apt.conf.d/post-update-menus
DPkg {
Post-Invoke {"test -f /var/lock/post-update-menus && update-menus.distrib ; rm -f /var/lock/post-update-menus ";};
}
------------------
that's all folks the case of scrollkeeper is obviously the same. But I would not do this for ldconfig: what if a package needs a library it depends on to configure itself?
a.