You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

38 lines
1.5 KiB

From 884e831ed07607097614276f6bbf192993228100 Mon Sep 17 00:00:00 2001
From: Hauke Mehrtens <hauke.mehrtens@lantiq.com>
Date: Tue, 2 Jun 2015 11:08:17 +0200
Subject: [PATCH 3/4] 004-use-env.patch
---
build_common/SConscript | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
--- a/build_common/SConscript
+++ b/build_common/SConscript
@@ -129,6 +129,26 @@ tc_set_msg = '''
* cause inexplicable errors. *
*******************************************************************************
'''
+env['ENV'] = os.environ
+if 'CC' in os.environ:
+ env['CC'] = Split(os.environ['CC'])
+ print "using CC from enviroment: %s" % env['CC']
+if 'CXX' in os.environ:
+ env['CXX'] = Split(os.environ['CXX'])
+ print "using CXX from enviroment: %s" % env['CXX']
+if 'CFLAGS' in os.environ:
+ env['CFLAGS'] = Split(os.environ['CFLAGS'])
+ print "using CFLAGS from enviroment: %s" % env['CFLAGS']
+if 'CXXFLAGS' in os.environ:
+ env['CXXFLAGS'] = Split(os.environ['CXXFLAGS'])
+ print "using CXXFLAGS from enviroment: %s" % env['CXXFLAGS']
+if 'CPPFLAGS' in os.environ:
+ env['CPPFLAGS'] = Split(os.environ['CPPFLAGS'])
+ print "using CPPFLAGS from enviroment: %s" % env['CPPFLAGS']
+if 'LDFLAGS' in os.environ:
+ env['LINKFLAGS'] = Split(os.environ['LDFLAGS'])
+ print "using LDFLAGS/LINKFLAGS from enviroment: %s" % env['LINKFLAGS']
+
if env.get('VERBOSE') == False:
env['CCCOMSTR'] = "Compiling $TARGET"
env['SHCCCOMSTR'] = "Compiling $TARGET"