[USB-BRINGUP-TRUNK]
[reactos.git] / ntoskrnl / ntoskrnl_i386.lnk
1 OUTPUT_FORMAT(pei-i386)
2 ENTRY(_mainCRTStartup)
3 SECTIONS
4 {
5 .text __image_base__ + __section_alignment__ :
6 {
7 __text_start__ = .;
8 *(.init)
9 *(.text)
10 *(SORT(.text$*))
11 *(.glue_7t)
12 *(.glue_7)
13 ___CTOR_LIST__ = .; __CTOR_LIST__ = . ;
14 LONG (-1); *(.ctors); *(.ctor); LONG (0);
15 ___DTOR_LIST__ = .; __DTOR_LIST__ = . ;
16 LONG (-1); *(.dtors); *(.dtor); LONG (0);
17 *(.fini)
18 /* ??? Why is .gcc_exc here? */
19 *(.gcc_exc)
20 __text_end__ = .;
21 *(.gcc_except_table)
22 }
23 /* The Cygwin32 library uses a section to avoid copying certain data
24 on fork. This used to be named ".data". The linker used
25 to include this between __data_start__ and __data_end__, but that
26 breaks building the cygwin32 dll. Instead, we name the section
27 ".data_cygwin_nocopy" and explictly include it after __data_end__. */
28 .data BLOCK(__section_alignment__) :
29 {
30 __data_start__ = . ;
31 *(.data)
32 *(.data2)
33 *(SORT(.data$*))
34 __data_end__ = . ;
35 *(.data_cygwin_nocopy)
36 }
37 .rdata BLOCK(__section_alignment__) :
38 {
39 *(.rdata)
40 *(SORT(.rdata$*))
41 *(.eh_frame)
42 }
43 .edata BLOCK(__section_alignment__) :
44 {
45 *(.edata)
46 }
47 /DISCARD/ :
48 {
49 *(.debug$S)
50 *(.debug$T)
51 *(.debug$F)
52 *(.drectve)
53 }
54
55 .idata BLOCK(__section_alignment__) :
56 {
57 /* This cannot currently be handled with grouped sections.
58 See pe.em:sort_sections. */
59 SORT(*)(.idata$2)
60 SORT(*)(.idata$3)
61 /* These zeroes mark the end of the import list. */
62 LONG (0); LONG (0); LONG (0); LONG (0); LONG (0);
63 SORT(*)(.idata$4)
64 SORT(*)(.idata$5)
65 SORT(*)(.idata$6)
66 SORT(*)(.idata$7)
67 }
68 .CRT BLOCK(__section_alignment__) :
69 {
70 *(SORT(.CRT$*))
71 }
72 .rsrc BLOCK(__section_alignment__) :
73 {
74 *(.rsrc)
75 *(SORT(.rsrc$*))
76 }
77 .bss BLOCK(__section_alignment__) :
78 {
79 __bss_start__ = . ;
80 *(.bss)
81 *(COMMON)
82 __bss_end__ = . ;
83 }
84 .reloc BLOCK(__section_alignment__) :
85 {
86 *(.reloc)
87 /* These zeroes mark the end of the reloc section. */
88 LONG (0); LONG (0); LONG (0); LONG (0); LONG (0);
89 }
90 .stab BLOCK(__section_alignment__) (NOLOAD) :
91 {
92 [ .stab ]
93 }
94 .stabstr BLOCK(__section_alignment__) (NOLOAD) :
95 {
96 [ .stabstr ]
97 }
98 INIT BLOCK(__section_alignment__) :
99 {
100 __init_start__ = . ;
101 *(INIT)
102 __init_end__ = . ;
103 }
104 }
105