[Lldb-commits] [PATCH] D73767: [lldb] [test] Pass LLVM_LIBS_DIR from CMake for linking liblldb

Pavel Labath via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Fri Jan 31 04:46:47 PST 2020


labath added a comment.

In D73767#1851418 <https://reviews.llvm.org/D73767#1851418>, @mgorny wrote:

> The question is, does this break any of the platform hacks? ;-)


I think it /may/ break one. See inline comment.

BTW, I think the best way to clean a lot of this up would be to take the tests which build executables linking to liblldb, and rewrite them as c++ unit tests (at least those that aren't skipped/xfailed everywhere), as cmake knows best how to link to the thing it has built. Then, a lot of this stuff can be just deleted...



================
Comment at: lldb/packages/Python/lldbsuite/test/lldbtest.py:1680
             self.dylibPath] if self.dylibPath in os.environ else None
-        lib_dir = os.environ["LLDB_LIB_DIR"]
+        lib_dir = configuration.lldb_libs_dir
         if existing_library_path:
----------------
I'm not sure if this is right, because (despite the name) `LLDB_LIB_DIR` points to the "bin" dir. But then again, this whole function seems pretty wrong, so it's hard to say what should it really do here.

 If you don't need this part (the previous patch didn't have it) and want to make this safe-ish for cherry-picking, maybe you could leave this part out for now.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D73767/new/

https://reviews.llvm.org/D73767





More information about the lldb-commits mailing list