[Lldb-commits] [PATCH] D109797: Fix rendezvous for rebase_exec=true case

Emre Kultursay via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Thu Sep 23 07:21:13 PDT 2021


emrekultursay added a comment.

Done. Can you also submit it please?



================
Comment at: lldb/test/API/functionalities/dlopen/main.cpp:26
+  // dlopen the 'liblib_b.so' shared library.
+  void* h = dlopen(solib, RTLD_LAZY);
+  assert(h && "dlopen failed?");
----------------
labath wrote:
> emrekultursay wrote:
> > labath wrote:
> > > see dylib.h and the functions within (the inferior of TestLoadUnload uses them) for a windows-compatible way to load shared libraries.
> > Since we are attaching to an already running process, which cannot find the dynamic library unless I pass the full path to `dlopen()`. That's why I couldn't use dylib.h (which doesn't add full path), but created my own version here.
> Ok, what I think you're saying is that when we run a process for attaching, we skip the code paths which set ((DY)LD_LIBRARY_)PATH, which is what makes the relative imports work. It shouldn't be too hard to extend the launch infrastructure to do that. Let's commit this in this form, and I'll do that as a follow-up.
Yes. That SGTM. Thanks. 


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D109797



More information about the lldb-commits mailing list