Skip to content

Commit 5f17377

Browse files
committed
[lit] Work around issue where can't set the host library environment.
1 parent 52d513a commit 5f17377

File tree

1 file changed

+7
-3
lines changed

1 file changed

+7
-3
lines changed

test/lit.cfg

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2480,9 +2480,13 @@ config.substitutions.append(('%llvm-profdata', config.llvm_profdata))
24802480
config.substitutions.append(('%llvm-cov', config.llvm_cov))
24812481

24822482
# Set up the host library environment.
2483-
host_library_env = (
2484-
"/usr/bin/env " +
2485-
construct_library_path_env(config.swift_host_lib_dir))
2483+
if hasattr(config, 'target_library_path_var'):
2484+
host_library_env = (
2485+
"/usr/bin/env " +
2486+
construct_library_path_env(config.swift_host_lib_dir))
2487+
else:
2488+
host_library_env = ""
2489+
24862490
config.substitutions.append(('%host-library-env', host_library_env))
24872491

24882492
if hasattr(config, 'otool_classic'):

0 commit comments

Comments
 (0)