diff options
author | Mark Wielaard <mark@klomp.org> | 2020-02-08 21:40:27 +0100 |
---|---|---|
committer | Mark Wielaard <mark@klomp.org> | 2020-02-18 13:20:18 +0100 |
commit | c4600ae002c8a8738035ec5f80e818171811c9d4 (patch) | |
tree | f93a4d24c4b06aad16b00c7e7d5696c132794f1b /libebl | |
parent | f4354082ba7c9d7d7c88b69a41db34f4f8a88ab5 (diff) | |
download | elfutils-c4600ae002c8a8738035ec5f80e818171811c9d4.tar.gz |
readelf, elflint: Handle PT_GNU_PROPERTY.
binutils 2.32 ld emits a new PT_GNU_PROPERTY segment that overlaps
with the PT_NOTE segment covering the .note.gnu.property section data.
https://sourceware.org/bugzilla/show_bug.cgi?id=25511
Signed-off-by: Mark Wielaard <mark@klomp.org>
Diffstat (limited to 'libebl')
-rw-r--r-- | libebl/ChangeLog | 5 | ||||
-rw-r--r-- | libebl/eblsegmenttypename.c | 6 |
2 files changed, 11 insertions, 0 deletions
diff --git a/libebl/ChangeLog b/libebl/ChangeLog index 4da7eeeb..b3287310 100644 --- a/libebl/ChangeLog +++ b/libebl/ChangeLog @@ -1,3 +1,8 @@ +2020-02-08 Mark Wielaard <mark@klomp.org> + + * eblsegmenttypename.c (ebl_segment_type_name): Handle + PT_GNU_PROPERTY. + 2019-08-29 Mark Wielaard <mark@klomp.org> * Makefile.am (noinst_LIBRARIES): Add libebl.a. diff --git a/libebl/eblsegmenttypename.c b/libebl/eblsegmenttypename.c index 14eda76e..c6bdff8a 100644 --- a/libebl/eblsegmenttypename.c +++ b/libebl/eblsegmenttypename.c @@ -56,6 +56,10 @@ ebl_segment_type_name (Ebl *ebl, int segment, char *buf, size_t len) PTYPE (TLS) }; +#ifndef PT_GNU_PROPERTY +#define PT_GNU_PROPERTY (PT_LOOS + 0x474e553) +#endif + /* Is it one of the standard segment types? */ if (segment >= PT_NULL && segment < PT_NUM) res = ptypes[segment]; @@ -65,6 +69,8 @@ ebl_segment_type_name (Ebl *ebl, int segment, char *buf, size_t len) res = "GNU_STACK"; else if (segment == PT_GNU_RELRO) res = "GNU_RELRO"; + else if (segment == PT_GNU_PROPERTY) + res = "GNU_PROPERTY"; else if (segment == PT_SUNWBSS) res = "SUNWBSS"; else if (segment == PT_SUNWSTACK) |