Support for overriding the target toolchain when cross compiling

R=ricow@google.com

Review URL: https://codereview.chromium.org//16143002

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23248 260f80e4-7a28-3924-810f-c04153c831b5
This commit is contained in:
kustermann@google.com 2013-05-28 10:43:08 +00:00
parent c2304eff9c
commit cfa3c09596

View file

@ -120,6 +120,11 @@ def SetTools(arch, toolchainprefix):
toolsOverride = None
if arch == 'arm' and toolchainprefix == None:
toolchainprefix = DEFAULT_ARM_CROSS_COMPILER_PATH + "/bin/arm-linux-gnueabi"
# If the 'TARGET_TOOLCHAIN_PREFIX' environment variable is set, we use it
# instead. (We use it currently on our buildbots to override the default
# toolchain).
if 'TARGET_TOOLCHAIN_PREFIX' in os.environ:
toolchainprefix = os.environ['TARGET_TOOLCHAIN_PREFIX']
if toolchainprefix:
toolsOverride = {
"CC.target" : toolchainprefix + "-gcc",