Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-13 Thread Joey Hess
Roger Leigh wrote: Sorry, wrong version of second patch; I've attached the correct one. This was pretty close. I've cleaned it up in the smarter-targets branch, including inlining away recursive calls to debian/rules for implicit targets. See what you think. Note: I have not decided if this is

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-13 Thread Roger Leigh
On Mon, Jun 13, 2011 at 05:30:53PM -0400, Joey Hess wrote: Roger Leigh wrote: Sorry, wrong version of second patch; I've attached the correct one. This was pretty close. I've cleaned it up in the smarter-targets branch, including inlining away recursive calls to debian/rules for implicit

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-13 Thread Joey Hess
Roger Leigh wrote: While I've not yet had time to debug it, the attached rules file You forgot the attachement. This is due to calling rules_explicit_target before you check if the sequence is valid (debhelper-fail-me) which leads to infinite forking since each dh runs rules_explicit_target

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-12 Thread Joey Hess
Roger Leigh wrote: Good point. In the attached patch I've retained the scheme for the build and install targets, where it serves a purpose, and dropped it for binary. $sequences{binary} = ['rules:install', @ba, @b]; $sequences{'binary-indep'} = ['rules:install-indep', @b];

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-12 Thread Joey Hess
Modestas Vainius wrote: But this all seems like re-implementation of make in perl Well yes, that's essentially what dh has always been guilty of. :) Anyway, I guess it is a good thing to be policy complaint. So I suggest adding a dh restriction that standard targets have to be explicit.

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-12 Thread Roger Leigh
Hi Joey, On Sun, Jun 12, 2011 at 11:47:54AM -0400, Joey Hess wrote: Roger Leigh wrote: Good point. In the attached patch I've retained the scheme for the build and install targets, where it serves a purpose, and dropped it for binary. $sequences{binary} = ['rules:install', @ba, @b];

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-12 Thread Roger Leigh
On Sun, Jun 12, 2011 at 08:28:01PM +0100, Roger Leigh wrote: On Sun, Jun 12, 2011 at 11:47:54AM -0400, Joey Hess wrote: One possible approach here would be to call rules_explicit_target(build-(arch|indep)) and and then if they exist, we can skip the entire build sequence up to invoking

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-12 Thread Modestas Vainius
Hello, On sekmadienis 12 Birželis 2011 03:14:08 Joey Hess wrote: Modestas Vainius wrote: Personally I don't understand what's the issue here. If debian/rules has no explicit build,install,binary etc. targets (which will continue to be = 90% of cases), current dh implementation works just

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-12 Thread Roger Leigh
On Sat, Jun 11, 2011 at 07:30:38PM -0400, Joey Hess wrote: Roger Leigh wrote: Notice that the initial 'debian/rules install' performed by dh binary isn't repeated on the second invocation. But AFAICS there's no .log file that would make dh skip this, so I'm unsure why it's skipped. The

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-12 Thread Roger Leigh
On Sat, Jun 11, 2011 at 08:33:19PM -0400, Joey Hess wrote: Roger Leigh wrote: +my @bd = qw{ dh_testdir dh_auto_configure dh_auto_build dh_auto_test -}], -$sequences{'build-indep'} = [@{$sequences{build}}]; -$sequences{'build-arch'} = [@{$sequences{build}}]; +};

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-12 Thread Roger Leigh
On Sat, Jun 11, 2011 at 08:19:32PM -0400, Joey Hess wrote: Roger Leigh wrote: +If running a configure script, it may be necessary to prevent it being +run twice, once for architecture-independent packages, and again for +architecture-dependent packages. This may be accomplished by

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-11 Thread Roger Leigh
On Tue, Jun 07, 2011 at 03:52:01PM +0100, Roger Leigh wrote: On Tue, Jun 07, 2011 at 01:47:41PM +0100, Roger Leigh wrote: On Tue, Jun 07, 2011 at 08:12:15AM -0400, Joey Hess wrote: Roger Leigh wrote: I think I may have proposed something similar to this patch before, but I can't find

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-11 Thread Modestas Vainius
Hello, On sekmadienis 12 Birželis 2011 00:10:34 Roger Leigh wrote: On Tue, Jun 07, 2011 at 03:52:01PM +0100, Roger Leigh wrote: On Tue, Jun 07, 2011 at 01:47:41PM +0100, Roger Leigh wrote: On Tue, Jun 07, 2011 at 08:12:15AM -0400, Joey Hess wrote: Roger Leigh wrote: I think I may

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-11 Thread Joey Hess
Roger Leigh wrote: Note that there's one issue with the code that confuses me. This might be a pre-existing issue with dh that the patch exposes: % fakeroot dh binary --no-act debian/rules install debian/rules override_dh_strip dh_makeshlibs dh_shlibdeps dh_installdeb

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-11 Thread Joey Hess
Modestas Vainius wrote: This has a potential to go very deep with make (binary) - perl (dh) - make (install) - perl (dh) - make (build) - perl (dh). We have already seen what negative effect this has on e.g. make -jN. IMHO, bugs will be hard to understand and fix with such level of

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-11 Thread Joey Hess
Roger Leigh wrote: +If running a configure script, it may be necessary to prevent it being +run twice, once for architecture-independent packages, and again for +architecture-dependent packages. This may be accomplished by +overriding Ldh_autoconfigure(1): + +

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-11 Thread Joey Hess
Roger Leigh wrote: +my @bd = qw{ dh_testdir dh_auto_configure dh_auto_build dh_auto_test -}], -$sequences{'build-indep'} = [@{$sequences{build}}]; -$sequences{'build-arch'} = [@{$sequences{build}}]; +}; +$sequences{build} = [@bd, 'rules:build-arch',

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-07 Thread Joey Hess
Roger Leigh wrote: I think I may have proposed something similar to this patch before, but I can't find it in the BTS. It caused significant slowdown (due to running every debhelper command twice with -a and -i) and quite likely broke packages due to running make install twice, so was removed.

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-07 Thread Roger Leigh
On Tue, Jun 07, 2011 at 08:12:15AM -0400, Joey Hess wrote: Roger Leigh wrote: I think I may have proposed something similar to this patch before, but I can't find it in the BTS. It caused significant slowdown (due to running every debhelper command twice with -a and -i) and quite likely

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-07 Thread Roger Leigh
On Tue, Jun 07, 2011 at 01:47:41PM +0100, Roger Leigh wrote: On Tue, Jun 07, 2011 at 08:12:15AM -0400, Joey Hess wrote: Roger Leigh wrote: I think I may have proposed something similar to this patch before, but I can't find it in the BTS. It caused significant slowdown (due to

Bug#629139: debhelper: dh does not call policy-defined debian/rules targets

2011-06-03 Thread Roger Leigh
Package: debhelper Version: 8.1.6 Severity: normal Tags: patch Hi Joey, I think I may have proposed something similar to this patch before, but I can't find it in the BTS. This was something I was working on last year WRT the build-arch/build-indep patches you applied already. Possibly it was