mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-10-16 12:24:19 +08:00
[PATCH 1/2] coff-go32: update ldscript
* scripttempl/i386go32.sc: Provide symbol _environ. Link in .ctors and .dtors. Discard LTO sections.
This commit is contained in:

committed by
Nick Clifton

parent
49c16254b4
commit
0fe0f2d621
@ -1,3 +1,9 @@
|
|||||||
|
2020-04-17 Juan Manuel Guerrero <juan.guerrero@gmx.de>
|
||||||
|
Jan W. Jagersma <jwjagersma@gmail.com>
|
||||||
|
|
||||||
|
* scripttempl/i386go32.sc: Provide symbol _environ. Link in
|
||||||
|
.ctors and .dtors. Discard LTO sections.
|
||||||
|
|
||||||
2020-04-17 Nick Clifton <nickc@redhat.com>
|
2020-04-17 Nick Clifton <nickc@redhat.com>
|
||||||
|
|
||||||
* testsuite/config/default.exp: If not already set then create the
|
* testsuite/config/default.exp: If not already set then create the
|
||||||
|
@ -43,15 +43,21 @@ SECTIONS
|
|||||||
${RELOCATING+etext = . ; PROVIDE(_etext = .) ;}
|
${RELOCATING+etext = . ; PROVIDE(_etext = .) ;}
|
||||||
${RELOCATING+. = ALIGN(${SEGMENT_SIZE});}
|
${RELOCATING+. = ALIGN(${SEGMENT_SIZE});}
|
||||||
}
|
}
|
||||||
|
|
||||||
.data ${RELOCATING+ ${DATA_ALIGNMENT}} : {
|
.data ${RELOCATING+ ${DATA_ALIGNMENT}} : {
|
||||||
${RELOCATING+djgpp_first_ctor = . ;
|
${RELOCATING+djgpp_first_ctor = . ;
|
||||||
*(SORT(.ctors.*))
|
*(SORT(.ctors.*))
|
||||||
*(.ctor)
|
*(.ctor)
|
||||||
|
*(.ctors)
|
||||||
djgpp_last_ctor = . ;}
|
djgpp_last_ctor = . ;}
|
||||||
${RELOCATING+djgpp_first_dtor = . ;
|
${RELOCATING+djgpp_first_dtor = . ;
|
||||||
*(SORT(.dtors.*))
|
*(SORT(.dtors.*))
|
||||||
*(.dtor)
|
*(.dtor)
|
||||||
|
*(.dtors)
|
||||||
djgpp_last_dtor = . ;}
|
djgpp_last_dtor = . ;}
|
||||||
|
__environ = . ;
|
||||||
|
PROVIDE(_environ = .) ;
|
||||||
|
LONG(0) ;
|
||||||
*(.data)
|
*(.data)
|
||||||
${RELOCATING+*(.data.*)}
|
${RELOCATING+*(.data.*)}
|
||||||
|
|
||||||
@ -65,8 +71,10 @@ SECTIONS
|
|||||||
${RELOCATING+edata = . ; PROVIDE(_edata = .) ;}
|
${RELOCATING+edata = . ; PROVIDE(_edata = .) ;}
|
||||||
${RELOCATING+. = ALIGN(${SEGMENT_SIZE});}
|
${RELOCATING+. = ALIGN(${SEGMENT_SIZE});}
|
||||||
}
|
}
|
||||||
|
|
||||||
${CONSTRUCTING+${RELOCATING-$CTOR}}
|
${CONSTRUCTING+${RELOCATING-$CTOR}}
|
||||||
${CONSTRUCTING+${RELOCATING-$DTOR}}
|
${CONSTRUCTING+${RELOCATING-$DTOR}}
|
||||||
|
|
||||||
.bss ${RELOCATING+ SIZEOF(.data) + ADDR(.data)} :
|
.bss ${RELOCATING+ SIZEOF(.data) + ADDR(.data)} :
|
||||||
{
|
{
|
||||||
*(.bss${RELOCATING+ .bss.* .gnu.linkonce.b.*})
|
*(.bss${RELOCATING+ .bss.* .gnu.linkonce.b.*})
|
||||||
@ -74,6 +82,10 @@ SECTIONS
|
|||||||
${RELOCATING+ end = . ; PROVIDE(_end = .) ;}
|
${RELOCATING+ end = . ; PROVIDE(_end = .) ;}
|
||||||
${RELOCATING+ . = ALIGN(${SEGMENT_SIZE});}
|
${RELOCATING+ . = ALIGN(${SEGMENT_SIZE});}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Discard LTO sections. */
|
||||||
|
/DISCARD/ : { *(.gnu.lto_*) }
|
||||||
|
|
||||||
/* Stabs debugging sections. */
|
/* Stabs debugging sections. */
|
||||||
.stab 0 : { *(.stab) }
|
.stab 0 : { *(.stab) }
|
||||||
.stabstr 0 : { *(.stabstr) }
|
.stabstr 0 : { *(.stabstr) }
|
||||||
|
Reference in New Issue
Block a user