[PATCH 17/18] Provide __size_t via <sys/_types.h>
Corinna Vinschen
vinschen@redhat.com
Thu Apr 14 16:26:00 GMT 2016
On Apr 14 13:54, Sebastian Huber wrote:
> Various FreeBSD source and header files need a typedef __size_t via
> <sys/_types.h>. Unfortunately the GCC provided <stddef.h> uses
>
> #if (defined (__FreeBSD__) && (__FreeBSD__ >= 5)) \
> || defined(__DragonFly__) \
> || defined(__FreeBSD_kernel__)
> /* __size_t is a typedef on FreeBSD 5, must not trash it. */
> #elif defined (__VMS__)
> /* __size_t is also a typedef on VMS. */
> #else
> #define __size_t
> #endif
>
> and therefore defines __size_t on Newlib targets which would trash a
> __size_t typedef. Include <stddef.h> before <sys/_types.h> in
> <sys/types.h> and undefine __size_t in <sys/_types.h> as a workaround.
What about GCC upstream? Why are they doing that in the first place?
What sense does it make to set __size_t to nothing, rather than setting
it to __SIZE_TYPE__?
Did you ask on the gcc list?
Thanks,
Corinna
--
Corinna Vinschen
Cygwin Maintainer
Red Hat
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/newlib/attachments/20160414/c2b5cba7/attachment.sig>
More information about the Newlib
mailing list