[debhelper-devel] [debhelper] 09/17: dh_missing: Proper error messages for missing $srcdir
Niels Thykier
nthykier at moszumanska.debian.org
Sat Apr 8 08:58:10 UTC 2017
This is an automated email from the git hooks/post-receive script.
nthykier pushed a commit to branch master
in repository debhelper.
commit 5c1ae232035f03447a71af38352794b6a6b9f037
Author: Niels Thykier <niels at thykier.net>
Date: Mon Apr 3 10:12:19 2017 +0000
dh_missing: Proper error messages for missing $srcdir
Signed-off-by: Niels Thykier <niels at thykier.net>
---
dh_missing | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/dh_missing b/dh_missing
index b3c7848..0ec3202 100755
--- a/dh_missing
+++ b/dh_missing
@@ -81,6 +81,21 @@ if ($srcdir eq '.') {
$srcdir='debian/tmp';
}
+if (! -d $srcdir) {
+ if (scalar(getpackages()) == 1 && not defined($dh{SOURCEDIR})) {
+ warning("$srcdir does not exist and there is only binary package.");
+ warning("Assuming everything is installed directly into the package directory.");
+ exit(0);
+ }
+ if (compat(10)) {
+ # Prevent "dh $@ --list-missing --destdir=..." from failing in compat 10.
+ warning("Cannot check if installation is missing files: $srcdir does not exist");
+ exit(0);
+ } else {
+ error("Cannot check if installation is missing files: $srcdir does not exist");
+ }
+}
+
for my $file (<debian/.debhelper/generated/*/installed-by-*>) {
local $/ = undef;
open(my $fh, '<', $file) or die "could not open $file: $!";
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debhelper/debhelper.git
More information about the debhelper-devel
mailing list