[Build-common-hackers] Bug#521872: makefile-vars.mk clobbers LDFLAGS and others
Martin Pitt
martin.pitt at ubuntu.com
Mon Mar 30 16:58:43 UTC 2009
Package: cdbs
Version: 0.4.55
Severity: important
Hello,
In https://launchpad.net/bugs/138981 it was reported that cdbs'
makefile-vars.mk clobbers LDFLAGS/CFLAGS set by upstream makefiles.
DEB_MAKE_INVOKE = $(DEB_MAKE_ENVVARS) $(MAKE) $(if $(DEB_MAKE_MAKEFILE), -f $(DEB_MAKE_MAKEFILE),) -C $(DEB_BUILDDIR) CFLAGS=$(if $(CFLAGS_$(cdbs_curpkg)),"$(CFLAGS_$(cdbs_curpkg))","$(CFLAGS)") CXXFLAGS=$(if $(CXXFLAGS_$(cdbs_curpkg)),"$(CXXFLAGS_$(cdbs_curpkg))","$(CXXFLAGS)") CPPFLAGS=$(if $(CPPFLAGS_$(cdbs_curpkg)),"$(CPPFLAGS_$(cdbs_curpkg))","$(CPPFLAGS)") LDFLAGS=$(if $(LDFLAGS_$(cdbs_curpkg)),"$(LDFLAGS_$(cdbs_curpkg))","$(LDFLAGS)")
This is wrong, since if $LDFLAGS is not set in the environment, but in the
upstream Makefiles, this ends up as
make LDFLAGS=""
and thus upstream makefiles which only provide defaults (instead of overriding)
break.
Patching this is obvious, the "LDFLAGS=" simply needs to be moved into the
conditional substitution, but I wouldn't like to change this in Ubuntu
without having it changed in Debian as well, to avoid toolchain
diversion.
Thanks for considering,
Martin
--
Martin Pitt | http://www.piware.de
Ubuntu Developer (www.ubuntu.com) | Debian Developer (www.debian.org)
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: Digital signature
Url : http://lists.alioth.debian.org/pipermail/build-common-hackers/attachments/20090330/b4894e35/attachment.pgp
More information about the Build-common-hackers
mailing list