[PATCH] D66845: [lit] Don't set DYLD_LIBRARY_PATH when DYLD_INSERT_LIBRARIES is set.
Jonas Devlieghere via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 27 17:31:54 PDT 2019
This revision was automatically updated to reflect the committed changes.
Closed by commit rL370135: [lit] Don't set DYLD_LIBRARY_PATH when DYLD_INSERT_LIBRARIES is set. (authored by JDevlieghere, committed by ).
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.
Changed prior to commit:
https://reviews.llvm.org/D66845?vs=217524&id=217539#toc
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D66845/new/
https://reviews.llvm.org/D66845
Files:
lldb/trunk/lit/Suite/lit.cfg
Index: lldb/trunk/lit/Suite/lit.cfg
===================================================================
--- lldb/trunk/lit/Suite/lit.cfg
+++ lldb/trunk/lit/Suite/lit.cfg
@@ -31,7 +31,6 @@
'libclang_rt.asan_osx_dynamic.dylib')
config.environment['DYLD_INSERT_LIBRARIES'] = runtime
-# Shared library build of LLVM may require LD_LIBRARY_PATH or equivalent.
def find_shlibpath_var():
if platform.system() in ['Linux', 'FreeBSD', 'NetBSD', 'SunOS']:
yield 'LD_LIBRARY_PATH'
@@ -40,18 +39,21 @@
elif platform.system() == 'Windows':
yield 'PATH'
-for shlibpath_var in find_shlibpath_var():
- # In stand-alone build llvm_shlib_dir specifies LLDB's lib directory
- # while llvm_libs_dir specifies LLVM's lib directory.
- shlibpath = os.path.pathsep.join(
- (config.llvm_shlib_dir,
- config.llvm_libs_dir,
- config.environment.get(shlibpath_var, '')))
- config.environment[shlibpath_var] = shlibpath
- break
-else:
- lit_config.warning("unable to inject shared library path on '{}'"
- .format(platform.system()))
+if not config.environment['DYLD_INSERT_LIBRARIES']:
+ # Shared library build of LLVM may require LD_LIBRARY_PATH or equivalent.
+ # This clashes with DYLD_INSERT_LIBRARIES which is needed on Darwin.
+ for shlibpath_var in find_shlibpath_var():
+ # In stand-alone build llvm_shlib_dir specifies LLDB's lib directory while
+ # llvm_libs_dir specifies LLVM's lib directory.
+ shlibpath = os.path.pathsep.join(
+ (config.llvm_shlib_dir,
+ config.llvm_libs_dir,
+ config.environment.get(shlibpath_var, '')))
+ config.environment[shlibpath_var] = shlibpath
+ break
+ else:
+ lit_config.warning("unable to inject shared library path on '{}'"
+ .format(platform.system()))
# Build dotest command.
dotest_cmd = [config.dotest_path, '-q']
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D66845.217539.patch
Type: text/x-patch
Size: 1887 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190828/d6384406/attachment.bin>
More information about the llvm-commits
mailing list