aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2019-05-30 10:17:29 +0100
committerNick Clifton <nickc@redhat.com>2019-05-30 10:17:29 +0100
commitae9ac79e5e291a2bc5c6620a10c37a3558d55d36 (patch)
tree406f4c6519b7213a2ec7d600bc9cbcb87cd2ef80
parent54a471e5fd44d7a91297ece1383b0ad6d62c7306 (diff)
downloadfsf-binutils-gdb-ae9ac79e5e291a2bc5c6620a10c37a3558d55d36.zip
fsf-binutils-gdb-ae9ac79e5e291a2bc5c6620a10c37a3558d55d36.tar.gz
fsf-binutils-gdb-ae9ac79e5e291a2bc5c6620a10c37a3558d55d36.tar.bz2
Harmonize readelf's output for version sections.
PR 24627 binutils * readelf.c (process_version_sections): Add 0x prefix to address display. Correct indentation. ld * testsuite/ld-elf/ver_def.vd: Update expected output.
-rw-r--r--binutils/ChangeLog6
-rw-r--r--binutils/readelf.c4
-rw-r--r--ld/ChangeLog5
-rw-r--r--ld/testsuite/ld-elf/ver_def.vd2
4 files changed, 14 insertions, 3 deletions
diff --git a/binutils/ChangeLog b/binutils/ChangeLog
index 76d9d52..04710e3 100644
--- a/binutils/ChangeLog
+++ b/binutils/ChangeLog
@@ -1,3 +1,9 @@
+2019-05-30 Nick Clifton <nickc@redhat.com>
+
+ PR 24627
+ * readelf.c (process_version_sections): Add 0x prefix to address
+ display. Correct indentation.
+
2019-05-30 Alan Modra <amodra@gmail.com>
* testsuite/lib/binutils-common.exp (supports_gnu_unique): Add
diff --git a/binutils/readelf.c b/binutils/readelf.c
index 2615e8b..cfa2df5 100644
--- a/binutils/readelf.c
+++ b/binutils/readelf.c
@@ -10550,7 +10550,7 @@ process_version_sections (Filedata * filedata)
printable_section_name (filedata, section),
section->sh_info);
- printf (_(" Addr: 0x"));
+ printf (_(" Addr: 0x"));
printf_vma (section->sh_addr);
printf (_(" Offset: %#08lx Link: %u (%s)\n"),
(unsigned long) section->sh_offset, section->sh_link,
@@ -10842,7 +10842,7 @@ process_version_sections (Filedata * filedata)
total),
printable_section_name (filedata, section), (unsigned long) total);
- printf (_(" Addr: "));
+ printf (_(" Addr: 0x"));
printf_vma (section->sh_addr);
printf (_(" Offset: %#08lx Link: %u (%s)\n"),
(unsigned long) section->sh_offset, section->sh_link,
diff --git a/ld/ChangeLog b/ld/ChangeLog
index f0f7178..70e7241 100644
--- a/ld/ChangeLog
+++ b/ld/ChangeLog
@@ -1,3 +1,8 @@
+2019-05-30 Nick Clifton <nickc@redhat.com>
+
+ PR 24627
+ * testsuite/ld-elf/ver_def.vd: Update expected output.
+
2019-05-30 Alan Modra <amodra@gmail.com>
PR 24596
diff --git a/ld/testsuite/ld-elf/ver_def.vd b/ld/testsuite/ld-elf/ver_def.vd
index f75e15e..b2658ee 100644
--- a/ld/testsuite/ld-elf/ver_def.vd
+++ b/ld/testsuite/ld-elf/ver_def.vd
@@ -6,7 +6,7 @@
# line at the end in particular (hence #pass must not be used here).
Version symbols section '\.gnu\.version' contains 4 entries:
- Addr: [0-9a-f]+ +Offset: 0x[0-9a-f]+ +Link: 2 \(\.dynsym\)
+ +Addr: 0x[0-9a-f]+ +Offset: 0x[0-9a-f]+ +Link: 2 \(\.dynsym\)
+000: +0 \(\*local\*\) +2 \(ver_foo\) +1 \(\*global\*\) +2 \(ver_foo\) +
Version definition section '\.gnu\.version_d' contains 2 entries: