source: rtems/c/src/lib/libbsp/powerpc/papyrus/startup/linkcmds @ eba2e4f

4.104.114.84.95
Last change on this file since eba2e4f 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: 3.5 KB
Line 
1/*
2 *  This file contains directives for the GNU linker which are specific
3 *  to the Papyrus.
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(download_entry)
14 
15MEMORY
16  {
17        RAM : ORIGIN = 0, LENGTH = 4M
18        FLASH : ORIGIN = 0xFF000000, LENGTH = 0x80000
19        EPROM : ORIGIN = 0xFFFE0000, LENGTH = 0x20000
20  }
21 
22/* Do we need any of these for elf?
23   __DYNAMIC = 0;    */
24
25SECTIONS
26{
27  .vectors 0x0100 :
28  {
29    *(.vectors)
30  }
31 
32  .text 0x20000 :
33  {
34     *(.entry)
35     *(.entry2)
36     *(.text)
37     *(.rodata)
38     *(.gnu.linkonce.r*)
39     *(.rodata1)
40     *(.descriptors)
41     *(rom_ver)
42     etext = ALIGN(0x10);
43     _etext = .;
44
45     __CTOR_LIST__ = .;
46     LONG((__CTOR_END__ - __CTOR_LIST__) / 4 - 2)
47     *(.ctors)
48     LONG(0)
49     __CTOR_END__ = .;
50
51     __DTOR_LIST__ = .;
52     LONG((__DTOR_END__ - __DTOR_LIST__) / 4 - 2)
53     *(.dtors)
54     LONG(0)
55     __DTOR_END__ = .;
56
57     *(.lit)
58     *(.shdata)
59     *(.init)
60     *(.fini)
61     _endtext = .;
62  } > RAM
63 
64  /* R/W Data */
65  .data :
66  {
67    *(.data)
68    *(.data1)
69    PROVIDE (__SDATA_START__ = .);
70    *(.sdata)
71  } > RAM
72 
73  PROVIDE (__EXCEPT_START__ = .);
74  .gcc_except_table   : { *(.gcc_except_table) } >RAM
75  PROVIDE (__EXCEPT_END__ = .);
76  __GOT_START__ = .;
77  .got :
78  {
79     s.got = .;
80     *(.got.plt) *(.got)
81  } > RAM
82  __GOT_END__ = .;
83
84  .got1           : { *(.got1)          } >RAM
85  PROVIDE (__GOT2_START__ = .);
86  PROVIDE (_GOT2_START_ = .);
87  .got2           :  { *(.got2)         } >RAM
88  PROVIDE (__GOT2_END__ = .);
89  PROVIDE (_GOT2_END_ = .);
90
91  PROVIDE (__FIXUP_START__ = .);
92  PROVIDE (_FIXUP_START_ = .);
93  .fixup          : { *(.fixup)         } >RAM
94  PROVIDE (_FIXUP_END_ = .);
95  PROVIDE (__FIXUP_END__ = .);
96 
97  PROVIDE (__SDATA2_START__ = .);
98  .sdata2         : { *(.sdata2)        } >RAM
99  .sbss2          : { *(.sbss2)         } >RAM
100  PROVIDE (__SBSS2_END__ = .);
101
102  .sbss2          : { *(.sbss2)         } >RAM
103  PROVIDE (__SBSS2_END__ = .);
104
105  __SBSS_START__ = .;
106  .bss :
107  {
108    bss.start = .;
109    *(.bss) *(.sbss) *(COMMON)
110    bss.end = ALIGN(4);
111  } > RAM
112  __SBSS_END__ = .;
113 
114  bss.size = bss.end - bss.start;
115  PROVIDE(_end = bss.end);
116
117
118  /* Stabs debugging sections.  */
119  .stab 0 : { *(.stab) }
120  .stabstr 0 : { *(.stabstr) }
121  .stab.excl 0 : { *(.stab.excl) }
122  .stab.exclstr 0 : { *(.stab.exclstr) }
123  .stab.index 0 : { *(.stab.index) }
124  .stab.indexstr 0 : { *(.stab.indexstr) }
125  .comment 0 : { *(.comment) }
126
127  /* DWARF debug sections.
128     Symbols in the DWARF debugging sections are relative to the beginning
129     of the section so we begin them at 0.  */
130  /* DWARF 1 */
131  .debug          0 : { *(.debug) }
132  .line           0 : { *(.line) }
133 
134  /* GNU DWARF 1 extensions */
135  .debug_srcinfo  0 : { *(.debug_srcinfo) }
136  .debug_sfnames  0 : { *(.debug_sfnames) }
137 
138  /* DWARF 1.1 and DWARF 2 */
139  .debug_aranges  0 : { *(.debug_aranges) }
140  .debug_pubnames 0 : { *(.debug_pubnames) }
141 
142  /* DWARF 2 */
143  .debug_info     0 : { *(.debug_info) }
144  .debug_abbrev   0 : { *(.debug_abbrev) }
145  .debug_line     0 : { *(.debug_line) }
146  .debug_frame    0 : { *(.debug_frame) }
147  .debug_str      0 : { *(.debug_str) }
148  .debug_loc      0 : { *(.debug_loc) }
149  .debug_macinfo  0 : { *(.debug_macinfo) }
150 
151  /* SGI/MIPS DWARF 2 extensions */
152  .debug_weaknames 0 : { *(.debug_weaknames) }
153  .debug_funcnames 0 : { *(.debug_funcnames) }
154  .debug_typenames 0 : { *(.debug_typenames) }
155  .debug_varnames  0 : { *(.debug_varnames) }
156  /* These must appear regardless of  .  */
157}
158
159
Note: See TracBrowser for help on using the repository browser.