add support for embedded relocs in m68k ELF port
[deliverable/binutils-gdb.git] / ld / emulparams / criself.sh
CommitLineData
9d06555c
HPN
1# This is for embedded products (no MMU) with ELF.
2MACHINE=
3SCRIPT_NAME=elf
4TEMPLATE_NAME=elf32
5OUTPUT_FORMAT="elf32-cris"
6ARCH=cris
7MAXPAGESIZE=32
8ENTRY=_start
9EMBEDDED=yes
10ALIGNMENT=32
11TEXT_START_ADDR=0
12
13# Put crt0 for flash/eprom etc. in this section.
14INITIAL_READONLY_SECTIONS='.startup : { *(.startup) }'
15
16# TEXT_START_SYMBOLS doesn't get what we want which is the start of
17# all read-only sections; there's at least .init and .fini before it.
18# We have to resort to trickery.
19EXECUTABLE_SYMBOLS='PROVIDE (__Stext = .);'
20
21# Smuggle an "OTHER_TEXT_END_SYMBOLS" here.
22OTHER_READONLY_SECTIONS='PROVIDE (__Etext = .);'
23DATA_START_SYMBOLS='PROVIDE (__Sdata = .);'
24
25# Smuggle an "OTHER_DATA_END_SYMBOLS" here.
26OTHER_GOT_SECTIONS='PROVIDE (__Edata = .);'
27
28# If .bss does not immediately follow .data but has its own start
29# address, we can't get to it with OTHER_BSS_SYMBOLS, neither can we
30# use ADDR(.bss) there. Instead, we use the symbol support for the
31# end symbol.
32OTHER_BSS_END_SYMBOLS='
33 PROVIDE (__Ebss = .);
34 PROVIDE (__end = .);
35 __Sbss = SIZEOF (.sbss) != 0 ? ADDR (.sbss) : ADDR (.bss);
36 PROVIDE (_bss_start = __Sbss);
37'
38
39INIT_START='
40 . = ALIGN(2);
41 ___init__start = .;
42 PROVIDE (___do_global_ctors = .);
43 SHORT (0xe1fc); /* push srp */
44 SHORT (0xbe7e);
45'
46
47INIT_END='
48 SHORT (0x0d3e); /* jump [sp+] */
49 PROVIDE (__init__end = .);
50 PROVIDE (___init__end = .);
51'
52
53FINI_START='
54 . = ALIGN (2);
55 ___fini__start = .;
56 PROVIDE (___do_global_dtors = .);
57 SHORT (0xe1fc); /* push srp */
58 SHORT (0xbe7e);
59'
60
61FINI_END='
62 SHORT (0x0d3e); /* jump [sp+] */
63 PROVIDE (__fini__end = .);
64 ___fini__end = .;
65'
66
67CTOR_START='
68 PROVIDE (___ctors = .);
69 ___elf_ctors_dtors_begin = .;
70'
71
72CTOR_END='
73 PROVIDE (___ctors_end = .);
74'
75
76DTOR_START='
77 PROVIDE (___dtors = .);
78'
79
80CTOR_END='
81 PROVIDE (___dtors_end = .);
82 ___elf_ctors_dtors_end = .;
83'
84
85
86# Smuggle an "OTHER_ALL_END_SYMBOLS" here.
87# Also add the other symbols provided for rsim/xsim and elinux.
88OTHER_RELOCATING_SECTIONS='
89PROVIDE (__Eall = .);
90PROVIDE (__Endmem = 0x10000000);
91PROVIDE (__Stacksize = 0);
92'
This page took 0.042094 seconds and 4 git commands to generate.