source: rtems/c/src/lib/libbsp/m68k/dmv152/startup/linkcmds @ 85c92574

4.104.114.84.95
Last change on this file since 85c92574 was 85c92574, checked in by Joel Sherrill <joel.sherrill@…>, on 05/09/02 at 21:37:30

2001-05-09 Joel Sherrill <joel@…>

  • startup/linkcmds: In support of gcc 3.1, added one of more of the sections .jcr, .rodata*, .data.*, .gnu.linkonce.s2.*, .gnu.linkonce.sb2.*, and .gnu.linkonce.s.*. Spacing corrections and direction of segments to memory regions may also have been addressed. This was a sweep across all BSPs.
  • Property mode set to 100644
File size: 4.5 KB
Line 
1/*
2 *  This file contains directives for the GNU linker which are specific
3 *  to the DY-4 DMV152/SVME153 boards.
4 *
5 *  COPYRIGHT (c) 1989-1999.
6 *  On-Line Applications Research Corporation (OAR).
7 *
8 *  The license and distribution terms for this file may be
9 *  found in the file LICENSE in this distribution or at
10 *  http://www.OARcorp.com/rtems/license.html.
11 *
12 *  $Id$
13 */
14
15/*
16 * Declare some sizes.
17 */
18_RamBase = DEFINED(_RamBase) ? _RamBase : 0x0;
19_RamSize = DEFINED(_RamSize) ? _RamSize : 1M;
20_HeapSize = DEFINED(_HeapSize) ? _HeapSize : 0x10000;
21_StackSize = DEFINED(_StackSize) ? _StackSize : 0x1000;
22
23MEMORY
24{
25        ram : org = 0x0, l = 1M
26}
27
28SECTIONS
29{
30        ram : {
31                . = 0x12800;
32        } >ram
33
34        /*
35         * Text, data and bss segments
36         */
37        .text : {
38                *(.text)
39
40                /*
41                 * C++ constructors/destructors
42                 */
43                *(.gnu.linkonce.t.*)
44
45                /*
46                 * Initialization and finalization code.
47                 *
48                 * Various files can provide initialization and finalization
49                 * functions.  crtbegin.o and crtend.o are two instances. The
50                 * body of these functions are in .init and .fini sections. We
51                 * accumulate the bodies here, and prepend function prologues
52                 * from crti.o and function epilogues from crtn.o. crti.o must
53                 * be linked first; crtn.o must be linked last.  Because these
54                 * are wildcards, it doesn't matter if the user does not
55                 * actually link against crti.o and crtn.o; the linker won't
56                 * look for a file to match a wildcard.  The wildcard also
57                 * means that it doesn't matter which directory crti.o and
58                 * crtn.o are in.
59                 */
60                PROVIDE (_init = .);
61                *crti.o(.init)
62                *(.init)
63                *crtn.o(.init)
64                PROVIDE (_fini = .);
65                *crti.o(.fini)
66                *(.fini)
67                *crtn.o(.fini)
68
69                /*
70                 * C++ constructors/destructors
71                 *
72                 * gcc uses crtbegin.o to find the start of the constructors
73                 * and destructors so we make sure it is first.  Because this
74                 * is a wildcard, it doesn't matter if the user does not
75                 * actually link against crtbegin.o; the linker won't look for
76                 * a file to match a wildcard.  The wildcard also means that
77                 * it doesn't matter which directory crtbegin.o is in. The
78                 * constructor and destructor list are terminated in
79                 * crtend.o.  The same comments apply to it.
80                 */
81                . = ALIGN (16);
82                *crtbegin.o(.ctors)
83                *(.ctors)
84                *crtend.o(.ctors)
85                *crtbegin.o(.dtors)
86                *(.dtors)
87                *crtend.o(.dtors)
88
89                /*
90                 * Exception frame info
91                 */
92                . = ALIGN (16);
93                *(.eh_frame)
94
95                /*
96                 * Read-only data
97                 */
98                . = ALIGN (16);
99                _rodata_start = . ;
100                *(.rodata*)
101                *(.gnu.linkonce.r*)
102
103                 . = ALIGN (16);
104                PROVIDE (etext = .);
105        } >ram
106        .data : {
107                copy_start = .;
108                *(.data)
109                *(.gnu.linkonce.d*)
110                *(.gcc_except_table)
111                *(.jcr)
112                . = ALIGN (16);
113                PROVIDE (_edata = .);
114                copy_end = .;
115        } >ram
116        .bss : {
117                _clear_start = .;
118                *(.bss)
119                *(COMMON)
120                . = ALIGN (16);
121                PROVIDE (end = .);
122
123                . += _StackSize;
124                . = ALIGN (16);
125                _stack_init = .;
126                _clear_end = .;
127
128                _WorkspaceBase = .;
129        } >ram
130
131  /* Stabs debugging sections.  */
132  .stab 0 : { *(.stab) }
133  .stabstr 0 : { *(.stabstr) }
134  .stab.excl 0 : { *(.stab.excl) }
135  .stab.exclstr 0 : { *(.stab.exclstr) }
136  .stab.index 0 : { *(.stab.index) }
137  .stab.indexstr 0 : { *(.stab.indexstr) }
138  .comment 0 : { *(.comment) }
139
140  /* DWARF debug sections.
141     Symbols in the DWARF debugging sections are relative to the beginning
142     of the section so we begin them at 0.  */
143  /* DWARF 1 */
144  .debug          0 : { *(.debug) }
145  .line           0 : { *(.line) }
146 
147  /* GNU DWARF 1 extensions */
148  .debug_srcinfo  0 : { *(.debug_srcinfo) }
149  .debug_sfnames  0 : { *(.debug_sfnames) }
150 
151  /* DWARF 1.1 and DWARF 2 */
152  .debug_aranges  0 : { *(.debug_aranges) }
153  .debug_pubnames 0 : { *(.debug_pubnames) }
154 
155  /* DWARF 2 */
156  .debug_info     0 : { *(.debug_info) }
157  .debug_abbrev   0 : { *(.debug_abbrev) }
158  .debug_line     0 : { *(.debug_line) }
159  .debug_frame    0 : { *(.debug_frame) }
160  .debug_str      0 : { *(.debug_str) }
161  .debug_loc      0 : { *(.debug_loc) }
162  .debug_macinfo  0 : { *(.debug_macinfo) }
163 
164  /* SGI/MIPS DWARF 2 extensions */
165  .debug_weaknames 0 : { *(.debug_weaknames) }
166  .debug_funcnames 0 : { *(.debug_funcnames) }
167  .debug_typenames 0 : { *(.debug_typenames) }
168  .debug_varnames  0 : { *(.debug_varnames) }
169  /* These must appear regardless of  .  */
170}
Note: See TracBrowser for help on using the repository browser.