rtld-elf: Sync with FreeBSD
authorJohn Marino <draco@marino.st>
Wed, 13 Apr 2011 19:20:44 +0000 (21:20 +0200)
committerJohn Marino <draco@marino.st>
Thu, 28 Apr 2011 20:02:07 +0000 (22:02 +0200)
commitfcf53d9b037c8b3b6b834245c8c0eb99b1458e72
treedac0d3a1917f5ac1535df1ef452f86625e42fc66
parent3bef29b863eb38b81876ec6eb3fbf9503be620ed
rtld-elf: Sync with FreeBSD

The DragonFly run-time linker receives its first upgrade since TLS was
added.  Highlights include improvements to dl functionality:

dlvsym
dl_iterate_phdr
_rtld_addr_phdr
improved dlfunct

Improved security for dangerous LD environment variables were added.
Several bugs were fixed.
libmap.conf functionality was added.
utrace/ktrace support added.
Improved atexit and cxa_atexit finalization.
ELF symbol versioning using gnu semantics.
ldd and kdump improvments
significant man page updates
dynamic token expansion functionlity added.
new locking mechanism
Support for env var LD_ELF_HINTS_PATH
Support for RTLD_NODELETE and RTLD_NOLOAD flags for dlopen
dlfunc moved from libc to rtld

The next GCC upgrade will take advantage of this rtld upgrade in order
to improve exception handling.  DragonFly has never used the shared
libgcc_s which has impeded (or broke?) C++ exception handling.

This commit syncs rtld-elf to the FreeBSD cerca 16 DEC 2010.  However,
bug fixes between then and 25 March 2011 have been included, but major
functionality changes from the ELF Filter support on 25 DEC 2010 onwards
has been excluded.
52 files changed:
include/dlfcn.h
include/link.h
include/paths.h
lib/libc/gen/Makefile.inc
lib/libc/gen/dl_iterate_phdr.3 [new file with mode: 0644]
lib/libc/gen/dladdr.3
lib/libc/gen/dlclose.3 [new file with mode: 0644]
lib/libc/gen/dlerror.3 [new file with mode: 0644]
lib/libc/gen/dlfcn.3 [new file with mode: 0644]
lib/libc/gen/dlfcn.c
lib/libc/gen/dlfunc.c [deleted file]
lib/libc/gen/dlinfo.3
lib/libc/gen/dlopen.3
lib/libc/gen/dlsym.3 [new file with mode: 0644]
lib/libc/gen/dlvsym.3 [new file with mode: 0644]
lib/libc/gen/elf_utils.c [new file with mode: 0644]
lib/libc/include/libc_private.h
lib/libc/stdlib/atexit.c
lib/libthread_xu/pthread.map
lib/libthread_xu/thread/thr_fork.c
lib/libthread_xu/thread/thr_private.h
libexec/rtld-elf/Makefile
libexec/rtld-elf/debug.c
libexec/rtld-elf/debug.h
libexec/rtld-elf/i386/lockdflt.c [deleted file]
libexec/rtld-elf/i386/reloc.c
libexec/rtld-elf/i386/rtld_machdep.h
libexec/rtld-elf/i386/rtld_start.S
libexec/rtld-elf/libmap.c [new file with mode: 0644]
libexec/rtld-elf/libmap.h [new file with mode: 0644]
libexec/rtld-elf/malloc.c
libexec/rtld-elf/map_object.c
libexec/rtld-elf/rtld.1
libexec/rtld-elf/rtld.c
libexec/rtld-elf/rtld.h
libexec/rtld-elf/rtld_lock.c [new file with mode: 0644]
libexec/rtld-elf/rtld_lock.h [copied from libexec/rtld-elf/debug.h with 52% similarity]
libexec/rtld-elf/x86_64/lockdflt.c [deleted file]
libexec/rtld-elf/x86_64/reloc.c
libexec/rtld-elf/x86_64/rtld_machdep.h
libexec/rtld-elf/x86_64/rtld_start.S
share/man/man5/Makefile
share/man/man5/libmap.conf.5 [new file with mode: 0644]
sys/cpu/i386/include/elf.h
sys/cpu/x86_64/include/elf.h
sys/sys/elf32.h
sys/sys/elf_common.h
sys/sys/elf_generic.h
sys/sys/link_elf.h
usr.bin/kdump/kdump.c
usr.bin/ldd/ldd.1
usr.bin/ldd/ldd.c