[PATCH] D135368: [llvm] [lit] Fix use_lld() to respect llvm_shlib_dir

Michał Górny via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Oct 6 08:05:11 PDT 2022


mgorny created this revision.
mgorny added reviewers: jhenderson, zturner, MaskRay.
Herald added subscribers: StephenFan, delcypher.
Herald added a project: All.
mgorny requested review of this revision.
Herald added a project: LLVM.

Fix the use_lld() to use llvm_shlib_dir similarly to how use_clang()
does it.  This fixes use_lld() wrongly prepending llvm_libs_dir,
i.e. the directory with system-installed LLVM libraries before
the build directory of standalone build.  As a result, the shared
libraries from an earlier version of clang end up being used instead of
the newly built version when running the test suite prior to installing.


https://reviews.llvm.org/D135368

Files:
  llvm/utils/lit/lit/llvm/config.py


Index: llvm/utils/lit/lit/llvm/config.py
===================================================================
--- llvm/utils/lit/lit/llvm/config.py
+++ llvm/utils/lit/lit/llvm/config.py
@@ -644,7 +644,7 @@
         self.with_environment('PATH', paths, append_path=True)
 
         lib_dir_props = [self.config.name.lower() + '_libs_dir',
-                         'lld_libs_dir', 'llvm_libs_dir']
+                         'lld_libs_dir', 'llvm_shlib_dir', 'llvm_libs_dir']
         lib_paths = [getattr(self.config, pp) for pp in lib_dir_props
                      if getattr(self.config, pp, None)]
 


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D135368.465738.patch
Type: text/x-patch
Size: 603 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20221006/f2d30d16/attachment.bin>


More information about the llvm-commits mailing list