* emulparams/crislinux.sh (ENTRY): Change back to _start.
(TEXT_START_SYMBOLS): Remove conditional setting of __start. * scripttempl/crisaout.sc: Change all RELOCATING not related to merging non-a.out sections into CONSTRUCTING.
This commit is contained in:
parent
fbc4fff4c6
commit
8c8998585a
3 changed files with 50 additions and 42 deletions
|
@ -1,3 +1,11 @@
|
||||||
|
2000-11-30 Hans-Peter Nilsson <hp@axis.com>
|
||||||
|
|
||||||
|
* emulparams/crislinux.sh (ENTRY): Change back to _start.
|
||||||
|
(TEXT_START_SYMBOLS): Remove conditional setting of __start.
|
||||||
|
|
||||||
|
* scripttempl/crisaout.sc: Change all RELOCATING not related to
|
||||||
|
merging non-a.out sections into CONSTRUCTING.
|
||||||
|
|
||||||
2000-11-28 Nick Clifton <nickc@redhat.com>
|
2000-11-28 Nick Clifton <nickc@redhat.com>
|
||||||
|
|
||||||
* ld.1 (COPYING): Mention that the GNU Free Documentation
|
* ld.1 (COPYING): Mention that the GNU Free Documentation
|
||||||
|
|
|
@ -4,7 +4,9 @@ SCRIPT_NAME=elf
|
||||||
OUTPUT_FORMAT="elf32-cris"
|
OUTPUT_FORMAT="elf32-cris"
|
||||||
ARCH=cris
|
ARCH=cris
|
||||||
TEMPLATE_NAME=elf32
|
TEMPLATE_NAME=elf32
|
||||||
ENTRY=__start
|
|
||||||
|
ENTRY=_start
|
||||||
|
|
||||||
# Needed? Perhaps should be page-size alignment.
|
# Needed? Perhaps should be page-size alignment.
|
||||||
ALIGNMENT=32
|
ALIGNMENT=32
|
||||||
GENERATE_SHLIB_SCRIPT=yes
|
GENERATE_SHLIB_SCRIPT=yes
|
||||||
|
@ -16,12 +18,10 @@ MAXPAGESIZE=8192
|
||||||
|
|
||||||
# FIXME: GOT, PLT...
|
# FIXME: GOT, PLT...
|
||||||
|
|
||||||
TEXT_START_SYMBOLS='PROVIDE (__Stext = .);
|
# We don't do the hoops through DEFINED to provide [_]*start, as it
|
||||||
__start = DEFINED(__start) ? __start :
|
# doesn't work with --gc-sections, and the start-name is pretty fixed
|
||||||
DEFINED(_start) ? _start :
|
# anyway.
|
||||||
DEFINED(start) ? start :
|
TEXT_START_SYMBOLS='PROVIDE (__Stext = .);'
|
||||||
DEFINED(.startup) ? .startup + 2 : 2;
|
|
||||||
'
|
|
||||||
|
|
||||||
# Smuggle an "OTHER_TEXT_END_SYMBOLS" here.
|
# Smuggle an "OTHER_TEXT_END_SYMBOLS" here.
|
||||||
OTHER_READONLY_SECTIONS='PROVIDE (__Etext = .);'
|
OTHER_READONLY_SECTIONS='PROVIDE (__Etext = .);'
|
||||||
|
|
|
@ -7,10 +7,10 @@ SECTIONS
|
||||||
.text ${RELOCATING+ ${TEXT_START_ADDR}}:
|
.text ${RELOCATING+ ${TEXT_START_ADDR}}:
|
||||||
{
|
{
|
||||||
CREATE_OBJECT_SYMBOLS;
|
CREATE_OBJECT_SYMBOLS;
|
||||||
${RELOCATING+ __Stext = .;}
|
${CONSTRUCTING+ __Stext = .;}
|
||||||
${RELOCATING+*(.startup)}
|
${RELOCATING+*(.startup)}
|
||||||
*(.text)
|
*(.text)
|
||||||
${RELOCATING+__start = DEFINED(__start) ? __start :
|
${CONSTRUCTING+__start = DEFINED(__start) ? __start :
|
||||||
DEFINED(_start) ? _start :
|
DEFINED(_start) ? _start :
|
||||||
DEFINED(start) ? start :
|
DEFINED(start) ? start :
|
||||||
DEFINED(.startup) ? .startup + 2 : 2;}
|
DEFINED(.startup) ? .startup + 2 : 2;}
|
||||||
|
@ -25,25 +25,25 @@ SECTIONS
|
||||||
default.
|
default.
|
||||||
FIXME: It's somewhat unexpected to have code emitted by the linker
|
FIXME: It's somewhat unexpected to have code emitted by the linker
|
||||||
script. Some other mechanism could probably do better. */
|
script. Some other mechanism could probably do better. */
|
||||||
${RELOCATING+. = ALIGN (2);}
|
${CONSTRUCTING+ . = ALIGN (2);}
|
||||||
${RELOCATING+ ___init__start = .;}
|
${CONSTRUCTING+ ___init__start = .;}
|
||||||
${RELOCATING+PROVIDE (___do_global_ctors = .);}
|
${CONSTRUCTING+ PROVIDE (___do_global_ctors = .);}
|
||||||
${RELOCATING+SHORT (0xe1fc); /* push srp */}
|
${CONSTRUCTING+ SHORT (0xe1fc); /* push srp */}
|
||||||
${RELOCATING+SHORT (0xbe7e);}
|
${CONSTRUCTING+ SHORT (0xbe7e);}
|
||||||
${RELOCATING+*(.init)}
|
${CONSTRUCTING+ *(.init)}
|
||||||
${RELOCATING+SHORT (0x0d3e); /* jump [sp+] */}
|
${CONSTRUCTING+ SHORT (0x0d3e); /* jump [sp+] */}
|
||||||
${RELOCATING+PROVIDE (__init__end = .);}
|
${CONSTRUCTING+ PROVIDE (__init__end = .);}
|
||||||
${RELOCATING+PROVIDE (___init__end = .);}
|
${CONSTRUCTING+ PROVIDE (___init__end = .);}
|
||||||
|
|
||||||
${RELOCATING+. = ALIGN (2);}
|
${CONSTRUCTING+ . = ALIGN (2);}
|
||||||
${RELOCATING+ ___fini__start = .;}
|
${CONSTRUCTING+ ___fini__start = .;}
|
||||||
${RELOCATING+PROVIDE (___do_global_dtors = .);}
|
${CONSTRUCTING+ PROVIDE (___do_global_dtors = .);}
|
||||||
${RELOCATING+SHORT (0xe1fc); /* push srp */}
|
${CONSTRUCTING+ SHORT (0xe1fc); /* push srp */}
|
||||||
${RELOCATING+SHORT (0xbe7e);}
|
${CONSTRUCTING+ SHORT (0xbe7e);}
|
||||||
${RELOCATING+*(.fini)}
|
${CONSTRUCTING+ *(.fini)}
|
||||||
${RELOCATING+SHORT (0x0d3e); /* jump [sp+] */}
|
${CONSTRUCTING+ SHORT (0x0d3e); /* jump [sp+] */}
|
||||||
${RELOCATING+PROVIDE (__fini__end = .);}
|
${CONSTRUCTING+ PROVIDE (__fini__end = .);}
|
||||||
${RELOCATING+ ___fini__end = .;}
|
${CONSTRUCTING+ ___fini__end = .;}
|
||||||
|
|
||||||
/* Cater to linking from ELF. */
|
/* Cater to linking from ELF. */
|
||||||
${CONSTRUCTING+ PROVIDE(___ctors = .);}
|
${CONSTRUCTING+ PROVIDE(___ctors = .);}
|
||||||
|
@ -68,12 +68,12 @@ SECTIONS
|
||||||
of itself in the a.out header. This should only matter for
|
of itself in the a.out header. This should only matter for
|
||||||
testing; for production use, .data is at a "known" location.
|
testing; for production use, .data is at a "known" location.
|
||||||
We assume .data does not get an alignment larger than 32 bytes. */
|
We assume .data does not get an alignment larger than 32 bytes. */
|
||||||
${RELOCATING+. = ALIGN (32);}
|
${CONSTRUCTING+. = ALIGN (32);}
|
||||||
|
|
||||||
${RELOCATING+ __Etext = .;}
|
${CONSTRUCTING+ __Etext = .;}
|
||||||
|
|
||||||
/* Deprecated, use __Etext. */
|
/* Deprecated, use __Etext. */
|
||||||
${RELOCATING+ PROVIDE(_etext = .);}
|
${CONSTRUCTING+ PROVIDE(_etext = .);}
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Any dot-relative start-expression (such as "ALIGN(2)", also including
|
/* Any dot-relative start-expression (such as "ALIGN(2)", also including
|
||||||
|
@ -84,7 +84,7 @@ SECTIONS
|
||||||
unimportant. */
|
unimportant. */
|
||||||
.data :
|
.data :
|
||||||
{
|
{
|
||||||
${RELOCATING+ __Sdata = .;}
|
${CONSTRUCTING+ __Sdata = .;}
|
||||||
*(.data);
|
*(.data);
|
||||||
${RELOCATING+*(.data.*)}
|
${RELOCATING+*(.data.*)}
|
||||||
${RELOCATING+*(.gnu.linkonce.d*)}
|
${RELOCATING+*(.gnu.linkonce.d*)}
|
||||||
|
@ -92,30 +92,30 @@ SECTIONS
|
||||||
${RELOCATING+*(.gcc_except_table)}
|
${RELOCATING+*(.gcc_except_table)}
|
||||||
|
|
||||||
/* See comment at ALIGN before __Etext. */
|
/* See comment at ALIGN before __Etext. */
|
||||||
${RELOCATING+. = ALIGN (32);}
|
${CONSTRUCTING+. = ALIGN (32);}
|
||||||
|
|
||||||
${RELOCATING+ __Edata = .;}
|
${CONSTRUCTING+ __Edata = .;}
|
||||||
|
|
||||||
/* Deprecated, use __Edata. */
|
/* Deprecated, use __Edata. */
|
||||||
${RELOCATING+ PROVIDE(_edata = .);}
|
${CONSTRUCTING+ PROVIDE(_edata = .);}
|
||||||
}
|
}
|
||||||
|
|
||||||
.bss :
|
.bss :
|
||||||
{
|
{
|
||||||
/* Deprecated, use __Sbss. */
|
/* Deprecated, use __Sbss. */
|
||||||
${RELOCATING+ PROVIDE(_bss_start = .);}
|
${CONSTRUCTING+ PROVIDE(_bss_start = .);}
|
||||||
|
|
||||||
${RELOCATING+ __Sbss = .;}
|
${CONSTRUCTING+ __Sbss = .;}
|
||||||
*(.bss)
|
*(.bss)
|
||||||
${RELOCATING+*(.bss.*)}
|
${RELOCATING+*(.bss.*)}
|
||||||
*(COMMON)
|
*(COMMON)
|
||||||
${RELOCATING+ __Ebss = .;}
|
${CONSTRUCTING+ __Ebss = .;}
|
||||||
|
|
||||||
/* Deprecated, use __Ebss or __Eall as appropriate. */
|
/* Deprecated, use __Ebss or __Eall as appropriate. */
|
||||||
${RELOCATING+ PROVIDE(_end = .);}
|
${CONSTRUCTING+ PROVIDE(_end = .);}
|
||||||
${RELOCATING+ PROVIDE(__end = .);}
|
${CONSTRUCTING+ PROVIDE(__end = .);}
|
||||||
}
|
}
|
||||||
${RELOCATING+ __Eall = .;}
|
${CONSTRUCTING+ __Eall = .;}
|
||||||
|
|
||||||
/* Unfortunately, stabs are not mappable from ELF to a.out.
|
/* Unfortunately, stabs are not mappable from ELF to a.out.
|
||||||
It can probably be fixed with some amount of work. */
|
It can probably be fixed with some amount of work. */
|
||||||
|
@ -123,9 +123,9 @@ SECTIONS
|
||||||
{ *(.stab) *(.stab*) *(.debug) *(.debug*) *(.comment) *(.gnu.warning.*) }
|
{ *(.stab) *(.stab*) *(.debug) *(.debug*) *(.comment) *(.gnu.warning.*) }
|
||||||
|
|
||||||
/* For the rsim and xsim simulators. */
|
/* For the rsim and xsim simulators. */
|
||||||
${RELOCATING+ PROVIDE(__Endmem = 0x10000000);}
|
${CONSTRUCTING+ PROVIDE(__Endmem = 0x10000000);}
|
||||||
|
|
||||||
/* For elinux. */
|
/* For elinux. */
|
||||||
${RELOCATING+ PROVIDE(__Stacksize = 0);}
|
${CONSTRUCTING+ PROVIDE(__Stacksize = 0);}
|
||||||
}
|
}
|
||||||
EOF
|
EOF
|
||||||
|
|
Loading…
Reference in a new issue