From 412d5d42faab3dfc59d498ff538a9d5788adeac3 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Mon, 22 Nov 2010 19:23:29 -0400 Subject: dh_listpackages: Do not display warnings if options cause no packages to be listed. --- Debian/Debhelper/Dh_Getopt.pm | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'Debian/Debhelper/Dh_Getopt.pm') diff --git a/Debian/Debhelper/Dh_Getopt.pm b/Debian/Debhelper/Dh_Getopt.pm index 257fe649..e4f3e471 100644 --- a/Debian/Debhelper/Dh_Getopt.pm +++ b/Debian/Debhelper/Dh_Getopt.pm @@ -236,7 +236,9 @@ sub parseopts { if ($dh{DOINDEP} || $dh{DOARCH}) { # User specified that all arch (in)dep package be # built, and there are none of that type. - warning("You asked that all arch in(dep) packages be built, but there are none of that type."); + if (! $dh{BLOCK_NOOP_WARNINGS}) { + warning("You asked that all arch in(dep) packages be built, but there are none of that type."); + } exit(0); } push @{$dh{DOPACKAGES}},getpackages("both"); @@ -263,7 +265,9 @@ sub parseopts { @{$dh{DOPACKAGES}}=@package_list; if (! defined $dh{DOPACKAGES} || ! @{$dh{DOPACKAGES}}) { - warning("No packages to build."); + if (! $dh{BLOCK_NOOP_WARNINGS}) { + warning("No packages to build."); + } exit(0); } -- cgit v1.2.3