1 /* Script for -z combreloc: combine and sort reloc sections */
2 OUTPUT_FORMAT("elf32-littlearm", "elf32-bigarm",
10 /* Read-only sections, merged into text segment: */
11 PROVIDE (__executable_start = SEGMENT_START("text-segment", 0x8000)); . = SEGMENT_START("text-segment", 0x8000) + SIZEOF_HEADERS;
12 .interp : { *(.interp) }
13 .note.gnu.build-id : { *(.note.gnu.build-id) }
15 .gnu.hash : { *(.gnu.hash) }
16 .dynsym : { *(.dynsym) }
17 .dynstr : { *(.dynstr) }
18 .gnu.version : { *(.gnu.version) }
19 .gnu.version_d : { *(.gnu.version_d) }
20 .gnu.version_r : { *(.gnu.version_r) }
24 *(.rel.text .rel.text.* .rel.gnu.linkonce.t.*)
26 *(.rel.rodata .rel.rodata.* .rel.gnu.linkonce.r.*)
27 *(.rel.data.rel.ro* .rel.gnu.linkonce.d.rel.ro.*)
28 *(.rel.data .rel.data.* .rel.gnu.linkonce.d.*)
29 *(.rel.tdata .rel.tdata.* .rel.gnu.linkonce.td.*)
30 *(.rel.tbss .rel.tbss.* .rel.gnu.linkonce.tb.*)
34 *(.rel.bss .rel.bss.* .rel.gnu.linkonce.b.*)
35 PROVIDE_HIDDEN (__rel_iplt_start = .);
37 PROVIDE_HIDDEN (__rel_iplt_end = .);
38 PROVIDE_HIDDEN (__rela_iplt_start = .);
39 PROVIDE_HIDDEN (__rela_iplt_end = .);
44 *(.rela.text .rela.text.* .rela.gnu.linkonce.t.*)
46 *(.rela.rodata .rela.rodata.* .rela.gnu.linkonce.r.*)
47 *(.rela.data .rela.data.* .rela.gnu.linkonce.d.*)
48 *(.rela.tdata .rela.tdata.* .rela.gnu.linkonce.td.*)
49 *(.rela.tbss .rela.tbss.* .rela.gnu.linkonce.tb.*)
53 *(.rela.bss .rela.bss.* .rela.gnu.linkonce.b.*)
54 PROVIDE_HIDDEN (__rel_iplt_start = .);
55 PROVIDE_HIDDEN (__rel_iplt_end = .);
56 PROVIDE_HIDDEN (__rela_iplt_start = .);
58 PROVIDE_HIDDEN (__rela_iplt_end = .);
76 *(.text.unlikely .text.*_unlikely)
77 *(.text.exit .text.exit.*)
78 *(.text.startup .text.startup.*)
79 *(.text.hot .text.hot.*)
80 *(.text .stub .text.* .gnu.linkonce.t.*)
81 /* .gnu.warning sections are handled specially by elf32.em. */
83 *(.glue_7t) *(.glue_7) *(.vfp11_veneer) *(.v4_bx)
89 PROVIDE (__etext = .);
92 .rodata : { *(.rodata .rodata.* .gnu.linkonce.r.*) }
93 .rodata1 : { *(.rodata1) }
94 .ARM.extab : { *(.ARM.extab* .gnu.linkonce.armextab.*) }
95 PROVIDE_HIDDEN (__exidx_start = .);
96 .ARM.exidx : { *(.ARM.exidx* .gnu.linkonce.armexidx.*) }
97 PROVIDE_HIDDEN (__exidx_end = .);
98 .eh_frame_hdr : { *(.eh_frame_hdr) }
99 .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
100 .gcc_except_table : ONLY_IF_RO { *(.gcc_except_table .gcc_except_table.*) }
101 /* Adjust the address for the data segment. We want to adjust up to
102 the same address within the page on the next page up. */
103 . = ALIGN(CONSTANT (MAXPAGESIZE)) + (. & (CONSTANT (MAXPAGESIZE) - 1));
104 /* Exception handling */
105 .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) }
106 .gcc_except_table : ONLY_IF_RW { *(.gcc_except_table .gcc_except_table.*) }
107 /* Thread Local Storage sections */
108 .tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
109 .tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
112 PROVIDE_HIDDEN (__preinit_array_start = .);
113 KEEP (*(.preinit_array))
114 PROVIDE_HIDDEN (__preinit_array_end = .);
118 PROVIDE_HIDDEN (__init_array_start = .);
119 KEEP (*(SORT(.init_array.*)))
120 KEEP (*(.init_array))
121 PROVIDE_HIDDEN (__init_array_end = .);
125 PROVIDE_HIDDEN (__fini_array_start = .);
126 KEEP (*(SORT(.fini_array.*)))
127 KEEP (*(.fini_array))
128 PROVIDE_HIDDEN (__fini_array_end = .);
132 /* gcc uses crtbegin.o to find the start of
133 the constructors, so we make sure it is
134 first. Because this is a wildcard, it
135 doesn't matter if the user does not
136 actually link against crtbegin.o; the
137 linker won't look for a file to match a
138 wildcard. The wildcard also means that it
139 doesn't matter which directory crtbegin.o
141 KEEP (*crtbegin.o(.ctors))
142 KEEP (*crtbegin?.o(.ctors))
143 /* We don't want to include the .ctor section from
144 the crtend.o file until after the sorted ctors.
145 The .ctor section from the crtend file contains the
146 end of ctors marker and it must be last */
147 KEEP (*(EXCLUDE_FILE (*crtend.o *crtend?.o ) .ctors))
148 KEEP (*(SORT(.ctors.*)))
153 KEEP (*crtbegin.o(.dtors))
154 KEEP (*crtbegin?.o(.dtors))
155 KEEP (*(EXCLUDE_FILE (*crtend.o *crtend?.o ) .dtors))
156 KEEP (*(SORT(.dtors.*)))
159 .jcr : { KEEP (*(.jcr)) }
160 .data.rel.ro : { *(.data.rel.ro.local* .gnu.linkonce.d.rel.ro.local.*) *(.data.rel.ro* .gnu.linkonce.d.rel.ro.*) }
161 .dynamic : { *(.dynamic) }
162 .got : { *(.got.plt) *(.igot.plt) *(.got) *(.igot) }
166 *(.data .data.* .gnu.linkonce.d.*)
169 .data1 : { *(.data1) }
170 _edata = .; PROVIDE (edata = .);
176 *(.bss .bss.* .gnu.linkonce.b.*)
178 /* Align here to ensure that the .bss section occupies space up to
179 _end. Align after .bss to ensure correct alignment even if the
180 .bss section disappears because there are no input sections.
181 FIXME: Why do we need it? When there is no .bss section, we don't
182 pad the .data section. */
183 . = ALIGN(. != 0 ? 32 / 8 : 1);
185 _bss_end__ = . ; __bss_end__ = . ;
189 _end = .; PROVIDE (end = .);
190 /* Stabs debugging sections. */
191 .stab 0 : { *(.stab) }
192 .stabstr 0 : { *(.stabstr) }
193 .stab.excl 0 : { *(.stab.excl) }
194 .stab.exclstr 0 : { *(.stab.exclstr) }
195 .stab.index 0 : { *(.stab.index) }
196 .stab.indexstr 0 : { *(.stab.indexstr) }
197 .comment 0 : { *(.comment) }
198 /* DWARF debug sections.
199 Symbols in the DWARF debugging sections are relative to the beginning
200 of the section so we begin them at 0. */
202 .debug 0 : { *(.debug) }
203 .line 0 : { *(.line) }
204 /* GNU DWARF 1 extensions */
205 .debug_srcinfo 0 : { *(.debug_srcinfo .zdebug_srcinfo) }
206 .debug_sfnames 0 : { *(.debug_sfnames .zdebug_sfnames) }
207 /* DWARF 1.1 and DWARF 2 */
208 .debug_aranges 0 : { *(.debug_aranges .zdebug_aranges) }
209 .debug_pubnames 0 : { *(.debug_pubnames .zdebug_pubnames) }
211 .debug_info 0 : { *(.debug_info .gnu.linkonce.wi.* .zdebug_info) }
212 .debug_abbrev 0 : { *(.debug_abbrev .zdebug_abbrev) }
213 .debug_line 0 : { *(.debug_line .zdebug_line) }
214 .debug_frame 0 : { *(.debug_frame .zdebug_frame) }
215 .debug_str 0 : { *(.debug_str .zdebug_str) }
216 .debug_loc 0 : { *(.debug_loc .zdebug_loc) }
217 .debug_macinfo 0 : { *(.debug_macinfo .zdebug_macinfo) }
218 /* SGI/MIPS DWARF 2 extensions */
219 .debug_weaknames 0 : { *(.debug_weaknames .zdebug_weaknames) }
220 .debug_funcnames 0 : { *(.debug_funcnames .zdebug_funcnames) }
221 .debug_typenames 0 : { *(.debug_typenames .zdebug_typenames) }
222 .debug_varnames 0 : { *(.debug_varnames .zdebug_varnames) }
224 .debug_pubtypes 0 : { *(.debug_pubtypes .zdebug_pubtypes) }
225 .debug_ranges 0 : { *(.debug_ranges .zdebug_ranges) }
231 .ARM.attributes 0 : { KEEP (*(.ARM.attributes)) KEEP (*(.gnu.attributes)) }
232 .note.gnu.arm.ident 0 : { KEEP (*(.note.gnu.arm.ident)) }
233 /DISCARD/ : { *(.note.GNU-stack) *(.gnu_debuglink) *(.gnu.lto_*) }