On 13/10/23 07:54, Niels Thykier wrote:
`dh_install` is a special snowflake of doing everything differently than anything else. The `dh_install` helper manually does the glob'ing rather than using the `filedoublearray` for glob expansion.
[...]

For everything else, glob support should be done by the executable itself (possibly indirectly via dh-exec).

Hi Niels,

allow me, for the sake of argument, to champion the idea that what `dh_install` does should done also by `dh_installman` (and others).

Independently from the implementation, I was quite surprised when I realized, through trial and error, that just adding `#!/usr/bin/dh-exec` to a `.manpages` file required two additional changes:

1) turning the glob patterns into exact paths, and
2) prefix each entry with `debian/tmp/`.

Although technically justified and documented in the man page, this goes against the Principle of Least Astonishment for debhelper users.

(This is as surprising as the need to change debian/tmp/ into debian/pkg/ when going from multi- to single-binary package.)

Making `dh_installman` behave like `dh_install` would not be a breaking change. Currently no `.manpages` file use both globs and dh-exec (they would not work), so enabling glob expansion would be a backward compatible change.

Regards,

--
Gioele Barabucci

Reply via email to