This is the mail archive of the
mailing list for the binutils project.
Writing a ldd like utility.
- From: "vamsi krishna" <vamsi dot krishnak at gmail dot com>
- To: binutils at sourceware dot org
- Date: Thu, 1 Jun 2006 23:53:22 +0530
- Subject: Writing a ldd like utility.
I need to write some for a program which needs the virtual address
where the shared libraries (I need to enumerate each of them ) are
mapped in the virtual adress space.
o I can read the link_maps of the dynamic linker get the details of
where the shared libraries are mapped, but I'am little skeptical about
its portability (do all the linuxes and unixes have the same way to
access the link_maps ?).
o I see the there are some .dynamic sections in the elf binary, so the
information on where (virtual address) these dynamic shared libraries
are mapped is put in this section?
o Was wondering how ldd does that ? (does it fork the executable and
get the link_maps from it?)
Thank you for your comments.