status of PIE support?

Kees Cook
2008-05-08T05:46:04Z

Hello! I'm curious what the current status PIE support is? Many distros
have been carrying variations on PIE support patches for several releases
now, and I'd like to help get them into the mainline gdb. As I understand
it, the code was originally from Elena Zannoni and ported by various
people including Jan Kratochvil.

I've trivially ported the patches that are currently in Ubuntu's 6.8
gdb to the current gdb CVS. Since they're large, I'll just link to
them[1][2].

The older PIE CVS branches seem pretty far out of date:
"ezannoni_pie-20030916"
"ezannoni_pie-20040323"

What would be required to get this code in shape for a commit? I'm
currently fairly unfamiliar with gdb internals, but I'm willing to
learn. :)

Thanks,

-Kees

[1] http://outflux.net/gdb/pie-support.patch
gdb/gdb/Makefile.in | 2
gdb/gdb/amd64-tdep.c | 66 ++++++++-
gdb/gdb/auxv.c | 20 +-
gdb/gdb/auxv.h | 4
gdb/gdb/breakpoint.c | 61 ++++++++
gdb/gdb/breakpoint.h | 5
gdb/gdb/dwarf2read.c | 2
gdb/gdb/elfread.c | 2
gdb/gdb/infrun.c | 5
gdb/gdb/objfiles.c | 17 ++
gdb/gdb/solib-svr4.c | 342 ++++++++++++++++++++++++++++++++++++++++++++++----
gdb/gdb/solib.c | 107 +++++++++++----
gdb/gdb/solist.h | 10 +
gdb/gdb/symfile-mem.c | 2
gdb/gdb/symfile.c | 22 ++-
gdb/gdb/varobj.c | 56 ++++++++
gdb/gdb/varobj.h | 2
17 files changed, 644 insertions(+), 81 deletions(-)

[2] http://outflux.net/gdb/pie-testsuite.patch
gdb/gdb/testsuite/configure | 3
gdb/gdb/testsuite/configure.ac | 2
gdb/gdb/testsuite/gdb.pie/Makefile.in | 19
gdb/gdb/testsuite/gdb.pie/attach.c | 20
gdb/gdb/testsuite/gdb.pie/attach.exp | 432 ++++++++++++++
gdb/gdb/testsuite/gdb.pie/attach2.c | 24
gdb/gdb/testsuite/gdb.pie/break.c | 146 ++++
gdb/gdb/testsuite/gdb.pie/break.exp | 973 +++++++++++++++++++++++++++++++++
gdb/gdb/testsuite/gdb.pie/break1.c | 44 +
gdb/gdb/testsuite/gdb.pie/corefile.exp | 243 ++++++++
gdb/gdb/testsuite/gdb.pie/coremaker.c | 142 ++++
11 files changed, 2046 insertions(+), 2 deletions(-)

--
Kees Cook @outflux.net