Package: debhelper Version: 13.2 Severity: normal Wildcards work in executable "install" files, but not in executable "docs" files.
debhelper(7) says:
Otherwise, the output will be used exactly as-is. Notably, debhelper will
not expand wildcards or strip comments or strip whitespace in the output.
dh_install is probably an exception and globbing works because it's done later:
@install=filedoublearray($file); # no globbing here; done below
while dh_installdocs does it immediately (which is skipped on executable $file):
@docs = filearray($file, \@search_dirs, $error_handler);
I'm not sure if not expanding wildcards in executable "docs" etc. is a good
idea, since it prevents one from using something like
#!dh-exec
docs/*
docs-arm/* [arm64]
tiny example package attached:
$ fakeroot debian/rules binary
dh binary
dh_update_autotools_config
dh_autoreconf
create-stamp debian/debhelper-build-stamp
dh_testroot
dh_prep
dh_install
dh_installdocs
cp: cannot stat 'doc/*': No such file or directory
dh_installdocs: error: cp --reflink=auto -a doc/\*
debian/dhtest/usr/share/doc/dhtest returned exit code 1
make: *** [debian/rules:3: binary] Error 1
chmod -x debian/docs and it's fine ...
Andreas
PS: This limitation seems to be very vague:
Substitution limits
To avoid infinite loops and resource exhaustion, debhelper will stop
with an error
if the text contains many substitution variables (50) or [...]
Is that
- 50 distinct variables?
- 50 substitutions per line in the input?
- 50 substitutions in total? (What about large files with 100 lines with
${DEB_HOST_MULTIARCH}?)
- something different?
Andreas
dhtest.tar.gz
Description: application/gzip

