Control: found -1 1.21.0 Control: notfound -1 1.21.1 since the issue really occurred in dpkg 1.21.0.
On 2022-01-13 13:17:42 +0100, Guillem Jover wrote: [...] Thanks for the explanations. > On Wed, 2022-01-12 at 14:17:17 +0100, Vincent Lefevre wrote: > > If this is the case, > > is there a way to know which alternatives are missing? Those that > > appear in /var/log/alternatives.log* while dpkg 1.20.0 was installed? > > As long as alternatives.log has been kept for long enough, I keep them for 1 year. :-) So, this was OK for me, except that this does not say which packages could be affected, i.e. which installed packages provide the considered alternative. > otherwise grepping for u-a in maintscripts in the dpkg db might be > more effective. This is more complex than just a grep due to continuation lines. For instance, /var/lib/dpkg/info/mlterm.postinst contains update-alternatives \ --install /usr/bin/x-terminal-emulator x-terminal-emulator /usr/bin/mlterm 20 \ --slave /usr/share/man/man1/x-terminal-emulator.1.gz x-terminal-emulator.1.gz /usr/share/man/man1/mlterm.1.gz So, if I'm not mistaken: pcregrep -Mr '^(.|\\\n)*update-alternatives(.|\\\n)*--install(.|\\\n)*\bx-terminal-emulator\b(.|\n)*?[^\\]$' /var/lib/dpkg/info based on the idea from <https://unix.stackexchange.com/a/207584/74516>. If there were a field in the control file, this could have been much easier (and could also be useful in a more general way, e.g. to search for non-installed packages providing some alternative). -- Vincent Lefèvre <vinc...@vinc17.net> - Web: <https://www.vinc17.net/> 100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/> Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)