From 986b407f319bac4a2bbe9068334e6891543fb9ef Mon Sep 17 00:00:00 2001 From: Greg Fitzgerald Date: Fri, 18 Apr 2014 17:39:50 +0000 Subject: [PATCH] Fixed llvm-build when no targets are enabled llvm-svn: 206627 --- llvm/utils/llvm-build/llvmbuild/main.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/llvm/utils/llvm-build/llvmbuild/main.py b/llvm/utils/llvm-build/llvmbuild/main.py index 6cb5c12f3541..58af547f52c8 100644 --- a/llvm/utils/llvm-build/llvmbuild/main.py +++ b/llvm/utils/llvm-build/llvmbuild/main.py @@ -719,7 +719,9 @@ def add_magic_target_components(parser, project, opts): enable_targets = available_targets.values() else: # We support both space separated and semi-colon separated lists. - if ' ' in opts.enable_targets: + if opts.enable_targets == '': + enable_target_names = [] + elif ' ' in opts.enable_targets: enable_target_names = opts.enable_targets.split() else: enable_target_names = opts.enable_targets.split(';')