1 # Linker script for PE.
2 # These are substituted in as variables in order to get '}' in a shell
3 # conditional expansion.
4 INIT='.init : { *(.init) }'
5 FINI='.fini : { *(.fini) }'
7 OUTPUT_FORMAT(${OUTPUT_FORMAT})
10 ENTRY(_mainCRTStartup)
15 .text ${RELOCATING+ __image_base__ + __section_alignment__ } :
17 ${RELOCATING+ *(.init);}
19 ${CONSTRUCTING+ ___CTOR_LIST__ = .; __CTOR_LIST__ = . ;
20 LONG (-1); *(.ctors); *(.ctor); LONG (0); }
21 ${CONSTRUCTING+ ___DTOR_LIST__ = .; __DTOR_LIST__ = . ;
22 LONG (-1); *(.dtors); *(.dtor); LONG (0); }
23 ${RELOCATING+ *(.fini);}
24 ${RELOCATING+ etext = .};
27 .bss BLOCK(__section_alignment__) :
34 .data BLOCK(__section_alignment__) :
42 .rdata BLOCK(__section_alignment__) :
50 .edata BLOCK(__section_alignment__) : {
54 .junk BLOCK(__section_alignment__) : {
62 .idata BLOCK(__section_alignment__) :
72 .CRT BLOCK(__section_alignment__) :
89 .rsrc BLOCK(__section_alignment__) :
96 .endjunk BLOCK(__section_alignment__) :
98 ${RELOCATING+ end = .};
101 .stab BLOCK(__section_alignment__) ${RELOCATING+(NOLOAD)} :
106 .stabstr BLOCK(__section_alignment__) ${RELOCATING+(NOLOAD)} :
112 .reloc BLOCK(__section_alignment__) :