Merge from vendor branch CVS:
[dragonfly.git] / sys / conf / ldscript.amd64
1 /*
2  * $FreeBSD: src/sys/conf/ldscript.i386,v 1.4.2.1 2001/09/20 09:29:23 peter Exp $
3  * $DragonFly: src/sys/conf/Attic/ldscript.amd64,v 1.1 2004/02/02 08:05:56 dillon Exp $
4  */
5 OUTPUT_FORMAT("elf64-x86-64", "elf64-64", "elf64-x86-64")
6 OUTPUT_ARCH(i386:x86-64)
7 ENTRY(btext)
8 SEARCH_DIR(/usr/lib);
9 SECTIONS
10 {
11   /* Read-only sections, merged into text segment: */
12   . = kernbase + 0x00100000 + SIZEOF_HEADERS;
13   .interp     : { *(.interp)    }
14   .hash          : { *(.hash)           }
15   .dynsym        : { *(.dynsym)         }
16   .dynstr        : { *(.dynstr)         }
17   .gnu.version   : { *(.gnu.version)    }
18   .gnu.version_d   : { *(.gnu.version_d)        }
19   .gnu.version_r   : { *(.gnu.version_r)        }
20   .rel.text      :
21     { *(.rel.text) *(.rel.gnu.linkonce.t*) }
22   .rela.text     :
23     { *(.rela.text) *(.rela.gnu.linkonce.t*) }
24   .rel.data      :
25     { *(.rel.data) *(.rel.gnu.linkonce.d*) }
26   .rela.data     :
27     { *(.rela.data) *(.rela.gnu.linkonce.d*) }
28   .rel.rodata    :
29     { *(.rel.rodata) *(.rel.gnu.linkonce.r*) }
30   .rela.rodata   :
31     { *(.rela.rodata) *(.rela.gnu.linkonce.r*) }
32   .rel.got       : { *(.rel.got)                }
33   .rela.got      : { *(.rela.got)               }
34   .rel.ctors     : { *(.rel.ctors)      }
35   .rela.ctors    : { *(.rela.ctors)     }
36   .rel.dtors     : { *(.rel.dtors)      }
37   .rela.dtors    : { *(.rela.dtors)     }
38   .rel.init      : { *(.rel.init)       }
39   .rela.init     : { *(.rela.init)      }
40   .rel.fini      : { *(.rel.fini)       }
41   .rela.fini     : { *(.rela.fini)      }
42   .rel.bss       : { *(.rel.bss)                }
43   .rela.bss      : { *(.rela.bss)               }
44   .rel.plt       : { *(.rel.plt)                }
45   .rela.plt      : { *(.rela.plt)               }
46   .init          : { KEEP (*(.init))    } =0x90909090
47   .plt      : { *(.plt) }
48   .text      :
49   {
50     *(.text)
51     *(.stub)
52     /* .gnu.warning sections are handled specially by elf32.em.  */
53     *(.gnu.warning)
54     *(.gnu.linkonce.t*)
55   } =0x90909090
56   _etext = .;
57   PROVIDE (etext = .);
58   .fini      : { KEEP(*(.fini))   } =0x90909090
59   .rodata    : { *(.rodata) *(.gnu.linkonce.r*) }
60   .rodata1   : { *(.rodata1) }
61   /* Adjust the address for the data segment.  We want to adjust up to
62      the same address within the page on the next page up.  */
63   . = ALIGN(0x1000) + (. & (0x1000 - 1)) ; 
64   .data    :
65   {
66     *(.data)
67     *(.gnu.linkonce.d*)
68     CONSTRUCTORS
69   }
70   .data1   : { *(.data1) }
71   .ctors         :
72   {
73     *(.ctors)
74   }
75   .dtors         :
76   {
77     *(.dtors)
78   }
79   .got           : { *(.got.plt) *(.got) }
80   .dynamic       : { *(.dynamic) }
81   /* We want the small data sections together, so single-instruction offsets
82      can access them all, and initialized data all before uninitialized, so
83      we can shorten the on-disk segment size.  */
84   .sdata     : { *(.sdata) }
85   _edata  =  .;
86   PROVIDE (edata = .);
87   __bss_start = .;
88   .sbss      : { *(.sbss) *(.scommon) }
89   .bss       :
90   {
91    *(.dynbss)
92    *(.bss)
93    *(COMMON)
94   }
95   . = ALIGN(32 / 8);
96   _end = . ;
97   PROVIDE (end = .);
98   /* Stabs debugging sections.  */
99   .stab 0 : { *(.stab) }
100   .stabstr 0 : { *(.stabstr) }
101   .stab.excl 0 : { *(.stab.excl) }
102   .stab.exclstr 0 : { *(.stab.exclstr) }
103   .stab.index 0 : { *(.stab.index) }
104   .stab.indexstr 0 : { *(.stab.indexstr) }
105   .comment 0 : { *(.comment) }
106   /* DWARF debug sections.
107      Symbols in the DWARF debugging sections are relative to the beginning
108      of the section so we begin them at 0.  */
109   /* DWARF 1 */
110   .debug          0 : { *(.debug) }
111   .line           0 : { *(.line) }
112   /* GNU DWARF 1 extensions */
113   .debug_srcinfo  0 : { *(.debug_srcinfo) }
114   .debug_sfnames  0 : { *(.debug_sfnames) }
115   /* DWARF 1.1 and DWARF 2 */
116   .debug_aranges  0 : { *(.debug_aranges) }
117   .debug_pubnames 0 : { *(.debug_pubnames) }
118   /* DWARF 2 */
119   .debug_info     0 : { *(.debug_info) }
120   .debug_abbrev   0 : { *(.debug_abbrev) }
121   .debug_line     0 : { *(.debug_line) }
122   .debug_frame    0 : { *(.debug_frame) }
123   .debug_str      0 : { *(.debug_str) }
124   .debug_loc      0 : { *(.debug_loc) }
125   .debug_macinfo  0 : { *(.debug_macinfo) }
126   /* SGI/MIPS DWARF 2 extensions */
127   .debug_weaknames 0 : { *(.debug_weaknames) }
128   .debug_funcnames 0 : { *(.debug_funcnames) }
129   .debug_typenames 0 : { *(.debug_typenames) }
130   .debug_varnames  0 : { *(.debug_varnames) }
131   /* These must appear regardless of  .  */
132 }