freebsd-dev/libexec/rtld-elf
Konstantin Belousov dec4912e62 Calculate relocation base for the main object, and apply the relocation
adjustment for all virtual addresses encoded into the ELF structures of
it. PIE binary could and should be loaded at non-zero mapbase.

For sym_zero pseudosymbol used as a return value from find_symdef()
for undefined weak symbols, st_value also should be adjusted, since
_rtld_bind corrects symbol values by relocbase.

Discussed with:	bz
Reviewed by:	kan
Tested by:	bz (i386, amd64), bsam (linux)
MFC after:	some time
2009-10-10 15:27:10 +00:00
..
amd64 Now that the kernel defines CACHE_LINE_SIZE in machine/param.h, use 2009-04-19 23:02:50 +00:00
arm Now that the kernel defines CACHE_LINE_SIZE in machine/param.h, use 2009-04-19 23:02:50 +00:00
i386 Now that the kernel defines CACHE_LINE_SIZE in machine/param.h, use 2009-04-19 23:02:50 +00:00
ia64 Now that the kernel defines CACHE_LINE_SIZE in machine/param.h, use 2009-04-19 23:02:50 +00:00
mips Now that the kernel defines CACHE_LINE_SIZE in machine/param.h, use 2009-04-19 23:02:50 +00:00
powerpc Now that the kernel defines CACHE_LINE_SIZE in machine/param.h, use 2009-04-19 23:02:50 +00:00
sparc64 Now that the kernel defines CACHE_LINE_SIZE in machine/param.h, use 2009-04-19 23:02:50 +00:00
debug.c
debug.h Use C99's varadic macro syntax instead of gcc's. 2006-03-28 18:26:47 +00:00
libmap.c Fix a malloc overrun in 32-bit compat libmap lookup code. 2006-01-31 06:08:28 +00:00
libmap.h Description from Dan: 2005-02-04 02:46:41 +00:00
Makefile Second attempt at eliminating .text relocations in shared libraries 2009-07-14 21:19:13 +00:00
malloc.c In preparation for a new malloc implementation: 2006-01-12 07:28:21 +00:00
map_object.c In rtld's map_object(), use pread(..., 0) rather than read() to read the 2009-10-06 17:14:39 +00:00
rtld_lock.c Prefer <sys/param.h> to <machine/param.h> for the definition of 2009-04-20 10:35:50 +00:00
rtld_lock.h Provide custom simple allocator for rtld locks in libthr. The allocator 2008-12-02 11:58:31 +00:00
rtld_tls.h
rtld.1 Document RTLD_NODELETE, -z nodelete and -z origin support. 2009-04-01 14:38:20 +00:00
rtld.c Calculate relocation base for the main object, and apply the relocation 2009-10-10 15:27:10 +00:00
rtld.h Allow order of initialization of loaded shared objects to be 2009-06-20 14:16:41 +00:00
Symbol.map Allow the NULL, RTLD_SELF and RTLD_NEXT handles to work with dlfunc(3). 2009-04-03 19:17:23 +00:00
xmalloc.c