summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--test/lit.cfg7
1 files changed, 6 insertions, 1 deletions
diff --git a/test/lit.cfg b/test/lit.cfg
index c58935956a..d74bc7bcb5 100644
--- a/test/lit.cfg
+++ b/test/lit.cfg
@@ -236,8 +236,13 @@ if loadable_module:
# llc knows whether he is compiled with -DNDEBUG.
import subprocess
-llc_cmd = subprocess.Popen([os.path.join(llvm_tools_dir, 'llc'), '-version'],
+try:
+ llc_cmd = subprocess.Popen([os.path.join(llvm_tools_dir, 'llc'), '-version'],
stdout = subprocess.PIPE)
+except OSError, why:
+ print "Could not find llc in " + llvm_tools_dir
+ exit(42)
+
if re.search(r'with assertions', llc_cmd.stdout.read()):
config.available_features.add('asserts')
llc_cmd.wait()