On Sun, Dec 05, 2010 at 05:43:26PM -0400, Joey Hess wrote: > Roger Leigh wrote: > > dh: Add sequence dependencies and satisfy dependencies prior to running > > sequence > [...] > > The only negative aspect > > I can see from doing this is that you will get configure run twice. > > It's possible to prevent that by using a proper dependency on > > config.status as shown in the example rules file. > > I don't see why configure would be run twice when running eg, > debian/rules binary. Even if I run debian/rules build; debian/rules binary, > it doesn't re-run the configure target in my testing. Do you > have a small testcase where with this patch configure is run twice, so > I can understand the problem?
I have attached a minimal testcase. There are two rules files: debian/rules.twice (dh defaults, configure gets run twice) debian/rules.once (overridden dh_auto_configure to depend on config.status to avoid multiple runs) Simply cp one of those files to debian/rules, and run [fakeroot] debian/rules binary|build|build-indep|binary-arch etc With the patch applied you should be able to run all of the (build|binary)(-arch|-indep)? targets and see what's going on. It's basically down to the fact that "dh_auto_configure -i" and "dh_auto_configure -a" are treated separately so dh doesn't think it's been previously run (when it has been). Possibly, it should act on all packages whether or not "-i" or "-a" are given that it is configuring the package /as a whole/. I'm trying to think when this would be the wrong thing to do, maybe some people do run configure twice, but I doubt it's very common, and I doubt they are using the dh defaults if doing to. Regards, Roger -- .''`. Roger Leigh : :' : Debian GNU/Linux http://people.debian.org/~rleigh/ `. `' Printing on GNU/Linux? http://gutenprint.sourceforge.net/ `- GPG Public Key: 0x25BFB848 Please GPG sign your mail.
test.tar.bz2
Description: Binary data
signature.asc
Description: Digital signature