Hi Niels,
On Thu, Feb 22, 2024 at 07:32:21PM +0100, Niels Thykier wrote:
[...]
I am omitting Breaks, Conflicts, and Replaces because I am not aware of any
users of these at the moment. I am open to adding them, if there is a strong
use-case.
One generic case that this doesn't handle is Essential: yes packages. For
many of these, the ${shlibs:Depends} gets promoted in debian/control to
Pre-Depends, not to Depends.
Maybe it would make sense to auto-aggregate these substvars, *IFF* there is
not already a reference to the substvar in question in the package stanza in
debian/control? This would provide adequate flexibility for any other
exceptions that might be out there, beyond the Pre-Depends case.
Cheers,
dpkg-gencontrol reads information from an unpacked Debian source tree and generates a binary
package control file (which defaults to debian/tmp/DEBIAN/control); during this process it will
simplify the relation fields.
Thus Pre-Depends, Depends, Recommends and Suggests are simplified in this order by removing
dependencies which are known to be true according to the stronger dependencies already parsed.
It will also remove any self-dependency (in fact it will remove any dependency which evaluates
to true given the current version of the package as installed). Logically it keeps the
intersection of multiple dependencies on the same package. The order of dependencies is
preserved as best as possible: if any dependency must be discarded due to another dependency
appearing further in the field, the superseding dependency will take the place of the discarded
one.