This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug lto/42776] LTO doesn't work on non-ELF platforms.
- From: "davek at gcc dot gnu dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 3 Feb 2010 12:02:18 -0000
- Subject: [Bug lto/42776] LTO doesn't work on non-ELF platforms.
- References: <bug-42776-14373@http.gcc.gnu.org/bugzilla/>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Comment #15 from davek at gcc dot gnu dot org 2010-02-03 12:02 -------
(In reply to comment #14)
> There is a portability issue in is_elf_or_coff: fopen should be called with
> "rb" instead of "r". Otherwise, fread fails when a COFF file has 26 sections,
> because it is interpreted as a text, and 26 means "end of file".
ROFL, yes of course, good catch. I should have remembered, there was just a
thread on the -patches list about adding "b" to the ELF LTO reader for the sake
of mingw-based cross-compilers!
> Not tried. GCC and Binutils can be built with -flto under MSYS, and they seem
> to work.
Thanks for the report :)
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=42776