diff --git a/test/lit.cfg b/test/lit.cfg index c58935956a4..d74bc7bcb58 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()