source: rtems/c/src/lib/libbsp/m68k/mvme136/startup/linkcmds @ c499856

4.115
Last change on this file since c499856 was c499856, checked in by Chris Johns <chrisj@…>, on 03/20/14 at 21:10:47

Change all references of rtems.com to rtems.org.

  • Property mode set to 100644
File size: 5.1 KB
Line 
1/*
2 *  This file contains directives for the GNU linker which are specific
3 *  to the Motorola MVME136/MVME135 boards.
4 *
5 *  COPYRIGHT (c) 1989-2007.
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.rtems.org/license/LICENSE.
11 */
12
13/*
14 * Declare some sizes.
15 */
16RamBase = DEFINED(RamBase) ? RamBase : 0x0;
17RamSize = DEFINED(RamSize) ? RamSize : 1M;
18HeapSize = DEFINED(HeapSize) ? HeapSize : 0x0;
19_StackSize = DEFINED(_StackSize) ? _StackSize : 0x1000;
20
21MEMORY
22{
23        ram : org = 0x0, l = 1M
24}
25
26SECTIONS
27{
28        ram : {
29                . = 0x3000;
30        } >ram
31
32        /*
33         * Text, data and bss segments
34         */
35        .text : {
36                *(.text*)
37
38                /*
39                 * C++ constructors/destructors
40                 *
41                 * Various files can provide initialization and finalization
42                 * functions.  crtbegin.o and crtend.o are two instances. The
43                 * body of these functions are in .init and .fini sections. We
44                 * accumulate the bodies here, and prepend function prologues
45                 * from crti.o and function epilogues from crtn.o. crti.o must
46                 * be linked first; crtn.o must be linked last.  Because these
47                 * are wildcards, it doesn't matter if the user does not
48                 * actually link against crti.o and crtn.o; the linker won't
49                 * look for a file to match a wildcard.  The wildcard also
50                 * means that it doesn't matter which directory crti.o and
51                 * crtn.o are in.
52                 */
53                *(.gnu.linkonce.t.*)
54
55                /*
56                 * Initialization and finalization code.
57                 *
58                 * gcc uses crtbegin.o to find the start of the constructors
59                 * and destructors so we make sure it is first.  Because this
60                 * is a wildcard, it doesn't matter if the user does not
61                 * actually link against crtbegin.o; the linker won't look for
62                 * a file to match a wildcard.  The wildcard also means that
63                 * it doesn't matter which directory crtbegin.o is in. The
64                 * constructor and destructor list are terminated in
65                 * crtend.o.  The same comments apply to it.
66                 */
67                PROVIDE (_init = .);
68                *crti.o(.init)
69                *(.init)
70                *crtn.o(.init)
71                PROVIDE (_fini = .);
72                *crti.o(.fini)
73                *(.fini)
74                *crtn.o(.fini)
75
76                /*
77                 * Special FreeBSD sysctl sections.
78                 */
79                . = ALIGN (16);
80                __start_set_sysctl_set = .;
81                *(set_sysctl_*);
82                __stop_set_sysctl_set = ABSOLUTE(.);
83                *(set_domain_*);
84                *(set_pseudo_*);
85
86                /*
87                 * C++ constructors/destructors
88                 */
89                . = ALIGN (16);
90                *crtbegin.o(.ctors)
91                *(.ctors)
92                *crtend.o(.ctors)
93                *crtbegin.o(.dtors)
94                *(.dtors)
95                *crtend.o(.dtors)
96
97                /*
98                 * Exception frame info
99                 */
100                . = ALIGN (16);
101                *(.eh_frame)
102
103                /*
104                 * Read-only data
105                 */
106                . = ALIGN (16);
107                _rodata_start = .;
108                *(.rodata*)
109                *(.gnu.linkonce.r*)
110
111                 . = ALIGN (16);
112                PROVIDE (_etext = .);
113        } >ram
114
115        .tdata : {
116                _TLS_Data_begin = .;
117                *(.tdata .tdata.* .gnu.linkonce.td.*)
118                _TLS_Data_end = .;
119        } >ram
120
121        .tbss : {
122                _TLS_BSS_begin = .;
123                *(.tbss .tbss.* .gnu.linkonce.tb.*) *(.tcommon)
124                _TLS_BSS_end = .;
125        } >ram
126
127        _TLS_Data_size = _TLS_Data_end - _TLS_Data_begin;
128        _TLS_BSS_size = _TLS_BSS_end - _TLS_BSS_begin;
129        _TLS_Size = _TLS_BSS_end - _TLS_Data_begin;
130        _TLS_Alignment = ALIGNOF (.tdata);
131
132        .data : {
133                PROVIDE (_copy_start = .);
134                *(.data*)
135                *(.gnu.linkonce.d*)
136                *(.gcc_except_table*)
137                *(.jcr)
138                . = ALIGN (16);
139                PROVIDE (_edata = .);
140                PROVIDE (_copy_end = .);
141        } >ram
142        .bss : {
143                _clear_start = .;
144                *(.dynbss)
145                *(.bss* .gnu.linkonce.b.*)
146                *(COMMON)
147                . = ALIGN (16);
148                PROVIDE (end = .);
149
150                . += _StackSize;
151                . = ALIGN (16);
152                _stack_init = .;
153                _clear_end = .;
154
155                WorkAreaBase = .;
156        } >ram
157
158  /* Stabs debugging sections.  */
159  .stab 0 : { *(.stab) }
160  .stabstr 0 : { *(.stabstr) }
161  .stab.excl 0 : { *(.stab.excl) }
162  .stab.exclstr 0 : { *(.stab.exclstr) }
163  .stab.index 0 : { *(.stab.index) }
164  .stab.indexstr 0 : { *(.stab.indexstr) }
165  .comment 0 : { *(.comment) }
166
167  /* DWARF debug sections.
168     Symbols in the DWARF debugging sections are relative to the beginning
169     of the section so we begin them at 0.  */
170  /* DWARF 1 */
171  .debug          0 : { *(.debug) }
172  .line           0 : { *(.line) }
173 
174  /* GNU DWARF 1 extensions */
175  .debug_srcinfo  0 : { *(.debug_srcinfo) }
176  .debug_sfnames  0 : { *(.debug_sfnames) }
177 
178  /* DWARF 1.1 and DWARF 2 */
179  .debug_aranges  0 : { *(.debug_aranges) }
180  .debug_pubnames 0 : { *(.debug_pubnames) }
181 
182  /* DWARF 2 */
183  .debug_info     0 : { *(.debug_info) }
184  .debug_abbrev   0 : { *(.debug_abbrev) }
185  .debug_line     0 : { *(.debug_line) }
186  .debug_frame    0 : { *(.debug_frame) }
187  .debug_str      0 : { *(.debug_str) }
188  .debug_loc      0 : { *(.debug_loc) }
189  .debug_macinfo  0 : { *(.debug_macinfo) }
190 
191  /* SGI/MIPS DWARF 2 extensions */
192  .debug_weaknames 0 : { *(.debug_weaknames) }
193  .debug_funcnames 0 : { *(.debug_funcnames) }
194  .debug_typenames 0 : { *(.debug_typenames) }
195  .debug_varnames  0 : { *(.debug_varnames) }
196  /* These must appear regardless of  .  */
197}
Note: See TracBrowser for help on using the repository browser.