add dl_iterate_phdr interface
authorRich Felker <dalias@aerifal.cx>
Thu, 1 Nov 2012 01:27:48 +0000 (21:27 -0400)
committerRich Felker <dalias@aerifal.cx>
Thu, 1 Nov 2012 01:27:48 +0000 (21:27 -0400)
commit18c0e02e2bd53ceedbb843b06ff90890f1c734b0
tree37c29715025d24e38415e72ac8ec896fb22a2dcf
parent76f28cfce59dfc499252c874f87c34567e6c86c6
add dl_iterate_phdr interface

patches by Alex Caudill (npx). the dynamic-linked version is almost
identical to the final submitted patch; I just added a couple missing
lines for saving the phdr address when the dynamic linker is invoked
directly to run a program, and removed a couple to avoid introducing
another unnecessary type. the static-linked version is based on npx's
draft. it could use some improvements which are contingent on the
startup code saving some additional information for later use.
include/link.h [new file with mode: 0644]
src/ldso/dl_iterate_phdr.c [new file with mode: 0644]
src/ldso/dynlink.c