From ecb452465fb31c817f185130dca5d42f576d7463 Mon Sep 17 00:00:00 2001 From: Niels Thykier Date: Thu, 29 Jun 2017 10:57:34 +0000 Subject: dh_installdocs: Support --sourcedir and fallback to d/tmp [c11] --- dh_installdocs | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/dh_installdocs b/dh_installdocs index e8ecc44f..8e09022e 100755 --- a/dh_installdocs +++ b/dh_installdocs @@ -19,11 +19,16 @@ B [S>] [B<-A>] [B<-X>I] [S .. B is a debhelper program that is responsible for installing documentation into F in package build directories. -When upstream's own build system installs all the desired documentation -correctly, then B may be a better tool for handling the upstream -documentation. In this case, B is still useful for installing +In compat 10 and earlier, L may be a better tool for handling +the upstream documentation, when upstream's own build system installs all the desired documentation +correctly. In this case, B is still useful for installing packaging related documentation (e.g. the F file). +In compat 11 and later, B offers many of the features that +L also have. Futhermore, B also supports +the B build profile to exclude documentation (regardless of compat +level). + =head1 FILES =over 4 @@ -178,12 +183,14 @@ sub ensure_docdir { init(options => { "link-doc=s" => \$dh{LINK_DOC}, + "sourcedir=s" => \$dh{SOURCEDIR}, }); my $called_getpackages = 0; my @search_dirs = ('.'); my $error_handler = compat(10) ? \&glob_expand_error_handler_warn_and_discard : \&glob_expand_error_handler_reject; my $nodocs = is_build_profile_active('nodoc') ? 1 : 0; +@search_dirs = ($dh{SOURCEDIR} // '.', 'debian/tmp') if not compat(10); foreach my $package (getpackages()) { next if is_udeb($package); -- cgit v1.2.3