summaryrefslogtreecommitdiff
path: root/dh_installexamples
diff options
context:
space:
mode:
authorNiels Thykier <niels@thykier.net>2017-06-29 07:37:04 +0000
committerNiels Thykier <niels@thykier.net>2017-06-29 11:37:05 +0000
commit1388c2ac52deee1f27422b2bcb1965d70b9e5ae1 (patch)
treebd4fcd2ff59aac2b29a303b874b0f922add456a6 /dh_installexamples
parent6d7a49451e48cd07000ce9af1b247058a91e0d48 (diff)
downloaddebhelper-1388c2ac52deee1f27422b2bcb1965d70b9e5ae1.tar.gz
dh_installexamples: Permit missing manpage under nodoc profile
Diffstat (limited to 'dh_installexamples')
-rwxr-xr-xdh_installexamples8
1 files changed, 7 insertions, 1 deletions
diff --git a/dh_installexamples b/dh_installexamples
index 53ddc746..56d4e446 100755
--- a/dh_installexamples
+++ b/dh_installexamples
@@ -66,6 +66,10 @@ init();
my $pwd;
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;
+# We cannot assume documentation is built under nodoc, but if it is we must flag it as handled
+# or dh_missing might make noise.
+$error_handler = \&glob_expand_error_handler_silently_ignore if $nodocs;
foreach my $package (@{$dh{DOPACKAGES}}) {
next if is_udeb($package);
@@ -82,7 +86,9 @@ foreach my $package (@{$dh{DOPACKAGES}}) {
if (($package eq $dh{FIRSTPACKAGE} || $dh{PARAMS_ALL}) && @ARGV) {
push @examples, @ARGV;
}
-
+
+ next if $nodocs;
+
if (@examples) {
install_dir("$tmp/usr/share/doc/$package/examples");