diff options
| author | Daniel Dunbar <daniel@zuster.org> | 2011-11-10 01:16:48 +0000 |
|---|---|---|
| committer | Daniel Dunbar <daniel@zuster.org> | 2011-11-10 01:16:48 +0000 |
| commit | 807c6e4e5f34b4c23e5d1d929269fcbe758f4891 (patch) | |
| tree | 8f39cc25892790f9791f14e28e196116889a75c4 /llvm/utils | |
| parent | f58a0487765da1bf124f1d5db44a1f98e020f0ed (diff) | |
| download | bcm5719-llvm-807c6e4e5f34b4c23e5d1d929269fcbe758f4891.tar.gz bcm5719-llvm-807c6e4e5f34b4c23e5d1d929269fcbe758f4891.zip | |
build/Make & CMake: Pass the appropriate --native-target and --enable-targets
options to llvm-build, so the all-targets etc. components are defined properly.
llvm-svn: 144255
Diffstat (limited to 'llvm/utils')
| -rw-r--r-- | llvm/utils/llvm-build/llvmbuild/main.py | 14 |
1 files changed, 10 insertions, 4 deletions
diff --git a/llvm/utils/llvm-build/llvmbuild/main.py b/llvm/utils/llvm-build/llvmbuild/main.py index fe852a0c4e2..51923ebad7b 100644 --- a/llvm/utils/llvm-build/llvmbuild/main.py +++ b/llvm/utils/llvm-build/llvmbuild/main.py @@ -505,7 +505,7 @@ def add_magic_target_components(parser, project, opts): determined based on the target configuration options. This currently is responsible for populating the required_libraries list of - the "Native", "NativeCodeGen", and "Engine" components. + the "all-targets", "Native", "NativeCodeGen", and "Engine" components. """ # Determine the available targets. @@ -536,8 +536,14 @@ def add_magic_target_components(parser, project, opts): if opts.enable_targets is None: enable_targets = available_targets.values() else: + # We support both space separated and semi-colon separated lists. + if ' ' in opts.enable_targets: + enable_target_names = opts.enable_targets.split() + else: + enable_target_names = opts.enable_targets.split(';') + enable_targets = [] - for name in opts.enable_targets.split(): + for name in enable_target_names: target = available_targets.get(name) if target is None: parser.error("invalid target to enable: %r (not in project)" % ( @@ -641,8 +647,8 @@ def main(): action="store", default=None) group.add_option("", "--enable-targets", dest="enable_targets", metavar="NAMES", - help=("Enable the given space separated list of targets, " - "or all targets if not present"), + help=("Enable the given space or semi-colon separated " + "list of targets, or all targets if not present"), action="store", default=None) parser.add_option_group(group) |

