1 /* Script for -N: mix text and data on same page; don't align data */
2 OUTPUT_FORMAT("elf32-ntradbigmips", "elf32-ntradbigmips",
3 "elf32-ntradlittlemips")
6 SEARCH_DIR("/opt/brcm/hndtools-mipsel-uclibc-4.2.4/mipsel-linux-uclibc/lib32"); SEARCH_DIR("=/usr/local/lib32"); SEARCH_DIR("=/lib32"); SEARCH_DIR("=/usr/lib32"); SEARCH_DIR("=/usr/local/lib"); SEARCH_DIR("=/lib"); SEARCH_DIR("=/usr/lib");
9 /* Read-only sections, merged into text segment: */
10 PROVIDE (__executable_start = SEGMENT_START("text-segment", 0x10000000)); . = SEGMENT_START("text-segment", 0x10000000) + SIZEOF_HEADERS;
11 .interp : { *(.interp) }
12 .reginfo : { *(.reginfo) }
13 .note.gnu.build-id : { *(.note.gnu.build-id) }
14 .dynamic : { *(.dynamic) }
16 .gnu.hash : { *(.gnu.hash) }
17 .dynsym : { *(.dynsym) }
18 .dynstr : { *(.dynstr) }
19 .gnu.version : { *(.gnu.version) }
20 .gnu.version_d : { *(.gnu.version_d) }
21 .gnu.version_r : { *(.gnu.version_r) }
22 .rel.init : { *(.rel.init) }
23 .rela.init : { *(.rela.init) }
24 .rel.text : { *(.rel.text .rel.text.* .rel.gnu.linkonce.t.*) }
25 .rela.text : { *(.rela.text .rela.text.* .rela.gnu.linkonce.t.*) }
26 .rel.fini : { *(.rel.fini) }
27 .rela.fini : { *(.rela.fini) }
28 .rel.rodata : { *(.rel.rodata .rel.rodata.* .rel.gnu.linkonce.r.*) }
29 .rela.rodata : { *(.rela.rodata .rela.rodata.* .rela.gnu.linkonce.r.*) }
30 .rel.data.rel.ro : { *(.rel.data.rel.ro* .rel.gnu.linkonce.d.rel.ro.*) }
31 .rela.data.rel.ro : { *(.rela.data.rel.ro* .rela.gnu.linkonce.d.rel.ro.*) }
32 .rel.data : { *(.rel.data .rel.data.* .rel.gnu.linkonce.d.*) }
33 .rela.data : { *(.rela.data .rela.data.* .rela.gnu.linkonce.d.*) }
34 .rel.tdata : { *(.rel.tdata .rel.tdata.* .rel.gnu.linkonce.td.*) }
35 .rela.tdata : { *(.rela.tdata .rela.tdata.* .rela.gnu.linkonce.td.*) }
36 .rel.tbss : { *(.rel.tbss .rel.tbss.* .rel.gnu.linkonce.tb.*) }
37 .rela.tbss : { *(.rela.tbss .rela.tbss.* .rela.gnu.linkonce.tb.*) }
38 .rel.ctors : { *(.rel.ctors) }
39 .rela.ctors : { *(.rela.ctors) }
40 .rel.dtors : { *(.rel.dtors) }
41 .rela.dtors : { *(.rela.dtors) }
42 .rel.got : { *(.rel.got) }
43 .rela.got : { *(.rela.got) }
44 .rel.dyn : { *(.rel.dyn) }
45 .rel.sdata : { *(.rel.sdata .rel.sdata.* .rel.gnu.linkonce.s.*) }
46 .rela.sdata : { *(.rela.sdata .rela.sdata.* .rela.gnu.linkonce.s.*) }
47 .rel.sbss : { *(.rel.sbss .rel.sbss.* .rel.gnu.linkonce.sb.*) }
48 .rela.sbss : { *(.rela.sbss .rela.sbss.* .rela.gnu.linkonce.sb.*) }
49 .rel.sdata2 : { *(.rel.sdata2 .rel.sdata2.* .rel.gnu.linkonce.s2.*) }
50 .rela.sdata2 : { *(.rela.sdata2 .rela.sdata2.* .rela.gnu.linkonce.s2.*) }
51 .rel.sbss2 : { *(.rel.sbss2 .rel.sbss2.* .rel.gnu.linkonce.sb2.*) }
52 .rela.sbss2 : { *(.rela.sbss2 .rela.sbss2.* .rela.gnu.linkonce.sb2.*) }
53 .rel.bss : { *(.rel.bss .rel.bss.* .rel.gnu.linkonce.b.*) }
54 .rela.bss : { *(.rela.bss .rela.bss.* .rela.gnu.linkonce.b.*) }
57 PROVIDE_HIDDEN (__rel_iplt_start = .);
59 PROVIDE_HIDDEN (__rel_iplt_end = .);
63 PROVIDE_HIDDEN (__rela_iplt_start = .);
65 PROVIDE_HIDDEN (__rela_iplt_end = .);
84 *(.text.unlikely .text.*_unlikely)
85 *(.text .stub .text.* .gnu.linkonce.t.*)
86 /* .gnu.warning sections are handled specially by elf32.em. */
88 *(.mips16.fn.*) *(.mips16.call.*)
94 PROVIDE (__etext = .);
97 .rodata : { *(.rodata .rodata.* .gnu.linkonce.r.*) }
98 .rodata1 : { *(.rodata1) }
101 *(.sdata2 .sdata2.* .gnu.linkonce.s2.*)
103 .sbss2 : { *(.sbss2 .sbss2.* .gnu.linkonce.sb2.*) }
104 .eh_frame_hdr : { *(.eh_frame_hdr) }
105 .eh_frame : ONLY_IF_RO { KEEP (*(.eh_frame)) }
106 .gcc_except_table : ONLY_IF_RO { *(.gcc_except_table .gcc_except_table.*) }
107 /* Adjust the address for the data segment. We want to adjust up to
108 the same address within the page on the next page up. */
110 /* Exception handling */
111 .eh_frame : ONLY_IF_RW { KEEP (*(.eh_frame)) }
112 .gcc_except_table : ONLY_IF_RW { *(.gcc_except_table .gcc_except_table.*) }
113 /* Thread Local Storage sections */
114 .tdata : { *(.tdata .tdata.* .gnu.linkonce.td.*) }
115 .tbss : { *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon) }
118 PROVIDE_HIDDEN (__preinit_array_start = .);
119 KEEP (*(.preinit_array))
120 PROVIDE_HIDDEN (__preinit_array_end = .);
124 PROVIDE_HIDDEN (__init_array_start = .);
125 KEEP (*(SORT(.init_array.*)))
126 KEEP (*(.init_array))
127 PROVIDE_HIDDEN (__init_array_end = .);
131 PROVIDE_HIDDEN (__fini_array_start = .);
132 KEEP (*(.fini_array))
133 KEEP (*(SORT(.fini_array.*)))
134 PROVIDE_HIDDEN (__fini_array_end = .);
138 /* gcc uses crtbegin.o to find the start of
139 the constructors, so we make sure it is
140 first. Because this is a wildcard, it
141 doesn't matter if the user does not
142 actually link against crtbegin.o; the
143 linker won't look for a file to match a
144 wildcard. The wildcard also means that it
145 doesn't matter which directory crtbegin.o
147 KEEP (*crtbegin.o(.ctors))
148 KEEP (*crtbegin?.o(.ctors))
149 /* We don't want to include the .ctor section from
150 the crtend.o file until after the sorted ctors.
151 The .ctor section from the crtend file contains the
152 end of ctors marker and it must be last */
153 KEEP (*(EXCLUDE_FILE (*crtend.o *crtend?.o ) .ctors))
154 KEEP (*(SORT(.ctors.*)))
159 KEEP (*crtbegin.o(.dtors))
160 KEEP (*crtbegin?.o(.dtors))
161 KEEP (*(EXCLUDE_FILE (*crtend.o *crtend?.o ) .dtors))
162 KEEP (*(SORT(.dtors.*)))
165 .jcr : { KEEP (*(.jcr)) }
166 .data.rel.ro : { *(.data.rel.ro.local* .gnu.linkonce.d.rel.ro.local.*) *(.data.rel.ro* .gnu.linkonce.d.rel.ro.*) }
170 *(.data .data.* .gnu.linkonce.d.*)
173 .data1 : { *(.data1) }
174 .got.plt : { *(.got.plt) }
176 _gp = ALIGN(16) + 0x7ff0;
178 /* We want the small data sections together, so single-instruction offsets
179 can access them all, and initialized data all before uninitialized, so
180 we can shorten the on-disk segment size. */
183 *(.sdata .sdata.* .gnu.linkonce.s.*)
187 .srdata : { *(.srdata) }
188 _edata = .; PROVIDE (edata = .);
194 *(.sbss .sbss.* .gnu.linkonce.sb.*)
200 *(.bss .bss.* .gnu.linkonce.b.*)
202 /* Align here to ensure that the .bss section occupies space up to
203 _end. Align after .bss to ensure correct alignment even if the
204 .bss section disappears because there are no input sections.
205 FIXME: Why do we need it? When there is no .bss section, we don't
206 pad the .data section. */
207 . = ALIGN(. != 0 ? 32 / 8 : 1);
211 _end = .; PROVIDE (end = .);
212 /* Stabs debugging sections. */
213 .stab 0 : { *(.stab) }
214 .stabstr 0 : { *(.stabstr) }
215 .stab.excl 0 : { *(.stab.excl) }
216 .stab.exclstr 0 : { *(.stab.exclstr) }
217 .stab.index 0 : { *(.stab.index) }
218 .stab.indexstr 0 : { *(.stab.indexstr) }
219 .comment 0 : { *(.comment) }
220 /* DWARF debug sections.
221 Symbols in the DWARF debugging sections are relative to the beginning
222 of the section so we begin them at 0. */
224 .debug 0 : { *(.debug) }
225 .line 0 : { *(.line) }
226 /* GNU DWARF 1 extensions */
227 .debug_srcinfo 0 : { *(.debug_srcinfo) }
228 .debug_sfnames 0 : { *(.debug_sfnames) }
229 /* DWARF 1.1 and DWARF 2 */
230 .debug_aranges 0 : { *(.debug_aranges) }
231 .debug_pubnames 0 : { *(.debug_pubnames) }
233 .debug_info 0 : { *(.debug_info .gnu.linkonce.wi.*) }
234 .debug_abbrev 0 : { *(.debug_abbrev) }
235 .debug_line 0 : { *(.debug_line) }
236 .debug_frame 0 : { *(.debug_frame) }
237 .debug_str 0 : { *(.debug_str) }
238 .debug_loc 0 : { *(.debug_loc) }
239 .debug_macinfo 0 : { *(.debug_macinfo) }
240 /* SGI/MIPS DWARF 2 extensions */
241 .debug_weaknames 0 : { *(.debug_weaknames) }
242 .debug_funcnames 0 : { *(.debug_funcnames) }
243 .debug_typenames 0 : { *(.debug_typenames) }
244 .debug_varnames 0 : { *(.debug_varnames) }
246 .debug_pubtypes 0 : { *(.debug_pubtypes) }
247 .debug_ranges 0 : { *(.debug_ranges) }
248 .gnu.attributes 0 : { KEEP (*(.gnu.attributes)) }
249 .gptab.sdata : { *(.gptab.data) *(.gptab.sdata) }
250 .gptab.sbss : { *(.gptab.bss) *(.gptab.sbss) }
251 /DISCARD/ : { *(.note.GNU-stack) *(.gnu_debuglink) *(.gnu.lto_*) }