[Lldb-commits] [lldb] r370138 - [lit] Fix the way we check if an environment var is set

Jonas Devlieghere via lldb-commits lldb-commits at lists.llvm.org
Tue Aug 27 17:52:08 PDT 2019

Author: jdevlieghere
Date: Tue Aug 27 17:52:08 2019
New Revision: 370138

URL: http://llvm.org/viewvc/llvm-project?rev=370138&view=rev
[lit] Fix the way we check if an environment var is set

The old method would throw a KeyError.


Modified: lldb/trunk/lit/Suite/lit.cfg
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/lit/Suite/lit.cfg?rev=370138&r1=370137&r2=370138&view=diff
--- lldb/trunk/lit/Suite/lit.cfg (original)
+++ lldb/trunk/lit/Suite/lit.cfg Tue Aug 27 17:52:08 2019
@@ -39,7 +39,7 @@ def find_shlibpath_var():
   elif platform.system() == 'Windows':
     yield 'PATH'
-if not config.environment['DYLD_INSERT_LIBRARIES']:
+if 'DYLD_INSERT_LIBRARIES' in os.environ:
   # 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():

More information about the lldb-commits mailing list