[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Environment variables, debian/rules and dpkg-buildpackage

On Mon, Mar 16, 2009 at 09:14:32AM +0100, Raphael Hertzog wrote:
> On Sun, 15 Mar 2009, Stephen Gran wrote:
> > This one time, at band camp, Raphael Hertzog said:
> > > Care to elaborate what kind of flexibility you need in this specific case ?
> > 
> > I don't.  I'm imagining that some of our downstreams may.
> It's precisely one of our downstreams that pushed the
> dpkg-buildpackage change (Ubuntu). I don't think most downstreams
> care a lot about the exact implementation, but they clearly want
> a way to alter defauld build flags at the distribution level.

I do not see a need for dpkg-buildpackage to set CFLAGS etc. in the environment
*by default*. What is needed instead is a policy spelling how a package should
react when a particular variable is set in the environment. If the variable
is unset the package should be built the default way.

This would still allow downstream to set them (and objectively, nothing has
ever prevented downstream to set them in the first place).

At this point it seems clear to me that:
1) dpkg-buildpackage should be changed not to set CFLAGS etc. by default.
2) we need to document how packages are supposed to behave should CFLAGS etc.
be set in the environment at build-time
3) dpkg-buildpackage should provide a configurable way to set CFLAGS etc. to
some values if this is considered useful.

dpkg-buildpackage setting CFLAGS per default is both useless and harmful.
On the other hand, this proposal still allow downstream to use
dpkg-buildpackage in the same way as with lenny, and preserve the same level of

Bill. <ballombe@debian.org>

Imagine a large red swirl here. 

Reply to: