1 /* A modified version of the basic linker script, for testing purposes,
2 which puts all code above 0x10000. */
3 OUTPUT_FORMAT("elf32-xstormy16", "elf32-xstormy16",
7 SEARCH_DIR(/es/scratch/geoffk/objs/mainline-sX/H-i686-pc-linux-gnulibc2.2/xstormy16-elf/lib);
8 /* There are two memory regions we care about, one from 0 through 0x7F00
9 that is RAM and one from 0x8000 up which is ROM. */
12 RAM (w) : ORIGIN = 0, LENGTH = 0x7F00
13 LOROM (!w) : ORIGIN = 0x8000, LENGTH = 0x8000
14 HIROM (!w) : ORIGIN = 0x10000, LENGTH = 0xFF0000
37 /* Align here to ensure that the .bss section occupies space up to
38 _end. Align after .bss to ensure correct alignment even if the
39 .bss section disappears because there are no input sections. */
46 /* Read-only sections in ROM. */
47 .int_vec : { *(.int_vec) } > LOROM
48 .rodata : { *(.rodata) *(.rodata.*) *(.gnu.linkonce.r.*) } > LOROM
51 /* gcc uses crtbegin.o to find the start of
52 the constructors, so we make sure it is
53 first. Because this is a wildcard, it
54 doesn't matter if the user does not
55 actually link against crtbegin.o; the
56 linker won't look for a file to match a
57 wildcard. The wildcard also means that it
58 doesn't matter which directory crtbegin.o
60 KEEP (*crtbegin.o(.ctors))
61 /* We don't want to include the .ctor section from
62 from the crtend.o file until after the sorted ctors.
63 The .ctor section from the crtend file contains the
64 end of ctors marker and it must be last */
65 KEEP (*(EXCLUDE_FILE (*crtend.o ) .ctors))
66 KEEP (*(SORT(.ctors.*)))
71 KEEP (*crtbegin.o(.dtors))
72 KEEP (*(EXCLUDE_FILE (*crtend.o ) .dtors))
73 KEEP (*(SORT(.dtors.*)))
76 .eh_frame : { KEEP (*(.eh_frame)) } > LOROM
77 .gcc_except_table : { *(.gcc_except_table) } > LOROM
78 .jcr : { *(.jcr) } > LOROM
79 .plt : { *(.plt) } > LOROM
85 /* .gnu.warning sections are handled specially by elf32.em. */
97 PROVIDE (__etext = .);
100 /* Stabs debugging sections. */
101 .stab 0 : { *(.stab) }
102 .stabstr 0 : { *(.stabstr) }
103 .stab.excl 0 : { *(.stab.excl) }
104 .stab.exclstr 0 : { *(.stab.exclstr) }
105 .stab.index 0 : { *(.stab.index) }
106 .stab.indexstr 0 : { *(.stab.indexstr) }
107 .comment 0 : { *(.comment) }
108 /* DWARF debug sections.
109 Symbols in the DWARF debugging sections are relative to the beginning
110 of the section so we begin them at 0. */
112 .debug 0 : { *(.debug) }
113 .line 0 : { *(.line) }
114 /* GNU DWARF 1 extensions */
115 .debug_srcinfo 0 : { *(.debug_srcinfo) }
116 .debug_sfnames 0 : { *(.debug_sfnames) }
117 /* DWARF 1.1 and DWARF 2 */
118 .debug_aranges 0 : { *(.debug_aranges) }
119 .debug_pubnames 0 : { *(.debug_pubnames) }
121 .debug_info 0 : { *(.debug_info) *(.gnu.linkonce.wi.*) }
122 .debug_abbrev 0 : { *(.debug_abbrev) }
123 .debug_line 0 : { *(.debug_line) }
124 .debug_frame 0 : { *(.debug_frame) }
125 .debug_str 0 : { *(.debug_str) }
126 .debug_loc 0 : { *(.debug_loc) }
127 .debug_macinfo 0 : { *(.debug_macinfo) }
128 /* SGI/MIPS DWARF 2 extensions */
129 .debug_weaknames 0 : { *(.debug_weaknames) }
130 .debug_funcnames 0 : { *(.debug_funcnames) }
131 .debug_typenames 0 : { *(.debug_typenames) }
132 .debug_varnames 0 : { *(.debug_varnames) }
133 /* These must appear regardless of . */