[debhelper-devel] [RFC 0/4] improve verbosity/silentness of debhelper

Niels Thykier niels at thykier.net
Sat Jan 3 08:56:58 UTC 2015


On 2015-01-02 08:20, Bernhard R. Link wrote:
> * Bernhard R. Link <brlink at debian.org> [141229 14:11]:
>> This series tries to improve the verbosity and silentness of debhelper a
>> bit.
>>
>> The old rule of debhelper programs only outputting errors by default was
>> fine for dh_* commands but starting with the dh_auto_* commands it hides
>> information previously shown that can be quite annoying to miss and dh(1)
>> itself already ignored the rule by outputting which dh_* commands to run.
>>
>> This series adds a DH_QUIET environment variable to print less stuff,
>> then switches to display upstream build system commands to be run without
>> this (so one can see in the buildd log which options configure or make got
>> passed) and finally disables silent rules by default, too (So we can close
>> #551463 and #639168 but still have a way for people to opt out locally).
>>
>> Targeting jessie+1.
>>
>> Open question: why does Buildsystem look at the environment variables
>> directly instead of using %dh?
> 
> As noone said anything: Anyone any objections to pushing that to master?
> 
> 	Bernhard R. Link
> 

I have a minor nitpick with having two variables internally for this
purpose.  I think it would be better to map ENV{DH_QUIET} = 1 to:
   dh{DH_VERBOSE} = -1

So the code only needs to check one variable and we always get
consistent results (consider an external tool that might check them in
the other order than debhelper does).
  Admittedly, it does break the "if ($dh{VERBOSE})" pattern, so it is
not "free" to implement.

Maybe with a level of indirection by adding a "dh_verbosity(X)" sub or
so in Dh_Lib.pm that returns 1 if X >= "VERBOSITY_LEVEL".

~Niels





More information about the debhelper-devel mailing list