On Fri, 2006-02-03 at 09:45 -0600, Joel Sherrill wrote:
> >>>The problem is with using stdint.h integer types without checking if
> >>>they are actually
> >>>available.  I have posted a fix for this already that needs to be
> >>>reviewed.  Along with
> >>>some other fixes for similar target OS dependent bugs.  Patch is here:
> >>>http://gcc.gnu.org/ml/gcc-patches/2006-02/msg00032.html
> >>>(and this is PR26050).
> >>>      
> >>>
> 
> After running autoconf, it fails a bit differently. Output below my 
> signature.
I can reproduce the breakdown ...

> But something doesn't seem right.  *-rtems* and other newlib targets 
> have a stdint.h. 

Right, but .. AFAIS, this issue isn't related to stdint.h, but to
sys/types.h

> In file included from 
> ../../../../gcc/libgcc-math/i386/../flt-32/e_acosf.c:21:
> ../../../../gcc/libgcc-math/i386/../include/math_private.h:58: error: 
> expected specifier-qualifier-list before 'uint32_t'
> ../../../../gcc/libgcc-math/i386/../include/math_private.h:129: error: 
> expected specifier-qualifier-list before 'uint32_t'
> ../../../../gcc/libgcc-math/i386/../include/math_private.h:182: error: 
> expected '=', ',', ';', 'asm' or '__attribute__' before '__ieee754_rem_pio2'
> ../../../../gcc/libgcc-math/i386/../include/math_private.h:190: warning: 
> type defaults to 'int' in declaration of 'int32_t'
> ../../../../gcc/libgcc-math/i386/../include/math_private.h:190: error: 
> expected ';', ',' or ')' before '*' token
[..]
> control reaches end of non-void function
> make[3]: *** [libsse2_la-e_acosf.lo] Error 1
> make[2]: *** [all-recursive] Error 1
> make[1]: *** [all-target-libgcc-math] Error 2
> make: *** [all] Error 2

IMO, the cause is obvious:

To retrieve fixed-size types, libgcc-math/include/math_private.h
includes <sys/types.h> and expects it to provide u_int32_t and int32_t.

This assumption holds on BSD compatible systems, where sys/types.h
provides these types, but according to POSIX this assumption is invalid,
c.f.
http://www.opengroup.org/onlinepubs/009695399/basedefs/sys/types.h.html

I don't know what has triggered this issue right now, but I know there
is an inconsistence on BSD-fixed size types in newlib's sys/types.h.
However I doubt this is the cause of this breakdown.

Ralf


Reply via email to