[ba46ffa6] | 1 | OUTPUT_FORMAT("elf32-powerpc", "elf32-powerpc", |
---|
| 2 | "elf32-powerpc") |
---|
| 3 | OUTPUT_ARCH(powerpc) |
---|
| 4 | ENTRY(_start) |
---|
| 5 | /* Do we need any of these for elf? |
---|
| 6 | __DYNAMIC = 0; */ |
---|
| 7 | PROVIDE (__stack = 0); |
---|
| 8 | MEMORY { |
---|
| 9 | VECTORS : ORIGIN = 0x0 , LENGTH = 0x3000 |
---|
| 10 | CODE : ORIGIN = 0x3000 , LENGTH = 0x100000 |
---|
| 11 | } |
---|
| 12 | SECTIONS |
---|
| 13 | { |
---|
| 14 | .entry_point_section : |
---|
| 15 | { |
---|
| 16 | *(.entry_point_section) |
---|
| 17 | } > VECTORS |
---|
| 18 | |
---|
| 19 | /* |
---|
| 20 | * This section is used only if NO_DYNAMIC_EXCEPTION_VECTOR_INSTALL |
---|
| 21 | * is defined in vectors/vectors.S |
---|
| 22 | */ |
---|
| 23 | .vectors : |
---|
| 24 | { |
---|
| 25 | *(.vectors) |
---|
| 26 | } > VECTORS |
---|
| 27 | |
---|
| 28 | /* Read-only sections, merged into text segment: */ |
---|
| 29 | .interp : { *(.interp) } > CODE |
---|
| 30 | .hash : { *(.hash) } > CODE |
---|
| 31 | .dynsym : { *(.dynsym) } > CODE |
---|
| 32 | .dynstr : { *(.dynstr) } > CODE |
---|
| 33 | .gnu.version : { *(.gnu.version) } > CODE |
---|
| 34 | .gnu.version_d : { *(.gnu.version_d) } > CODE |
---|
| 35 | .gnu.version_r : { *(.gnu.version_r) } > CODE |
---|
| 36 | .rela.text : |
---|
| 37 | { *(.rela.text) *(.rela.gnu.linkonce.t*) } > CODE |
---|
| 38 | .rela.data : |
---|
| 39 | { *(.rela.data) *(.rela.gnu.linkonce.d*) } > CODE |
---|
| 40 | .rela.rodata : |
---|
| 41 | { *(.rela.rodata) *(.rela.gnu.linkonce.r*) } > CODE |
---|
| 42 | .rela.got : { *(.rela.got) } > CODE |
---|
| 43 | .rela.got1 : { *(.rela.got1) } > CODE |
---|
| 44 | .rela.got2 : { *(.rela.got2) } > CODE |
---|
| 45 | .rela.ctors : { *(.rela.ctors) } > CODE |
---|
| 46 | .rela.dtors : { *(.rela.dtors) } > CODE |
---|
| 47 | .rela.init : { *(.rela.init) } > CODE |
---|
| 48 | .rela.fini : { *(.rela.fini) } > CODE |
---|
| 49 | .rela.bss : { *(.rela.bss) } > CODE |
---|
| 50 | .rela.plt : { *(.rela.plt) } > CODE |
---|
| 51 | .rela.sdata : { *(.rela.sdata) } > CODE |
---|
| 52 | .rela.sbss : { *(.rela.sbss) } > CODE |
---|
| 53 | .rela.sdata2 : { *(.rela.sdata2) } > CODE |
---|
| 54 | .rela.sbss2 : { *(.rela.sbss2) } > CODE |
---|
| 55 | .text : |
---|
| 56 | { |
---|
| 57 | *(.text) |
---|
| 58 | /* .gnu.warning sections are handled specially by elf32.em. */ |
---|
| 59 | *(.gnu.warning) |
---|
| 60 | *(.gnu.linkonce.t*) |
---|
| 61 | } > CODE |
---|
| 62 | .init : { *(.init) } > CODE |
---|
| 63 | .fini : { *(.fini) } > CODE |
---|
| 64 | .rodata : { *(.rodata) *(.gnu.linkonce.r*) } > CODE |
---|
| 65 | .rodata1 : { *(.rodata1) } > CODE |
---|
| 66 | _etext = .; |
---|
| 67 | PROVIDE (etext = .); |
---|
| 68 | .sdata2 : { *(.sdata2) } > CODE |
---|
| 69 | .sbss2 : { *(.sbss2) } > CODE |
---|
| 70 | /* Adjust the address for the data segment. We want to adjust up to |
---|
| 71 | the same address within the page on the next page up. It would |
---|
| 72 | be more correct to do this: |
---|
| 73 | . = ALIGN(0x40000) + (ALIGN(8) & (0x40000 - 1)); |
---|
| 74 | The current expression does not correctly handle the case of a |
---|
| 75 | text segment ending precisely at the end of a page; it causes the |
---|
| 76 | data segment to skip a page. The above expression does not have |
---|
| 77 | this problem, but it will currently (2/95) cause BFD to allocate |
---|
| 78 | a single segment, combining both text and data, for this case. |
---|
| 79 | This will prevent the text segment from being shared among |
---|
| 80 | multiple executions of the program; I think that is more |
---|
| 81 | important than losing a page of the virtual address space (note |
---|
| 82 | that no actual memory is lost; the page which is skipped can not |
---|
| 83 | be referenced). */ |
---|
| 84 | . = ALIGN(0x1000); |
---|
| 85 | .data : |
---|
| 86 | { |
---|
| 87 | *(.data) |
---|
| 88 | *(.gnu.linkonce.d*) |
---|
| 89 | CONSTRUCTORS |
---|
| 90 | } > CODE |
---|
| 91 | .data1 : { *(.data1) } > CODE |
---|
| 92 | PROVIDE (__EXCEPT_START__ = .); |
---|
| 93 | .gcc_except_table : { *(.gcc_except_table) } > CODE |
---|
| 94 | PROVIDE (__EXCEPT_END__ = .); |
---|
| 95 | .got1 : { *(.got1) } > CODE |
---|
| 96 | .dynamic : { *(.dynamic) } > CODE |
---|
| 97 | /* Put .ctors and .dtors next to the .got2 section, so that the pointers |
---|
| 98 | get relocated with -mrelocatable. Also put in the .fixup pointers. |
---|
| 99 | The current compiler no longer needs this, but keep it around for 2.7.2 */ |
---|
| 100 | PROVIDE (_GOT2_START_ = .); |
---|
| 101 | .got2 : { *(.got2) } > CODE |
---|
| 102 | PROVIDE (__CTOR_LIST__ = .); |
---|
| 103 | .ctors : { *(.ctors) } > CODE |
---|
| 104 | PROVIDE (__CTOR_END__ = .); |
---|
| 105 | PROVIDE (__DTOR_LIST__ = .); |
---|
| 106 | .dtors : { *(.dtors) } > CODE |
---|
| 107 | PROVIDE (__DTOR_END__ = .); |
---|
| 108 | PROVIDE (_FIXUP_START_ = .); |
---|
| 109 | .fixup : { *(.fixup) } > CODE |
---|
| 110 | PROVIDE (_FIXUP_END_ = .); |
---|
| 111 | PROVIDE (_GOT2_END_ = .); |
---|
| 112 | PROVIDE (_GOT_START_ = .); |
---|
| 113 | .got : { *(.got) } > CODE |
---|
| 114 | .got.plt : { *(.got.plt) } > CODE |
---|
| 115 | PROVIDE (_GOT_END_ = .); |
---|
| 116 | /* We want the small data sections together, so single-instruction offsets |
---|
| 117 | can access them all, and initialized data all before uninitialized, so |
---|
| 118 | we can shorten the on-disk segment size. */ |
---|
| 119 | .sdata : { *(.sdata) } > CODE |
---|
| 120 | _edata = .; |
---|
| 121 | PROVIDE (edata = .); |
---|
| 122 | .sbss : |
---|
| 123 | { |
---|
| 124 | PROVIDE (__sbss_start = .); |
---|
| 125 | *(.sbss) |
---|
| 126 | *(.scommon) |
---|
| 127 | *(.dynsbss) |
---|
| 128 | PROVIDE (__sbss_end = .); |
---|
| 129 | } > CODE |
---|
| 130 | .plt : { *(.plt) } > CODE |
---|
| 131 | .bss : |
---|
| 132 | { |
---|
| 133 | PROVIDE (__bss_start = .); |
---|
| 134 | *(.dynbss) |
---|
| 135 | *(.bss) |
---|
| 136 | *(COMMON) |
---|
| 137 | . = ALIGN(16); |
---|
| 138 | } > CODE |
---|
| 139 | . = ALIGN(16); |
---|
| 140 | _end = . ; |
---|
| 141 | __rtems_end = . ; |
---|
| 142 | PROVIDE (end = .); |
---|
| 143 | /DISCARD/ : |
---|
| 144 | { |
---|
| 145 | *(.comment) |
---|
| 146 | } |
---|
[4cb5d29] | 147 | |
---|
| 148 | |
---|
| 149 | /* Stabs debugging sections. */ |
---|
| 150 | .stab 0 : { *(.stab) } |
---|
| 151 | .stabstr 0 : { *(.stabstr) } |
---|
| 152 | .stab.excl 0 : { *(.stab.excl) } |
---|
| 153 | .stab.exclstr 0 : { *(.stab.exclstr) } |
---|
| 154 | .stab.index 0 : { *(.stab.index) } |
---|
| 155 | .stab.indexstr 0 : { *(.stab.indexstr) } |
---|
| 156 | .comment 0 : { *(.comment) } |
---|
| 157 | |
---|
| 158 | /* DWARF debug sections. |
---|
| 159 | Symbols in the DWARF debugging sections are relative to the beginning |
---|
| 160 | of the section so we begin them at 0. */ |
---|
| 161 | /* DWARF 1 */ |
---|
| 162 | .debug 0 : { *(.debug) } |
---|
| 163 | .line 0 : { *(.line) } |
---|
| 164 | |
---|
| 165 | /* GNU DWARF 1 extensions */ |
---|
| 166 | .debug_srcinfo 0 : { *(.debug_srcinfo) } |
---|
| 167 | .debug_sfnames 0 : { *(.debug_sfnames) } |
---|
| 168 | |
---|
| 169 | /* DWARF 1.1 and DWARF 2 */ |
---|
| 170 | .debug_aranges 0 : { *(.debug_aranges) } |
---|
| 171 | .debug_pubnames 0 : { *(.debug_pubnames) } |
---|
| 172 | |
---|
| 173 | /* DWARF 2 */ |
---|
| 174 | .debug_info 0 : { *(.debug_info) } |
---|
| 175 | .debug_abbrev 0 : { *(.debug_abbrev) } |
---|
| 176 | .debug_line 0 : { *(.debug_line) } |
---|
| 177 | .debug_frame 0 : { *(.debug_frame) } |
---|
| 178 | .debug_str 0 : { *(.debug_str) } |
---|
| 179 | .debug_loc 0 : { *(.debug_loc) } |
---|
| 180 | .debug_macinfo 0 : { *(.debug_macinfo) } |
---|
| 181 | |
---|
| 182 | /* SGI/MIPS DWARF 2 extensions */ |
---|
| 183 | .debug_weaknames 0 : { *(.debug_weaknames) } |
---|
| 184 | .debug_funcnames 0 : { *(.debug_funcnames) } |
---|
| 185 | .debug_typenames 0 : { *(.debug_typenames) } |
---|
| 186 | .debug_varnames 0 : { *(.debug_varnames) } |
---|
| 187 | /* These must appear regardless of . */ |
---|
[ba46ffa6] | 188 | } |
---|