[llvm-lit] unbreak clang-only builds by not assuming llvm-lit in build dir

Reviewed By: tstellar

Differential Revision: https://reviews.llvm.org/D109000
This commit is contained in:
Yaron Keren 2021-08-31 18:02:02 +03:00
parent b8debabb77
commit 10d78a06ba
1 changed files with 4 additions and 2 deletions

View File

@ -21,8 +21,10 @@ script_path = os.path.join(config.llvm_src_root, 'utils',
'update_cc_test_checks.py')
assert os.path.isfile(script_path)
# Windows: llvm-lit.py, Linux: llvm-lit
llvm_lit = glob.glob(os.path.join(config.llvm_tools_dir, 'llvm-lit*'))[0]
lit = config.llvm_external_lit if config.llvm_external_lit else shell_quote(llvm_lit)
if config.llvm_external_lit:
lit = config.llvm_external_lit
else:
lit = shell_quote(glob.glob(os.path.join(config.llvm_tools_dir, 'llvm-lit*'))[0])
python = shell_quote(config.python_executable)
config.substitutions.append(
('%update_cc_test_checks', "%s %s %s" % (