From 9b83bfdcb0baac4c2f986c600a2a7c2e946ad17c Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Mon, 1 Dec 2014 17:34:05 -0700 Subject: buildman: Allow architecture to alias to multiple toolchains Some archs have need than one alias, so support a list of alises in the ..buildman file. Signed-off-by: Simon Glass --- tools/buildman/toolchain.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'tools/buildman/toolchain.py') diff --git a/tools/buildman/toolchain.py b/tools/buildman/toolchain.py index cb693f4641..ad4df8cc9b 100644 --- a/tools/buildman/toolchain.py +++ b/tools/buildman/toolchain.py @@ -185,9 +185,11 @@ class Toolchains: returns: toolchain object, or None if none found """ - for name, value in bsettings.GetItems('toolchain-alias'): - if arch == name: - arch = value + for tag, value in bsettings.GetItems('toolchain-alias'): + if arch == tag: + for alias in value.split(): + if alias in self.toolchains: + return self.toolchains[alias] if not arch in self.toolchains: raise ValueError, ("No tool chain found for arch '%s'" % arch) -- cgit v1.2.1