OUTPUT_FORMAT(pei-i386) ENTRY(_mainCRTStartup) SECTIONS { .text __image_base__ + __section_alignment__ : { __text_start__ = .; *(.init) *(.text) *(SORT(.text$*)) *(.glue_7t) *(.glue_7) ___CTOR_LIST__ = .; __CTOR_LIST__ = . ; LONG (-1); *(.ctors); *(.ctor); LONG (0); ___DTOR_LIST__ = .; __DTOR_LIST__ = . ; LONG (-1); *(.dtors); *(.dtor); LONG (0); *(.fini) /* ??? Why is .gcc_exc here? */ *(.gcc_exc) __text_end__ = .; *(.gcc_except_table) } /* The Cygwin32 library uses a section to avoid copying certain data on fork. This used to be named ".data". The linker used to include this between __data_start__ and __data_end__, but that breaks building the cygwin32 dll. Instead, we name the section ".data_cygwin_nocopy" and explictly include it after __data_end__. */ .data BLOCK(__section_alignment__) : { __data_start__ = . ; *(.data) *(.data2) *(SORT(.data$*)) __data_end__ = . ; *(.data_cygwin_nocopy) } .rdata BLOCK(__section_alignment__) : { *(.rdata) *(SORT(.rdata$*)) *(.eh_frame) } .edata BLOCK(__section_alignment__) : { *(.edata) } .idata BLOCK(__section_alignment__) : { /* This cannot currently be handled with grouped sections. See pe.em:sort_sections. */ SORT(*)(.idata$2) SORT(*)(.idata$3) /* These zeroes mark the end of the import list. */ LONG (0); LONG (0); LONG (0); LONG (0); LONG (0); SORT(*)(.idata$4) SORT(*)(.idata$5) SORT(*)(.idata$6) SORT(*)(.idata$7) } .CRT BLOCK(__section_alignment__) : { *(SORT(.CRT$*)) } .rsrc BLOCK(__section_alignment__) : { *(.rsrc) *(SORT(.rsrc$*)) } .bss BLOCK(__section_alignment__) : { __bss_start__ = . ; *(.bss) *(COMMON) __bss_end__ = . ; } .reloc BLOCK(__section_alignment__) : { *(.reloc) /* These zeroes mark the end of the reloc section. */ LONG (0); LONG (0); LONG (0); LONG (0); LONG (0); } .debug_aranges BLOCK(__section_alignment__) : { *(.debug_aranges) } .debug_abbrev BLOCK(__section_alignment__) : { *(.debug_abbrev) } .debug_frame BLOCK(__section_alignment__) : { *(.debug_frame) } .debug_info BLOCK(__section_alignment__) : { *(.debug_info) } .debug_line BLOCK(__section_alignment__) : { *(.debug_line) } .debug_loc BLOCK(__section_alignment__) : { *(.debug_loc) } .debug_pubnames BLOCK(__section_alignment__) : { *(.debug_pubnames) } .debug_ranges BLOCK(__section_alignment__) : { *(.debug_ranges) } .debug_str BLOCK(__section_alignment__) : { *(.debug_str) } INIT BLOCK(__section_alignment__) : { __init_start__ = . ; *(INIT) __init_end__ = . ; } }