[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: sys/socket.h and source defines



On Mon, Feb 18, 2002 at 04:19:56PM -0700, Joel Baker wrote:
> As best I can tell, with the native NetBSD sys/socket.h, if a problem in
> any way defines (or triggers definition of) _POSIX_SOURCE or _XOPEN_SOURCE,
> anything which calls sys/socket.h will break horribly (since it uses values
> from types.h - which it also fails to include on it's own - which are only
> valid if not using POSIX sources, specifically u_char rather than u_int8_t)
> 
> Can anyone offer solutions to this? It's breaking a number of packages
> which, for various reasons, declare one of these two, and then include some
> file which, in turn, includes sys/socket.h

I'd look at adding #ifdef's into sys/socket.h to switch to u_int8_t if
_POSIX_SOURCE is defined.



Reply to: