summaryrefslogtreecommitdiff
path: root/eclass
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2015-03-31 04:27:29 +0000
committerMike Frysinger <vapier@gentoo.org>2015-03-31 04:27:29 +0000
commitca3615aa1e93934b77c26b11e5d2825c597f63a8 (patch)
treebfe135e62b1b4cddfa1dcda11ae45e9346c90ea5 /eclass
parentClean up even more PYTHON_COMPAT from old implementations, add py3.4 support,... (diff)
downloadgentoo-2-ca3615aa1e93934b77c26b11e5d2825c597f63a8.tar.gz
gentoo-2-ca3615aa1e93934b77c26b11e5d2825c597f63a8.tar.bz2
gentoo-2-ca3615aa1e93934b77c26b11e5d2825c597f63a8.zip
tc-export_build_env: export BUILD_CPPFLAGS/BUILD_LDFLAGS to non-empty values so they do not get defaulted by build systems #526734 by Matthias Maier
Diffstat (limited to 'eclass')
-rw-r--r--eclass/toolchain-funcs.eclass9
1 files changed, 6 insertions, 3 deletions
diff --git a/eclass/toolchain-funcs.eclass b/eclass/toolchain-funcs.eclass
index d3c5a67eca29..4100a00d6f9b 100644
--- a/eclass/toolchain-funcs.eclass
+++ b/eclass/toolchain-funcs.eclass
@@ -1,6 +1,6 @@
# Copyright 1999-2015 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain-funcs.eclass,v 1.135 2015/03/16 21:12:27 vapier Exp $
+# $Header: /var/cvsroot/gentoo-x86/eclass/toolchain-funcs.eclass,v 1.136 2015/03/31 04:27:29 vapier Exp $
# @ECLASS: toolchain-funcs.eclass
# @MAINTAINER:
@@ -223,10 +223,13 @@ tc-is-static-only() {
# Export common build related compiler settings.
tc-export_build_env() {
tc-export "$@"
+ # Some build envs will initialize vars like:
+ # : ${BUILD_LDFLAGS:-${LDFLAGS}}
+ # So make sure all variables are non-empty. #526734
: ${BUILD_CFLAGS:=-O1 -pipe}
: ${BUILD_CXXFLAGS:=-O1 -pipe}
- : ${BUILD_CPPFLAGS:=}
- : ${BUILD_LDFLAGS:=}
+ : ${BUILD_CPPFLAGS:= }
+ : ${BUILD_LDFLAGS:= }
export BUILD_{C,CXX,CPP,LD}FLAGS
# Some packages use XXX_FOR_BUILD.