On Thu, Dec 08, 2011 at 02:47:00PM -0400, Joey Hess wrote:
> Steve Langasek wrote:
> > While I had originally believed this to be the case when drafting
> > <http://wiki.debian.org/Multiarch/Implementation>, feedback from those
> > implementing this in practice is that dh does *not* export these variables,
> > it only passes them to autoconf.
> That's not correct, dh exports the variables. (You made me look though.)
> joey@gnu:~/src/filters>head -n2 Makefile
> build:
> echo ${CPPFLAGS}
> joey@gnu:~/src/filters>echo 9 > debian/compat
> joey@gnu:~/src/filters>debian/rules build
> dh build
> dh_testdir
> dh_auto_configure
> dh_auto_build
> make[1]: Entering directory `/home/joey/src/filters'
> echo -D_FORTIFY_SOURCE=2
> -D_FORTIFY_SOURCE=2
Well, it exports CPPFLAGS as part of dpkg-buildflags handling, sure, but not
DEB_{HOST,BUILD}_*.
(I did actually test this myself before posting:
$ cat debian/rules
#!/usr/bin/make -f
%:
dh $@
override_dh_auto_configure:
echo $(DEB_HOST_MULTIARCH)
false
$ echo 9 > debian/compat
$ ./debian/rules build
dh build
dh_testdir
debian/rules override_dh_auto_configure
make[1]: Entering directory `/tmp/testing'
echo
false
<snip>
)
Also, I'm pretty sure the *FLAGS export happens only for dh_auto_* and
not for dh itself (set_buildflags is called from
/usr/share/perl5/Debian/Debhelper/Dh_Buildsystems.pm), so it still doesn't
help when called from dh_install.
--
Steve Langasek Give me a lever long enough and a Free OS
Debian Developer to set it on, and I can move the world.
Ubuntu Developer http://www.debian.org/
slangasek@ubuntu.com vorlon@debian.org
Attachment:
signature.asc
Description: Digital signature