Skip to content

Commit

Permalink
Fix pass params to llvm-config
Browse files Browse the repository at this point in the history
  • Loading branch information
alexander-penev committed Nov 30, 2023
1 parent cc88c41 commit 613f5ed
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions test/lit.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -327,17 +327,16 @@ if(config.have_enzyme):
# Ask llvm-config about assertion mode and build-mode.
try:
llvm_config_cmd = subprocess.Popen(
[os.path.join(llvm_tools_dir, 'llvm-config'), '--assertion-mode --build-mode'],
[os.path.join(llvm_tools_dir, 'llvm-config'), '--assertion-mode', '--build-mode'],
stdout = subprocess.PIPE,
env=config.environment)
except OSError:
print("Could not find llvm-config in " + llvm_tools_dir)
exit(42)

res=llvm_config_cmd.stdout.read().decode('ascii')
llvm_config_cmd.wait()

if re.search(r'ON', res):
config.available_features.add('asserts')
if re.search(r'[Dd][Ee][Bb][Uu][Gg]', res):
config.available_features.add('debug')

llvm_config_cmd.wait()

0 comments on commit 613f5ed

Please sign in to comment.