* [Qemu-devel] [PATCH] Fix linker scripts
@ 2011-08-26 9:16 Gerd Hoffmann
2011-08-27 17:53 ` Blue Swirl
0 siblings, 1 reply; 2+ messages in thread
From: Gerd Hoffmann @ 2011-08-26 9:16 UTC (permalink / raw)
To: qemu-devel; +Cc: Gerd Hoffmann
Remove PROVIDE_HIDDEN and ONLY_IF_{RO,RW} from linker scripts to make
them work with older binutils versions. Fixes *-bsd-user build on
OpenBSD 4.9 which ships binutils 2.15.
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
---
arm.ld | 12 ++++++------
hppa.ld | 18 ++++++++----------
i386.ld | 8 ++++----
mips.ld | 18 ++++++++----------
ppc.ld | 18 ++++++++----------
ppc64.ld | 6 ++----
sparc.ld | 12 ++++++------
x86_64.ld | 14 ++++++--------
8 files changed, 48 insertions(+), 58 deletions(-)
diff --git a/arm.ld b/arm.ld
index 12b3edb..7f13da9 100644
--- a/arm.ld
+++ b/arm.ld
@@ -71,23 +71,23 @@ SECTIONS
.data1 : { *(.data1) }
.preinit_array :
{
- PROVIDE_HIDDEN (__preinit_array_start = .);
+ PROVIDE (__preinit_array_start = .);
KEEP (*(.preinit_array))
- PROVIDE_HIDDEN (__preinit_array_end = .);
+ PROVIDE (__preinit_array_end = .);
}
.init_array :
{
- PROVIDE_HIDDEN (__init_array_start = .);
+ PROVIDE (__init_array_start = .);
KEEP (*(SORT(.init_array.*)))
KEEP (*(.init_array))
- PROVIDE_HIDDEN (__init_array_end = .);
+ PROVIDE (__init_array_end = .);
}
.fini_array :
{
- PROVIDE_HIDDEN (__fini_array_start = .);
+ PROVIDE (__fini_array_start = .);
KEEP (*(.fini_array))
KEEP (*(SORT(.fini_array.*)))
- PROVIDE_HIDDEN (__fini_array_end = .);
+ PROVIDE (__fini_array_end = .);
}
.ctors :
{
diff --git a/hppa.ld b/hppa.ld
index 9a4b22c..3555b3e 100644
--- a/hppa.ld
+++ b/hppa.ld
@@ -75,36 +75,34 @@ SECTIONS
.sbss2 : { *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*) }
.PARISC.unwind : { *(.PARISC.unwind) }
.eh_frame_hdr : { *(.eh_frame_hdr) }
- .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
- .gcc_except_table : ONLY_IF_RO { *(.gcc_except_table .gcc_except_table.*) }
/* Adjust the address for the data segment. We want to adjust up to
the same address within the page on the next page up. */
. = ALIGN(0x10000) + (. & (0x10000 - 1));
/* Exception handling */
- .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) }
- .gcc_except_table : ONLY_IF_RW { *(.gcc_except_table .gcc_except_table.*) }
+ .eh_frame : { KEEP (*(.eh_frame)) }
+ .gcc_except_table : { *(.gcc_except_table .gcc_except_table.*) }
/* Thread Local Storage sections */
.tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
.tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
.preinit_array :
{
- PROVIDE_HIDDEN (__preinit_array_start = .);
+ PROVIDE (__preinit_array_start = .);
KEEP (*(.preinit_array))
- PROVIDE_HIDDEN (__preinit_array_end = .);
+ PROVIDE (__preinit_array_end = .);
}
.init_array :
{
- PROVIDE_HIDDEN (__init_array_start = .);
+ PROVIDE (__init_array_start = .);
KEEP (*(SORT(.init_array.*)))
KEEP (*(.init_array))
- PROVIDE_HIDDEN (__init_array_end = .);
+ PROVIDE (__init_array_end = .);
}
.fini_array :
{
- PROVIDE_HIDDEN (__fini_array_start = .);
+ PROVIDE (__fini_array_start = .);
KEEP (*(.fini_array))
KEEP (*(SORT(.fini_array.*)))
- PROVIDE_HIDDEN (__fini_array_end = .);
+ PROVIDE (__fini_array_end = .);
}
.ctors :
{
diff --git a/i386.ld b/i386.ld
index f8df7bf..cc3f160 100644
--- a/i386.ld
+++ b/i386.ld
@@ -42,16 +42,16 @@ SECTIONS
.rel.plt :
{
*(.rel.plt)
- PROVIDE_HIDDEN (__rel_iplt_start = .);
+ PROVIDE (__rel_iplt_start = .);
*(.rel.iplt)
- PROVIDE_HIDDEN (__rel_iplt_end = .);
+ PROVIDE (__rel_iplt_end = .);
}
.rela.plt :
{
*(.rela.plt)
- PROVIDE_HIDDEN (__rela_iplt_start = .);
+ PROVIDE (__rela_iplt_start = .);
*(.rela.iplt)
- PROVIDE_HIDDEN (__rela_iplt_end = .);
+ PROVIDE (__rela_iplt_end = .);
}
.init : { *(.init) } =0x47ff041f
.text :
diff --git a/mips.ld b/mips.ld
index 4294761..7b610ce 100644
--- a/mips.ld
+++ b/mips.ld
@@ -79,36 +79,34 @@ SECTIONS
}
.sbss2 : { *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*) }
.eh_frame_hdr : { *(.eh_frame_hdr) }
- .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
- .gcc_except_table : ONLY_IF_RO { *(.gcc_except_table .gcc_except_table.*) }
/* Adjust the address for the data segment. We want to adjust up to
the same address within the page on the next page up. */
. = ALIGN (0x40000) - ((0x40000 - .) & (0x40000 - 1)); . = DATA_SEGMENT_ALIGN (0x40000, 0x1000);
/* Exception handling */
- .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) }
- .gcc_except_table : ONLY_IF_RW { *(.gcc_except_table .gcc_except_table.*) }
+ .eh_frame : { KEEP (*(.eh_frame)) }
+ .gcc_except_table : { *(.gcc_except_table .gcc_except_table.*) }
/* Thread Local Storage sections */
.tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
.tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
.preinit_array :
{
- PROVIDE_HIDDEN (__preinit_array_start = .);
+ PROVIDE (__preinit_array_start = .);
KEEP (*(.preinit_array))
- PROVIDE_HIDDEN (__preinit_array_end = .);
+ PROVIDE (__preinit_array_end = .);
}
.init_array :
{
- PROVIDE_HIDDEN (__init_array_start = .);
+ PROVIDE (__init_array_start = .);
KEEP (*(SORT(.init_array.*)))
KEEP (*(.init_array))
- PROVIDE_HIDDEN (__init_array_end = .);
+ PROVIDE (__init_array_end = .);
}
.fini_array :
{
- PROVIDE_HIDDEN (__fini_array_start = .);
+ PROVIDE (__fini_array_start = .);
KEEP (*(.fini_array))
KEEP (*(SORT(.fini_array.*)))
- PROVIDE_HIDDEN (__fini_array_end = .);
+ PROVIDE (__fini_array_end = .);
}
.ctors :
{
diff --git a/ppc.ld b/ppc.ld
index 5248ef1..69aa3f2 100644
--- a/ppc.ld
+++ b/ppc.ld
@@ -79,36 +79,34 @@ SECTIONS
}
.sbss2 : { *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*) }
.eh_frame_hdr : { *(.eh_frame_hdr) }
- .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
- .gcc_except_table : ONLY_IF_RO { *(.gcc_except_table .gcc_except_table.*) }
/* Adjust the address for the data segment. We want to adjust up to
the same address within the page on the next page up. */
. = ALIGN (0x10000) - ((0x10000 - .) & (0x10000 - 1)); . = DATA_SEGMENT_ALIGN (0x10000, 0x1000);
/* Exception handling */
- .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) }
- .gcc_except_table : ONLY_IF_RW { *(.gcc_except_table .gcc_except_table.*) }
+ .eh_frame : { KEEP (*(.eh_frame)) }
+ .gcc_except_table : { *(.gcc_except_table .gcc_except_table.*) }
/* Thread Local Storage sections */
.tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
.tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
.preinit_array :
{
- PROVIDE_HIDDEN (__preinit_array_start = .);
+ PROVIDE (__preinit_array_start = .);
KEEP (*(.preinit_array))
- PROVIDE_HIDDEN (__preinit_array_end = .);
+ PROVIDE (__preinit_array_end = .);
}
.init_array :
{
- PROVIDE_HIDDEN (__init_array_start = .);
+ PROVIDE (__init_array_start = .);
KEEP (*(SORT(.init_array.*)))
KEEP (*(.init_array))
- PROVIDE_HIDDEN (__init_array_end = .);
+ PROVIDE (__init_array_end = .);
}
.fini_array :
{
- PROVIDE_HIDDEN (__fini_array_start = .);
+ PROVIDE (__fini_array_start = .);
KEEP (*(.fini_array))
KEEP (*(SORT(.fini_array.*)))
- PROVIDE_HIDDEN (__fini_array_end = .);
+ PROVIDE (__fini_array_end = .);
}
.ctors :
{
diff --git a/ppc64.ld b/ppc64.ld
index dea0dbd..0059ee5 100644
--- a/ppc64.ld
+++ b/ppc64.ld
@@ -81,14 +81,12 @@ SECTIONS
.sdata2 : { *(.sdata2 .sdata2.* .gnu.linkonce.s2.*) }
.sbss2 : { *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*) }
.eh_frame_hdr : { *(.eh_frame_hdr) }
- .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
- .gcc_except_table : ONLY_IF_RO { KEEP (*(.gcc_except_table))
*(.gcc_except_table.*) } /* Adjust the address for the data segment. We want to
adjust up to + the same address within the page on the next page up. */
. = ALIGN (0x10000) - ((0x10000 - .) & (0x10000 - 1)); . = DATA_SEGMENT_ALIGN
(0x10000, 0x1000); /* Exception handling */
- .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) }
- .gcc_except_table : ONLY_IF_RW { KEEP (*(.gcc_except_table))
+ .eh_frame : { KEEP (*(.eh_frame)) }
+ .gcc_except_table : { KEEP (*(.gcc_except_table))
*(.gcc_except_table.*) } /* Thread Local Storage sections */
.tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
.tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
diff --git a/sparc.ld b/sparc.ld
index 31321be..56efe34 100644
--- a/sparc.ld
+++ b/sparc.ld
@@ -67,23 +67,23 @@ SECTIONS
.tbss : { *(.tbss) }
.preinit_array :
{
- PROVIDE_HIDDEN (__preinit_array_start = .);
+ PROVIDE (__preinit_array_start = .);
KEEP (*(.preinit_array))
- PROVIDE_HIDDEN (__preinit_array_end = .);
+ PROVIDE (__preinit_array_end = .);
}
.init_array :
{
- PROVIDE_HIDDEN (__init_array_start = .);
+ PROVIDE (__init_array_start = .);
KEEP (*(SORT(.init_array.*)))
KEEP (*(.init_array))
- PROVIDE_HIDDEN (__init_array_end = .);
+ PROVIDE (__init_array_end = .);
}
.fini_array :
{
- PROVIDE_HIDDEN (__fini_array_start = .);
+ PROVIDE (__fini_array_start = .);
KEEP (*(.fini_array))
KEEP (*(SORT(.fini_array.*)))
- PROVIDE_HIDDEN (__fini_array_end = .);
+ PROVIDE (__fini_array_end = .);
}
.ctors :
{
diff --git a/x86_64.ld b/x86_64.ld
index 46d8d4d..b7a9f4e 100644
--- a/x86_64.ld
+++ b/x86_64.ld
@@ -38,16 +38,16 @@ SECTIONS
.rel.plt :
{
*(.rel.plt)
- PROVIDE_HIDDEN (__rel_iplt_start = .);
+ PROVIDE (__rel_iplt_start = .);
*(.rel.iplt)
- PROVIDE_HIDDEN (__rel_iplt_end = .);
+ PROVIDE (__rel_iplt_end = .);
}
.rela.plt :
{
*(.rela.plt)
- PROVIDE_HIDDEN (__rela_iplt_start = .);
+ PROVIDE (__rela_iplt_start = .);
*(.rela.iplt)
- PROVIDE_HIDDEN (__rela_iplt_end = .);
+ PROVIDE (__rela_iplt_end = .);
}
.init :
{
@@ -70,8 +70,6 @@ SECTIONS
.rodata : { *(.rodata .rodata.* .gnu.linkonce.r.*) }
.rodata1 : { *(.rodata1) }
.eh_frame_hdr : { *(.eh_frame_hdr) }
- .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
- .gcc_except_table : ONLY_IF_RO { *(.gcc_except_table) }
/* Adjust the address for the data segment. We want to adjust up to
the same address within the page on the next page up. */
. = ALIGN (0x100000) - ((0x100000 - .) & (0x100000 - 1)); . = DATA_SEGMENT_ALIGN (0x100000, 0x1000);
@@ -97,8 +95,8 @@ SECTIONS
.data1 : { *(.data1) }
.tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
.tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
- .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) }
- .gcc_except_table : ONLY_IF_RW { *(.gcc_except_table) }
+ .eh_frame : { KEEP (*(.eh_frame)) }
+ .gcc_except_table : { *(.gcc_except_table) }
.dynamic : { *(.dynamic) }
.ctors :
{
--
1.7.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [Qemu-devel] [PATCH] Fix linker scripts
2011-08-26 9:16 [Qemu-devel] [PATCH] Fix linker scripts Gerd Hoffmann
@ 2011-08-27 17:53 ` Blue Swirl
0 siblings, 0 replies; 2+ messages in thread
From: Blue Swirl @ 2011-08-27 17:53 UTC (permalink / raw)
To: Gerd Hoffmann; +Cc: qemu-devel
Thanks, applied.
On Fri, Aug 26, 2011 at 9:16 AM, Gerd Hoffmann <kraxel@redhat.com> wrote:
> Remove PROVIDE_HIDDEN and ONLY_IF_{RO,RW} from linker scripts to make
> them work with older binutils versions. Fixes *-bsd-user build on
> OpenBSD 4.9 which ships binutils 2.15.
>
> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
> ---
> arm.ld | 12 ++++++------
> hppa.ld | 18 ++++++++----------
> i386.ld | 8 ++++----
> mips.ld | 18 ++++++++----------
> ppc.ld | 18 ++++++++----------
> ppc64.ld | 6 ++----
> sparc.ld | 12 ++++++------
> x86_64.ld | 14 ++++++--------
> 8 files changed, 48 insertions(+), 58 deletions(-)
>
> diff --git a/arm.ld b/arm.ld
> index 12b3edb..7f13da9 100644
> --- a/arm.ld
> +++ b/arm.ld
> @@ -71,23 +71,23 @@ SECTIONS
> .data1 : { *(.data1) }
> .preinit_array :
> {
> - PROVIDE_HIDDEN (__preinit_array_start = .);
> + PROVIDE (__preinit_array_start = .);
> KEEP (*(.preinit_array))
> - PROVIDE_HIDDEN (__preinit_array_end = .);
> + PROVIDE (__preinit_array_end = .);
> }
> .init_array :
> {
> - PROVIDE_HIDDEN (__init_array_start = .);
> + PROVIDE (__init_array_start = .);
> KEEP (*(SORT(.init_array.*)))
> KEEP (*(.init_array))
> - PROVIDE_HIDDEN (__init_array_end = .);
> + PROVIDE (__init_array_end = .);
> }
> .fini_array :
> {
> - PROVIDE_HIDDEN (__fini_array_start = .);
> + PROVIDE (__fini_array_start = .);
> KEEP (*(.fini_array))
> KEEP (*(SORT(.fini_array.*)))
> - PROVIDE_HIDDEN (__fini_array_end = .);
> + PROVIDE (__fini_array_end = .);
> }
> .ctors :
> {
> diff --git a/hppa.ld b/hppa.ld
> index 9a4b22c..3555b3e 100644
> --- a/hppa.ld
> +++ b/hppa.ld
> @@ -75,36 +75,34 @@ SECTIONS
> .sbss2 : { *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*) }
> .PARISC.unwind : { *(.PARISC.unwind) }
> .eh_frame_hdr : { *(.eh_frame_hdr) }
> - .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
> - .gcc_except_table : ONLY_IF_RO { *(.gcc_except_table .gcc_except_table.*) }
> /* Adjust the address for the data segment. We want to adjust up to
> the same address within the page on the next page up. */
> . = ALIGN(0x10000) + (. & (0x10000 - 1));
> /* Exception handling */
> - .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) }
> - .gcc_except_table : ONLY_IF_RW { *(.gcc_except_table .gcc_except_table.*) }
> + .eh_frame : { KEEP (*(.eh_frame)) }
> + .gcc_except_table : { *(.gcc_except_table .gcc_except_table.*) }
> /* Thread Local Storage sections */
> .tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
> .tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
> .preinit_array :
> {
> - PROVIDE_HIDDEN (__preinit_array_start = .);
> + PROVIDE (__preinit_array_start = .);
> KEEP (*(.preinit_array))
> - PROVIDE_HIDDEN (__preinit_array_end = .);
> + PROVIDE (__preinit_array_end = .);
> }
> .init_array :
> {
> - PROVIDE_HIDDEN (__init_array_start = .);
> + PROVIDE (__init_array_start = .);
> KEEP (*(SORT(.init_array.*)))
> KEEP (*(.init_array))
> - PROVIDE_HIDDEN (__init_array_end = .);
> + PROVIDE (__init_array_end = .);
> }
> .fini_array :
> {
> - PROVIDE_HIDDEN (__fini_array_start = .);
> + PROVIDE (__fini_array_start = .);
> KEEP (*(.fini_array))
> KEEP (*(SORT(.fini_array.*)))
> - PROVIDE_HIDDEN (__fini_array_end = .);
> + PROVIDE (__fini_array_end = .);
> }
> .ctors :
> {
> diff --git a/i386.ld b/i386.ld
> index f8df7bf..cc3f160 100644
> --- a/i386.ld
> +++ b/i386.ld
> @@ -42,16 +42,16 @@ SECTIONS
> .rel.plt :
> {
> *(.rel.plt)
> - PROVIDE_HIDDEN (__rel_iplt_start = .);
> + PROVIDE (__rel_iplt_start = .);
> *(.rel.iplt)
> - PROVIDE_HIDDEN (__rel_iplt_end = .);
> + PROVIDE (__rel_iplt_end = .);
> }
> .rela.plt :
> {
> *(.rela.plt)
> - PROVIDE_HIDDEN (__rela_iplt_start = .);
> + PROVIDE (__rela_iplt_start = .);
> *(.rela.iplt)
> - PROVIDE_HIDDEN (__rela_iplt_end = .);
> + PROVIDE (__rela_iplt_end = .);
> }
> .init : { *(.init) } =0x47ff041f
> .text :
> diff --git a/mips.ld b/mips.ld
> index 4294761..7b610ce 100644
> --- a/mips.ld
> +++ b/mips.ld
> @@ -79,36 +79,34 @@ SECTIONS
> }
> .sbss2 : { *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*) }
> .eh_frame_hdr : { *(.eh_frame_hdr) }
> - .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
> - .gcc_except_table : ONLY_IF_RO { *(.gcc_except_table .gcc_except_table.*) }
> /* Adjust the address for the data segment. We want to adjust up to
> the same address within the page on the next page up. */
> . = ALIGN (0x40000) - ((0x40000 - .) & (0x40000 - 1)); . = DATA_SEGMENT_ALIGN (0x40000, 0x1000);
> /* Exception handling */
> - .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) }
> - .gcc_except_table : ONLY_IF_RW { *(.gcc_except_table .gcc_except_table.*) }
> + .eh_frame : { KEEP (*(.eh_frame)) }
> + .gcc_except_table : { *(.gcc_except_table .gcc_except_table.*) }
> /* Thread Local Storage sections */
> .tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
> .tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
> .preinit_array :
> {
> - PROVIDE_HIDDEN (__preinit_array_start = .);
> + PROVIDE (__preinit_array_start = .);
> KEEP (*(.preinit_array))
> - PROVIDE_HIDDEN (__preinit_array_end = .);
> + PROVIDE (__preinit_array_end = .);
> }
> .init_array :
> {
> - PROVIDE_HIDDEN (__init_array_start = .);
> + PROVIDE (__init_array_start = .);
> KEEP (*(SORT(.init_array.*)))
> KEEP (*(.init_array))
> - PROVIDE_HIDDEN (__init_array_end = .);
> + PROVIDE (__init_array_end = .);
> }
> .fini_array :
> {
> - PROVIDE_HIDDEN (__fini_array_start = .);
> + PROVIDE (__fini_array_start = .);
> KEEP (*(.fini_array))
> KEEP (*(SORT(.fini_array.*)))
> - PROVIDE_HIDDEN (__fini_array_end = .);
> + PROVIDE (__fini_array_end = .);
> }
> .ctors :
> {
> diff --git a/ppc.ld b/ppc.ld
> index 5248ef1..69aa3f2 100644
> --- a/ppc.ld
> +++ b/ppc.ld
> @@ -79,36 +79,34 @@ SECTIONS
> }
> .sbss2 : { *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*) }
> .eh_frame_hdr : { *(.eh_frame_hdr) }
> - .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
> - .gcc_except_table : ONLY_IF_RO { *(.gcc_except_table .gcc_except_table.*) }
> /* Adjust the address for the data segment. We want to adjust up to
> the same address within the page on the next page up. */
> . = ALIGN (0x10000) - ((0x10000 - .) & (0x10000 - 1)); . = DATA_SEGMENT_ALIGN (0x10000, 0x1000);
> /* Exception handling */
> - .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) }
> - .gcc_except_table : ONLY_IF_RW { *(.gcc_except_table .gcc_except_table.*) }
> + .eh_frame : { KEEP (*(.eh_frame)) }
> + .gcc_except_table : { *(.gcc_except_table .gcc_except_table.*) }
> /* Thread Local Storage sections */
> .tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
> .tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
> .preinit_array :
> {
> - PROVIDE_HIDDEN (__preinit_array_start = .);
> + PROVIDE (__preinit_array_start = .);
> KEEP (*(.preinit_array))
> - PROVIDE_HIDDEN (__preinit_array_end = .);
> + PROVIDE (__preinit_array_end = .);
> }
> .init_array :
> {
> - PROVIDE_HIDDEN (__init_array_start = .);
> + PROVIDE (__init_array_start = .);
> KEEP (*(SORT(.init_array.*)))
> KEEP (*(.init_array))
> - PROVIDE_HIDDEN (__init_array_end = .);
> + PROVIDE (__init_array_end = .);
> }
> .fini_array :
> {
> - PROVIDE_HIDDEN (__fini_array_start = .);
> + PROVIDE (__fini_array_start = .);
> KEEP (*(.fini_array))
> KEEP (*(SORT(.fini_array.*)))
> - PROVIDE_HIDDEN (__fini_array_end = .);
> + PROVIDE (__fini_array_end = .);
> }
> .ctors :
> {
> diff --git a/ppc64.ld b/ppc64.ld
> index dea0dbd..0059ee5 100644
> --- a/ppc64.ld
> +++ b/ppc64.ld
> @@ -81,14 +81,12 @@ SECTIONS
> .sdata2 : { *(.sdata2 .sdata2.* .gnu.linkonce.s2.*) }
> .sbss2 : { *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*) }
> .eh_frame_hdr : { *(.eh_frame_hdr) }
> - .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
> - .gcc_except_table : ONLY_IF_RO { KEEP (*(.gcc_except_table))
> *(.gcc_except_table.*) } /* Adjust the address for the data segment. We want to
> adjust up to + the same address within the page on the next page up. */
> . = ALIGN (0x10000) - ((0x10000 - .) & (0x10000 - 1)); . = DATA_SEGMENT_ALIGN
> (0x10000, 0x1000); /* Exception handling */
> - .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) }
> - .gcc_except_table : ONLY_IF_RW { KEEP (*(.gcc_except_table))
> + .eh_frame : { KEEP (*(.eh_frame)) }
> + .gcc_except_table : { KEEP (*(.gcc_except_table))
> *(.gcc_except_table.*) } /* Thread Local Storage sections */
> .tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
> .tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
> diff --git a/sparc.ld b/sparc.ld
> index 31321be..56efe34 100644
> --- a/sparc.ld
> +++ b/sparc.ld
> @@ -67,23 +67,23 @@ SECTIONS
> .tbss : { *(.tbss) }
> .preinit_array :
> {
> - PROVIDE_HIDDEN (__preinit_array_start = .);
> + PROVIDE (__preinit_array_start = .);
> KEEP (*(.preinit_array))
> - PROVIDE_HIDDEN (__preinit_array_end = .);
> + PROVIDE (__preinit_array_end = .);
> }
> .init_array :
> {
> - PROVIDE_HIDDEN (__init_array_start = .);
> + PROVIDE (__init_array_start = .);
> KEEP (*(SORT(.init_array.*)))
> KEEP (*(.init_array))
> - PROVIDE_HIDDEN (__init_array_end = .);
> + PROVIDE (__init_array_end = .);
> }
> .fini_array :
> {
> - PROVIDE_HIDDEN (__fini_array_start = .);
> + PROVIDE (__fini_array_start = .);
> KEEP (*(.fini_array))
> KEEP (*(SORT(.fini_array.*)))
> - PROVIDE_HIDDEN (__fini_array_end = .);
> + PROVIDE (__fini_array_end = .);
> }
> .ctors :
> {
> diff --git a/x86_64.ld b/x86_64.ld
> index 46d8d4d..b7a9f4e 100644
> --- a/x86_64.ld
> +++ b/x86_64.ld
> @@ -38,16 +38,16 @@ SECTIONS
> .rel.plt :
> {
> *(.rel.plt)
> - PROVIDE_HIDDEN (__rel_iplt_start = .);
> + PROVIDE (__rel_iplt_start = .);
> *(.rel.iplt)
> - PROVIDE_HIDDEN (__rel_iplt_end = .);
> + PROVIDE (__rel_iplt_end = .);
> }
> .rela.plt :
> {
> *(.rela.plt)
> - PROVIDE_HIDDEN (__rela_iplt_start = .);
> + PROVIDE (__rela_iplt_start = .);
> *(.rela.iplt)
> - PROVIDE_HIDDEN (__rela_iplt_end = .);
> + PROVIDE (__rela_iplt_end = .);
> }
> .init :
> {
> @@ -70,8 +70,6 @@ SECTIONS
> .rodata : { *(.rodata .rodata.* .gnu.linkonce.r.*) }
> .rodata1 : { *(.rodata1) }
> .eh_frame_hdr : { *(.eh_frame_hdr) }
> - .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
> - .gcc_except_table : ONLY_IF_RO { *(.gcc_except_table) }
> /* Adjust the address for the data segment. We want to adjust up to
> the same address within the page on the next page up. */
> . = ALIGN (0x100000) - ((0x100000 - .) & (0x100000 - 1)); . = DATA_SEGMENT_ALIGN (0x100000, 0x1000);
> @@ -97,8 +95,8 @@ SECTIONS
> .data1 : { *(.data1) }
> .tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
> .tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
> - .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) }
> - .gcc_except_table : ONLY_IF_RW { *(.gcc_except_table) }
> + .eh_frame : { KEEP (*(.eh_frame)) }
> + .gcc_except_table : { *(.gcc_except_table) }
> .dynamic : { *(.dynamic) }
> .ctors :
> {
> --
> 1.7.1
>
>
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-08-27 17:53 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-08-26 9:16 [Qemu-devel] [PATCH] Fix linker scripts Gerd Hoffmann
2011-08-27 17:53 ` Blue Swirl
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).