This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [patch win32]: fix for PR target/41943
- From: Ozkan Sezer <sezeroz at gmail dot com>
- To: Kai Tietz <ktietz70 at googlemail dot com>
- Cc: Danny Smith <dansmister at gmail dot com>, Richard Henderson <rth at redhat dot com>, Dave Korn <dave dot korn dot cygwin at googlemail dot com>, gcc-patches at gcc dot gnu dot org
- Date: Thu, 22 Jul 2010 11:13:34 +0300
- Subject: Re: [patch win32]: fix for PR target/41943
>>> (i[34567]86-*-mingw* | x86_64-*-mingw*): Use
>>> for float.h post, and for w64 targets stddef.h/stdarg.h pre
>>> fixing by include_next.
>> The mingw323 float.h is alrewady prefixed with
>>
>> #include_next<float.h>
>>
>> #ifndef _MINGW_FLOAT_H_
>> #define _MINGW_FLOAT_H_
>>
>> ....
>>
>> Postfixing #include_next <float.h> onto gcc's float.h causes:
>>
>> gcc -H -Wall f.c
>> . c:\mingw\bin\../lib/gcc/mingw32/4.6.0/../../../../include/float.h
>> .. c:\mingw\bin\../lib/gcc/mingw32/4.6.0/include/float.h
>> In file included from c:\mingw\bin\../lib/gcc/mingw32/4.6.0/../../../../include/
>> float.h:19:0,
>> from f.c:1:
>> c:\mingw\bin\../lib/gcc/mingw32/4.6.0/include/float.h:278:24: fatal error: float
>> .h: No such file or directory
>> compilation terminated.
>>
>> Danny
>>
>
> I know. But as the float.h from gcc's internal header always comes
> first in include order, this next_include in system-headers is wrong.
> I tried to move the order of includes, but this patch was rejected. So
> the way to solve this is by pre/post-fixing those headers to make sure
> that by default the system-header is included, too.
> If you prefer to have this change just for w64, I am fine.
>
> Regards,
> Kai
What is in the way for the formerly suggested solution for this,
ie. this one:
http://gcc.gnu.org/ml/gcc-patches/2010-07/msg01450.html
Which seems like a much cleaner solution to me (my opinion, of
course.)
--
Ozkan