From 2103e25e19183990657339178669253148dec54f Mon Sep 17 00:00:00 2001 From: Stephen Wilson Date: Sun, 16 Jan 2011 19:45:39 +0000 Subject: Initial support for a DynamicLoader plugin on Linux. This patch is enough to have shared objects recognized by LLDB. We can handle position independent executables. We can handle dynamically loaded modules brought in via dlopen. The DYLDRendezvous class provides an interface to a structure present in the address space of ELF-based processes. This structure provides the address of a function which is called by the linker each time a shared object is loaded and unloaded (thus a breakpoint at that address will let LLDB intercept such events), a list of entries describing the currently loaded shared objects, plus a few other things. On Linux, processes are brought up with an auxiliary vector on the stack. One element in this vector contains the (possibly dynamic) entry address of the process. One does not need to walk the stack to find this information as it is also available under /proc//auxv. The new AuxVector class provides a convenient read-only view of this auxiliary vector information. We use the dynamic entry address and the address as specified in the object file to compute the actual load address of the inferior image. This strategy works for both normal executables and PIE's. llvm-svn: 123592 --- lldb/lib/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'lldb/lib') diff --git a/lldb/lib/Makefile b/lldb/lib/Makefile index 881b23c6185..abd9c1d8328 100644 --- a/lldb/lib/Makefile +++ b/lldb/lib/Makefile @@ -67,7 +67,8 @@ ifeq ($(HOST_OS),Darwin) endif ifeq ($(HOST_OS),Linux) - USEDLIBS += lldbPluginProcessLinux.a + USEDLIBS += lldbPluginProcessLinux.a \ + lldbPluginDynamicLoaderLinux.a endif include $(LEVEL)/Makefile.common -- cgit v1.2.3