Control: severity -1 minor
Control: retitle -1 dpkg: Man page not clear on re-inclusion behavior

Hi!

On Mon, 2017-08-07 at 15:26:36 -0500, Adam Heath wrote:
> package: dpkg
> version: 1.17.27
> 
> In the manpage for dpkg, there is an example for path-exclude/path-include:
> 
> ==
> --path-exclude=/usr/share/doc/*
> --path-include=/usr/share/doc/*/copyright
> ==
> 
> These 2 patterns will end up skipping packages that have
> /usr/share/doc/$foo as a symlink to another package.  Which means
> things like perl-base, libstdc++6, libgcc1, etc, which have their docs
> symlinked to another package from the same source, will be broken, as
> the copyright for the package is not available at
> /usr/share/doc/$pkg/copyright, as *required* by policy.

Policy requires shipping these files in the packages, it does not
require them to be present on the user filesystem. It also mentions
in ยง12.3 that no package can expect the existence of any files under
/usr/share/doc, which I've always understood as allowing local admins
to remove the entire hierarchy w/o consequence.

> Perhaps --path-exclude=/usr/share/doc/*/*, with the same include,
> might be better.

This is not necessary, as the current implementation will reinclude
any directory or symlink to a directory when there's a more specific
path reinclusion. This was already mentioned, but not directly, so
I've further clarified this behavior now in the man page and will be
included in the next release.

Thanks,
Guillem

Reply via email to