summaryrefslogtreecommitdiff
path: root/src/ldso/dynlink.c
AgeCommit message (Collapse)AuthorLines
2011-06-25fix some symbol resolution issues in dynamic linkerRich Felker-4/+4
1. search was wrongly beginning with lib itself rather than dso head 2. inconsistent resolution of function pointers for functions in plt
2011-06-25handle library paths better (ignore empty path components, etc.)Rich Felker-3/+5
2011-06-25fix possible (questionable) strict aliasing violations and ptr arithRich Felker-3/+3
2011-06-25proper path searching for dynamic linkerRich Felker-14/+38
first, use $LD_LIBRARY_PATH unless suid. if that fails, read path from /etc/ld-musl-$ARCH.path and fallback to a builtin default.
2011-06-25discard dso descriptors after performing relocationsRich Felker-0/+12
eventually (once dlopen exists) this behavior will be conditional on dlopen/dlsym not being reachable.
2011-06-25keep track of which dsos have been relocatedRich Felker-0/+1
2011-06-23prepare support for LD_LIBRARY_PATH (checking suid/sgid safety)Rich Felker-0/+6
the use of this test will be much stricter than glibc and other typical implementations; the environment will not be honored whatsoever unless the program is confirmed non-suid/sgid by the aux vector the kernel passed in. no fallback to slow syscall-based checking is used if the kernel fails to provide the information; we simply assume the worst (suid) in this case and refuse to honor environment.
2011-06-18dynamic linker 64bit fix: hash table entries are always 32bitRich Felker-2/+2
2011-06-18experimental dynamic linker!Rich Felker-0/+385
some notes: - library search path is hard coded - x86_64 code is untested and may not work - dlopen/dlsym is not yet implemented - relocations in read-only memory won't work