Date: 17 Dec 1996 14:28:58 -0500 From: Jay Sachs <sachs@interactive.net> To: questions@FreeBSD.org Cc: tjb@fnbc.com Subject: Re: Anyone built gcc 2.7.2.1 on FreeBSD? Message-ID: <8720cp9dhh.fsf@luddite.org> In-Reply-To: Tim Bissell's message of Tue, 17 Dec 96 09:52:10 GMT References: <Pine.BSF.3.95.961216213200.10949E-100000@alive.ampr.ab.ca> <20786.9612170952@lihuge.fnbc.co.uk>
next in thread | previous in thread | raw e-mail | index | archive | help
Tim Bissell <tjb@fnbc.co.uk> writes:
>Has anyone there built gcc 2.7.2.1 (or any gcc > 2.6.3) on FreeBSD 2.x? I can
>build it and use it, but get occasional compiler warnings because it uses its
>own stddef.h in preference to /usr/include/stddef.h, which results in warnings
>about empty definitions in sys/types.h.
>
>The problem appears to be that the GNU stddef.h includes <machine/ansi.h> but
>then redefines defines _BSD_SIZE_T_ and _BSD_SSIZE_T_ to empty strings, rather
>than "int" and "unsigned int", or undefining them completely.
[...]
>Anyone else been through this? I guess we should make the GNU maintainers of
>gcc aware of the problem, because their code tries to cater for FreeBSD.
Been there, done that. It turns out gcc isn't quite configured
correctly for FreeBSD. I sent this patch a month ago to g++-bugs.
-jay
*** stddef.h.orig Wed Nov 13 09:51:36 1996
--- stddef.h Wed Nov 13 09:50:54 1996
***************
*** 257,263 ****
/* In 4.3bsd-net2, leave these undefined to indicate that size_t, etc.
are already defined. */
! #if defined(_ANSI_H_)
/* The references to _GCC_PTRDIFF_T_, _GCC_SIZE_T_, and _GCC_WCHAR_T_
are probably typos and should be removed before 2.8 is released. */
#ifdef _GCC_PTRDIFF_T_
--- 257,263 ----
/* In 4.3bsd-net2, leave these undefined to indicate that size_t, etc.
are already defined. */
! #if defined(_ANSI_H_) || defined (_MACHINE_ANSI_H_)
/* The references to _GCC_PTRDIFF_T_, _GCC_SIZE_T_, and _GCC_WCHAR_T_
are probably typos and should be removed before 2.8 is released. */
#ifdef _GCC_PTRDIFF_T_
***************
*** 285,291 ****
#undef _WCHAR_T_
#undef _BSD_WCHAR_T_
#endif
! #endif /* _ANSI_H_ */
#endif /* __sys_stdtypes_h */
--- 285,291 ----
#undef _WCHAR_T_
#undef _BSD_WCHAR_T_
#endif
! #endif /* _ANSI_H_ || _MACHINE_ANSI_H_ */
#endif /* __sys_stdtypes_h */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?8720cp9dhh.fsf>
