1
From patchwork Tue Jan 10 17:38:16 2012
2
Content-Type: text/plain; charset="utf-8"
4
Content-Transfer-Encoding: 8bit
5
Subject: sparc-linux-user: Fix missing symbols in .rel/.rela.plt sections
6
Date: Tue, 10 Jan 2012 07:38:16 -0000
7
From: Aurelien Jarno <aurelien@aurel32.net>
9
Message-Id: <20120110173816.GB6244@volta.aurel32.net>
10
To: Blue Swirl <blauwirbel@gmail.com>
11
Cc: qemu-devel@nongnu.org
13
sparc-linux-user: Fix missing symbols in .rel/.rela.plt sections
15
Fix .rel.plt sections in the output to not only include .rel.plt
16
sections from the input but also the .rel.iplt sections and to define
17
the hidden symbols __rel_iplt_start and __rel_iplt_end around
18
.rel.iplt as otherwise we get undefined references to these when
19
linking statically to a multiarch enabled libc (using STT_GNU_IFUNC).
21
Cc: Blue Swirl <blauwirbel@gmail.com>
22
Signed-off-by: Aurelien Jarno <aurelien@aurel32.net>
25
ldscripts/sparc.ld | 16 ++++++++++++++--
26
1 files changed, 14 insertions(+), 2 deletions(-)
28
Index: qemu/ldscripts/sparc.ld
29
===================================================================
30
--- qemu.orig/ldscripts/sparc.ld 2013-05-22 19:56:19.641313674 +0200
31
+++ qemu/ldscripts/sparc.ld 2013-05-22 19:56:44.049190718 +0200
33
.rela.fini : { *(.rela.fini) }
34
.rel.bss : { *(.rel.bss) }
35
.rela.bss : { *(.rela.bss) }
36
- .rel.plt : { *(.rel.plt) }
37
- .rela.plt : { *(.rela.plt) }
41
+ PROVIDE (__rel_iplt_start = .);
43
+ PROVIDE (__rel_iplt_end = .);
48
+ PROVIDE (__rela_iplt_start = .);
50
+ PROVIDE (__rela_iplt_end = .);
52
.init : { *(.init) } =0x47ff041f