* ldmain.c (main): Error if --gc-sections and

dyanmic linking.
        * scripttempl/v850.sc:  Add KEEP attribute to .init,
        .fini, .dtors and .ctors.  Add .data and .text
        wildcards to support section garbage collection.
This commit is contained in:
Catherine Moore 1998-10-05 14:48:32 +00:00
parent d284b1f7c5
commit 64923bb947
2 changed files with 15 additions and 5 deletions

View File

@ -1,3 +1,11 @@
Mon Oct 5 09:40:43 1998 Catherine Moore <clm@cygnus.com>
* ldmain.c (main): Error if --gc-sections and
dyanmic linking.
* scripttempl/v850.sc: Add KEEP attribute to .init,
.fini, .dtors and .ctors. Add .data and .text
wildcards to support section garbage collection.
Wed Sep 30 11:19:15 1998 Nick Clifton <nickc@cygnus.com> Wed Sep 30 11:19:15 1998 Nick Clifton <nickc@cygnus.com>
* scripttempl/v850.sc: Rename .call_table section to * scripttempl/v850.sc: Rename .call_table section to

View File

@ -55,11 +55,12 @@ SECTIONS
.rela.bss : { *(.rela.bss) } .rela.bss : { *(.rela.bss) }
.rel.plt : { *(.rel.plt) } .rel.plt : { *(.rel.plt) }
.rela.plt : { *(.rela.plt) } .rela.plt : { *(.rela.plt) }
.init : { *(.init) } =0 .init : { KEEP (*(.init)) } =0
.plt : { *(.plt) } .plt : { *(.plt) }
.text : { .text : {
*(.text) *(.text)
${RELOCATING+*(.text.*)}
/* .gnu.warning sections are handled specially by elf32.em. */ /* .gnu.warning sections are handled specially by elf32.em. */
*(.gnu.warning) *(.gnu.warning)
*(.gnu.linkonce.t*) *(.gnu.linkonce.t*)
@ -83,25 +84,26 @@ SECTIONS
/* end-sanitize-v850e */ /* end-sanitize-v850e */
.fini : { *(.fini) } =0 .fini : { KEEP (*(.fini)) } =0
.rodata : { *(.rodata) *(.gnu.linkonce.r*) } .rodata : { *(.rodata) ${RELOCATING+*(.rodata.*)} *(.gnu.linkonce.r*) }
.rodata1 : { *(.rodata1) } .rodata1 : { *(.rodata1) }
.data : { .data : {
*(.data) *(.data)
${RELOCATING+*(.data.*)}
*(.gnu.linkonce.d*) *(.gnu.linkonce.d*)
CONSTRUCTORS CONSTRUCTORS
} }
.data1 : { *(.data1) } .data1 : { *(.data1) }
.ctors : { .ctors : {
${RELOCATING+___ctors = .;} ${RELOCATING+___ctors = .;}
*(.ctors) KEEP (*(.ctors))
${RELOCATING+___ctors_end = .;} ${RELOCATING+___ctors_end = .;}
} }
.dtors : { .dtors : {
${RELOCATING+___dtors = .;} ${RELOCATING+___dtors = .;}
*(.dtors) KEEP (*(.dtors))
${RELOCATING+___dtors_end = .;} ${RELOCATING+___dtors_end = .;}
} }