As per title, and see also the discussion in bug 41529. There is no fundamental requirement for ELF to be the object format, as the object file sections are just used as dumb containers for arbitrary binary data. The interface between lto-elf.c and the rest of lto1 needs only the ability to create sections and to place and retrieve binary data in/from them, so should be easy to implement for any object format that allows arbitrarily-named sections; that's everything except a.out I would suppose.
I'm only planning to fix this for the PE-COFF (windows) platforms, but I'll try and make the code general enough so that it works on other COFF platforms and just needs enabling by the relevant target maintainer. -- Summary: LTO doesn't work on non-ELF platforms. Product: gcc Version: 4.5.0 Status: UNCONFIRMED Keywords: build, lto Severity: normal Priority: P3 Component: lto AssignedTo: davek at gcc dot gnu dot org ReportedBy: davek at gcc dot gnu dot org GCC build triplet: i686-pc-cygwin GCC host triplet: i686-pc-cygwin GCC target triplet: i686-pc-cygwin http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42776