OUTPUT_FORMAT(pei-i386) ENTRY(_mainCRTStartup) SECTIONS { /DISCARD/ : { *(.init) *(.text) *(SORT(.text$*)) *(.glue_7t) *(.glue_7) *(.fini) /* ??? Why is .gcc_exc here? */ *(.gcc_exc) *(.gcc_except_table) } /DISCARD/ : { *(init) } /* 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__. */ /DISCARD/ : { *(.data) *(.data2) *(SORT(.data$*)) *(.data_cygwin_nocopy) } /DISCARD/ : { *(.rdata) *(SORT(.rdata$*)) *(.eh_frame) } /DISCARD/ : { *(.edata) } /DISCARD/ : { *(.debug$S) *(.debug$T) *(.debug$F) *(.drectve) } /DISCARD/ : { /* 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) } /DISCARD/ : { *(SORT(.CRT$*)) } /DISCARD/ : { *(.rsrc) *(SORT(.rsrc$*)) } /DISCARD/ : { *(.bss) *(COMMON) } /DISCARD/ : { *(.reloc) } .stab BLOCK(__section_alignment__) (NOLOAD) : { [ .stab ] } .stabstr BLOCK(__section_alignment__) (NOLOAD) : { [ .stabstr ] } }