source: rtems/c/src/lib/libbsp/m68k/mvme162/startup/linkcmds @ e4c07444

4.104.114.84.95
Last change on this file since e4c07444 was b8c9883, checked in by Joel Sherrill <joel.sherrill@…>, on Jan 13, 2000 at 8:45:07 PM

All m68k BSPs now build with new ELF style linkcmds.

  • Property mode set to 100644
File size: 3.4 KB
Line 
1/*
2 *  This file contains directives for the GNU linker which are specific
3 *  to the Motorola MVME162 board.
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 *  Modifications of respective RTEMS file: COPYRIGHT (c) 1994.
13 *  EISCAT Scientific Association. M.Savitski
14 *
15 *  This material is a part of the MVME162 Board Support Package
16 *  for the RTEMS executive. Its licensing policies are those of the
17 *  RTEMS above.
18 *
19 *  $Id$
20 */
21
22/*
23 * Declare some sizes.
24 */
25_RamBase = 0x100000;
26_RamSize = DEFINED(_RamSize) ? _RamSize : 1M;
27_HeapSize = DEFINED(_HeapSize) ? _HeapSize : 0x10000;
28_StackSize = DEFINED(_StackSize) ? _StackSize : 0x1000;
29
30MEMORY
31{
32        ram : org = 0x100000, l = 1M
33}
34
35SECTIONS
36{
37        ram : {
38                . = .;
39        } >ram
40
41        /*
42         * Text, data and bss segments
43         */
44        .text : {
45                *(.text)
46
47                /*
48                 * C++ constructors/destructors
49                 */
50                *(.gnu.linkonce.t.*)
51
52                /*
53                 * Initialization and finalization code.
54                 *
55                 * Various files can provide initialization and finalization
56                 * functions.  crtbegin.o and crtend.o are two instances. The
57                 * body of these functions are in .init and .fini sections. We
58                 * accumulate the bodies here, and prepend function prologues
59                 * from crti.o and function epilogues from crtn.o. crti.o must
60                 * be linked first; crtn.o must be linked last.  Because these
61                 * are wildcards, it doesn't matter if the user does not
62                 * actually link against crti.o and crtn.o; the linker won't
63                 * look for a file to match a wildcard.  The wildcard also
64                 * means that it doesn't matter which directory crti.o and
65                 * crtn.o are in.
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                 * C++ constructors/destructors
78                 *
79                 * gcc uses crtbegin.o to find the start of the constructors
80                 * and destructors so we make sure it is first.  Because this
81                 * is a wildcard, it doesn't matter if the user does not
82                 * actually link against crtbegin.o; the linker won't look for
83                 * a file to match a wildcard.  The wildcard also means that
84                 * it doesn't matter which directory crtbegin.o is in. The
85                 * constructor and destructor list are terminated in
86                 * crtend.o.  The same comments apply to it.
87                 */
88                . = ALIGN (16);
89                *crtbegin.o(.ctors)
90                *(.ctors)
91                *crtend.o(.ctors)
92                *crtbegin.o(.dtors)
93                *(.dtors)
94                *crtend.o(.dtors)
95
96                /*
97                 * Exception frame info
98                 */
99                . = ALIGN (16);
100                *(.eh_frame)
101
102                /*
103                 * Read-only data
104                 */
105                . = ALIGN (16);
106                _rodata_start = . ;
107                *(.rodata)
108                *(.gnu.linkonce.r*)
109
110                 . = ALIGN (16);
111                PROVIDE (_etext = .);
112        } >ram
113        .data : {
114                PROVIDE (_copy_start = .);
115                *(.data)
116                *(.gnu.linkonce.d*)
117                *(.gcc_except_table)
118                . = ALIGN (16);
119                PROVIDE (_edata = .);
120                PROVIDE (_copy_end = .);
121        } >ram
122        .bss : {
123                _clear_start = .;
124                *(.bss)
125                *(COMMON)
126                . = ALIGN (16);
127                PROVIDE (end = .);
128
129                . += _StackSize;
130                . = ALIGN (16);
131                _stack_init = .;
132                _clear_end = .;
133
134                _WorkspaceBase = .;
135        } >ram
136}
Note: See TracBrowser for help on using the repository browser.