X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=dh_install;h=4bd584b54f7c3439ce8ef5fbd85681a01ca898b8;hb=4ac0a7b9288220f00c948225ac659419ffc08110;hp=779b9d6e73564033aa3b63d5c840a16654cff801;hpb=8d285c73f8a1d8f4b632100ce764893f3d704068;p=debhelper.git diff --git a/dh_install b/dh_install index 779b9d6..4bd584b 100755 --- a/dh_install +++ b/dh_install @@ -62,7 +62,8 @@ filename. So if the filename is debian/tmp/usr/bin, then that directory will be copied to debian/package/usr/. If the filename is debian/tmp/etc/passwd, it will be copied to debian/package/etc/. -Note that if you list only a filename on a line by itself in a +Note that if you list exactly one filename or wildcard-pattern on a line by +itself in a debian/package.install file, with no explicit destination, then dh_install will automatically guess the destination even if this flag is not set. @@ -137,7 +138,12 @@ foreach my $package (@{$dh{DOPACKAGES}}) { if (! defined $dh{AUTODEST} && @$set > 1) { $dest=pop @$set; } - # glob now, relative to srcdir + if (! compat(4)) { # check added in v5 + # glob now, relative to srcdir + if (! map { glob "$srcdir/$_" } @$set) { + error("$package missing files (@$set), aborting"); + } + } foreach my $src (map { glob "$srcdir/$_" } @$set) { next if excludefile($src); @@ -197,14 +203,18 @@ if ($dh{LIST_MISSING} || $dh{FAIL_MISSING}) { my @missing; my $installed=join("|", @installed); - $installed=qr{^$installed$}; + $installed=qr{^($installed)$}; find(sub { -f || -l || return; $_="$File::Find::dir/$_"; - push @missing, $_ unless /$installed/ || excludefile($_); + if (! /$installed/ && ! excludefile($_)) { + my $file=$_; + $file=~s/^\Q$srcdir\E\///; + push @missing, $file; + } }, $srcdir); if (@missing) { - warning "$_ exists in debian/tmp but not installed to anywhere" foreach @missing; + warning "$_ exists in debian/tmp but is not installed to anywhere" foreach @missing; if ($dh{FAIL_MISSING}) { error("missing files, aborting"); } @@ -224,7 +234,7 @@ contain: While debian/libfoo.install contains: - usr/libfoo*.so.* + usr/lib/libfoo*.so.* If you want a libfoo-dev package too, debian/libfoo-dev.install might contain: