source: rtems/c/src/lib/libbsp/powerpc/eth_comm/startup/linkcmds @ 4cb5d29

4.104.114.84.95
Last change on this file since 4cb5d29 was 4cb5d29, checked in by Joel Sherrill <joel.sherrill@…>, on 09/29/00 at 13:33:23

2000-09-29 Charles-Antoine Gauthier <charles.gauthier@…>

  • startup/linkcmds: Added lines so DWARF debug information would be available. Otherwise gdb complains that the offsets for the debug info are incorrect and doesn't load the files.
  • Property mode set to 100644
File size: 4.0 KB
Line 
1/*
2 *  This file contains directives for the GNU linker which are specific
3 *  to the Ethernet-Comm Board
4 *
5 *  $Id$
6 */
7
8OUTPUT_FORMAT("elf32-powerpc", "elf32-powerpc",
9              "elf32-powerpc")
10OUTPUT_ARCH(powerpc)
11 SEARCH_DIR(/usr/local/powerpc-rtems/lib);
12 
13ENTRY(start)
14 
15MEMORY
16        {
17        ram : org = 0x0, l = 4M
18        dpram : org = 0xff000000, l = 16K
19        canbus : org = 0xff100000, l = 12K
20        flash : org = 0xfff00000, l = 512K
21        }
22
23
24SECTIONS
25{
26        .vectors :
27        {
28          *(.vectors)
29        } >ram
30
31        /*
32         * The stack will live in this area - between the vectors and
33         * the text section.
34         */
35       
36        .text 0x10000:
37        {
38             text.start = .;
39             *(.entry)
40             *(.entry2)
41             *(.text)
42             *(.rodata)
43             *(.gnu.linkonce.r*)
44             *(.rodata1)
45             *(.gnu.linkonce.t.*)
46             *(.descriptors)
47             /* .gnu.warning sections are handled specially by elf32.em.  */
48             *(.gnu.warning)
49             *(rom_ver)
50             etext = ALIGN(0x10);
51             _etext = .;
52       
53             __CTOR_LIST__ = .;
54             LONG((__CTOR_END__ - __CTOR_LIST__) / 4 - 2)
55             *(.ctors)
56             LONG(0)
57             __CTOR_END__ = .;
58       
59             __DTOR_LIST__ = .;
60             LONG((__DTOR_END__ - __DTOR_LIST__) / 4 - 2)
61             *(.dtors)
62             LONG(0)
63             __DTOR_END__ = .;
64       
65             *(.lit)
66             *(.shdata)
67             *(.init)
68             *(.fini)
69             _endtext = .;
70             text.end = .;
71        } > ram
72 
73        /* R/W Data */
74        .data :
75        {
76          *(.data)
77          *(.data1)
78          *(.gnu.linkonce.d.*)
79          PROVIDE (__SDATA_START__ = .);
80          *(.sdata)
81        } > ram
82       
83        PROVIDE (__EXCEPT_START__ = .);
84        .gcc_except_table   : { *(.gcc_except_table) } >RAM
85        PROVIDE (__EXCEPT_END__ = .);
86        __GOT_START__ = .;
87        .got :
88        {
89           s.got = .;
90           *(.got.plt) *(.got)
91        } > ram
92        __GOT_END__ = .;
93       
94        .got1             : { *(.got1)          } >ram
95        PROVIDE (__GOT2_START__ = .);
96        PROVIDE (_GOT2_START_ = .);
97        .got2             :  { *(.got2)         } >ram
98        PROVIDE (__GOT2_END__ = .);
99        PROVIDE (_GOT2_END_ = .);
100       
101        PROVIDE (__FIXUP_START__ = .);
102        PROVIDE (_FIXUP_START_ = .);
103        .fixup    : { *(.fixup)         } >ram
104        PROVIDE (_FIXUP_END_ = .);
105        PROVIDE (__FIXUP_END__ = .);
106         
107        PROVIDE (__SDATA2_START__ = .);
108        .sdata2           : { *(.sdata2)        } >ram
109        .sbss2            : { *(.sbss2)         } >ram
110        PROVIDE (__SBSS2_END__ = .);
111       
112        .sbss2            : { *(.sbss2)         } >ram
113        PROVIDE (__SBSS2_END__ = .);
114       
115        __SBSS_START__ = .;
116        .bss :
117        {
118          bss.start = .;
119          *(.bss) *(.sbss) *(COMMON)
120          . = ALIGN(4);
121          bss.end = .;
122        } > ram
123        __SBSS_END__ = .;
124
125        bss.size = bss.end - bss.start;
126        text.size = text.end - text.start;
127        PROVIDE(_end = bss.end);
128       
129        dpram :
130        {
131          m8xx = .;
132          _m8xx = .;
133          . += (8 * 1024);
134        } >dpram
135
136        canbus :
137        {
138          canbus0 = .;
139          . += (0x1000);
140          canbus1 = .;
141          . += (0x1000);
142          canbus2 = .;
143          . += (0x1000);
144        } >canbus
145
146
147  /* Stabs debugging sections.  */
148  .stab 0 : { *(.stab) }
149  .stabstr 0 : { *(.stabstr) }
150  .stab.excl 0 : { *(.stab.excl) }
151  .stab.exclstr 0 : { *(.stab.exclstr) }
152  .stab.index 0 : { *(.stab.index) }
153  .stab.indexstr 0 : { *(.stab.indexstr) }
154  .comment 0 : { *(.comment) }
155
156  /* DWARF debug sections.
157     Symbols in the DWARF debugging sections are relative to the beginning
158     of the section so we begin them at 0.  */
159  /* DWARF 1 */
160  .debug          0 : { *(.debug) }
161  .line           0 : { *(.line) }
162 
163  /* GNU DWARF 1 extensions */
164  .debug_srcinfo  0 : { *(.debug_srcinfo) }
165  .debug_sfnames  0 : { *(.debug_sfnames) }
166 
167  /* DWARF 1.1 and DWARF 2 */
168  .debug_aranges  0 : { *(.debug_aranges) }
169  .debug_pubnames 0 : { *(.debug_pubnames) }
170 
171  /* DWARF 2 */
172  .debug_info     0 : { *(.debug_info) }
173  .debug_abbrev   0 : { *(.debug_abbrev) }
174  .debug_line     0 : { *(.debug_line) }
175  .debug_frame    0 : { *(.debug_frame) }
176  .debug_str      0 : { *(.debug_str) }
177  .debug_loc      0 : { *(.debug_loc) }
178  .debug_macinfo  0 : { *(.debug_macinfo) }
179 
180  /* SGI/MIPS DWARF 2 extensions */
181  .debug_weaknames 0 : { *(.debug_weaknames) }
182  .debug_funcnames 0 : { *(.debug_funcnames) }
183  .debug_typenames 0 : { *(.debug_typenames) }
184  .debug_varnames  0 : { *(.debug_varnames) }
185  /* These must appear regardless of  .  */
186
187}
Note: See TracBrowser for help on using the repository browser.