aboutsummaryrefslogtreecommitdiff
path: root/binutils
diff options
context:
space:
mode:
authorNick Alcock <nick.alcock@oracle.com>2020-11-23 21:30:24 +0000
committerNick Alcock <nick.alcock@oracle.com>2020-11-25 19:11:35 +0000
commit96c61be508fa8fdef79f2f3f3b9140dd75b05207 (patch)
tree78cb5c72415cba40655729a267263deec41df8ef /binutils
parent53651de80f811495262a5b17b774a486dd37b326 (diff)
downloadfsf-binutils-gdb-96c61be508fa8fdef79f2f3f3b9140dd75b05207.zip
fsf-binutils-gdb-96c61be508fa8fdef79f2f3f3b9140dd75b05207.tar.gz
fsf-binutils-gdb-96c61be508fa8fdef79f2f3f3b9140dd75b05207.tar.bz2
binutils: readelf: support CTF dicts with non-native-endian symtabs
Now we have a way to tell libctf what the endianness of the symtab is, get readelf to use it. (objdump doesn't need to do so, nor does ld, because they both use BFD-aware mechanisms to open CTF dicts, so libctf can automatically figure the symtab endianness out.) binutils/ChangeLog 2020-11-23 Nick Alcock <nick.alcock@oracle.com> * readelf.c (dump_section_as_ctf): Call ctf_arc_symsect_endianness.
Diffstat (limited to 'binutils')
-rw-r--r--binutils/ChangeLog4
-rw-r--r--binutils/readelf.c3
2 files changed, 7 insertions, 0 deletions
diff --git a/binutils/ChangeLog b/binutils/ChangeLog
index 8485398..e03c892 100644
--- a/binutils/ChangeLog
+++ b/binutils/ChangeLog
@@ -1,3 +1,7 @@
+2020-11-23 Nick Alcock <nick.alcock@oracle.com>
+
+ * readelf.c (dump_section_as_ctf): Call ctf_arc_symsect_endianness.
+
2020-11-25 Alan Modra <amodra@gmail.com>
* testsuite/binutils-all/nm.exp (ifunc): xfail more targets.
diff --git a/binutils/readelf.c b/binutils/readelf.c
index e4d96bb..57e0f1d 100644
--- a/binutils/readelf.c
+++ b/binutils/readelf.c
@@ -14758,6 +14758,9 @@ dump_section_as_ctf (Elf_Internal_Shdr * section, Filedata * filedata)
goto fail;
}
+ ctf_arc_symsect_endianness (ctfa, filedata->file_header.e_ident[EI_DATA]
+ != ELFDATA2MSB);
+
if (parentdata)
{
if ((parenta = ctf_arc_bufopen (&parentsect, symsectp, strsectp,