xref: /netbsd-src/external/gpl3/binutils/dist/ld/scripttempl/alphavms.sc (revision 6d322f2f4598f0d8a138f10ea648ec4fabe41f8b)
1# Linker script for Alpha VMS systems.
2# Tristan Gingold <gingold@adacore.com>.
3
4PAGESIZE=0x10000
5
6cat <<EOF
7OUTPUT_FORMAT("${OUTPUT_FORMAT}")
8${LIB_SEARCH_DIRS}
9
10SECTIONS
11{
12  ${RELOCATING+. = ${PAGESIZE};}
13
14  /* RW initialized data.  */
15  \$DATA\$ ALIGN (${PAGESIZE}) : {
16    *(\$DATA\$)
17  }
18  /* RW data unmodified (zero-initialized).  */
19  \$BSS\$ ALIGN (${PAGESIZE}) : {
20    *(\$BSS\$)
21  }
22  /* RO, executable code.  */
23  \$CODE\$ ALIGN (${PAGESIZE}) : {
24    *(\$CODE\$ *\$CODE*)
25  }
26  /* RO initialized data.  */
27  \$LITERAL\$ ALIGN (${PAGESIZE}) : {
28    *(\$LINK\$)
29    *(\$LITERAL\$)
30    *(\$READONLY\$)
31    *(\$READONLY_ADDR\$)
32    *(eh_frame)
33    *(jcr)
34    *(ctors)
35    *(dtors)
36    *(gcc_except_table)
37
38    /* LIB$INITIALIZE stuff.  */
39    *(LIB\$INITIALIZDZ)	/* Start marker.  */
40    *(LIB\$INITIALIZD_)	/* Hi priority.  */
41    *(LIB\$INITIALIZE)	/* User.  */
42    *(LIB\$INITIALIZE$)	/* End marker.  */
43  }
44
45  \$DWARF\$ ALIGN (${PAGESIZE}) : {
46    \$dwarf2.debug_pubtypes = .;
47    *(debug_pubtypes)
48    \$dwarf2.debug_ranges = .;
49    *(debug_ranges)
50
51    \$dwarf2.debug_abbrev = .;
52    *(debug_abbrev)
53    \$dwarf2.debug_aranges = .;
54    *(debug_aranges)
55    \$dwarf2.debug_frame = .;
56    *(debug_frame)
57    \$dwarf2.debug_info = .;
58    *(debug_info)
59    \$dwarf2.debug_line = .;
60    *(debug_line)
61    \$dwarf2.debug_loc = .;
62    *(debug_loc)
63    \$dwarf2.debug_macinfo = .;
64    *(debug_macinfo)
65    \$dwarf2.debug_macro = .;
66    *(debug_macro)
67    \$dwarf2.debug_pubnames = .;
68    *(debug_pubnames)
69    \$dwarf2.debug_str = .;
70    *(debug_str)
71    \$dwarf2.debug_zzzzzz = .;
72  }
73
74  \$DST\$ 0 : {
75    *(\$DST\$)
76  }
77}
78EOF
79