[all-commits] [llvm/llvm-project] 5f4c85: [lldb/test] Do a better job at setting (DY)LD_LIBR...

Pavel Labath via All-commits all-commits at lists.llvm.org
Wed Jul 22 02:37:23 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 5f4c850e7b4f100a8c779ea52b492c87af076136
      https://github.com/llvm/llvm-project/commit/5f4c850e7b4f100a8c779ea52b492c87af076136
  Author: Pavel Labath <pavel at labath.sk>
  Date:   2020-07-22 (Wed, 22 Jul 2020)

  Changed paths:
    M lldb/packages/Python/lldbsuite/test/lldbtest.py
    M lldb/test/API/commands/expression/weak_symbols/TestWeakSymbols.py

  Log Message:
  -----------
  [lldb/test] Do a better job at setting (DY)LD_LIBRARY_PATH

Summary:
registerSharedLibrariesWithTarget was setting the library path
environment variable to the process build directory, but the function is
also accepting libraries in other directories (in which case they won't
be found automatically).

This patch makes the function set the path variable correctly for these
libraries too. This enables us to remove the code for setting the path
variable in TestWeakSymbols.py, which was working only accidentally --
it was relying on the fact that
  launch_info.SetEnvironmentEntries(..., append=True)
would not overwrite the path variable it has set, but that is going to
change with D83306.

Reviewers: davide, jingham

Subscribers: lldb-commits

Tags: #lldb

Differential Revision: https://reviews.llvm.org/D83552




More information about the All-commits mailing list