Thread (3 messages) flat view 3 messages, 3 authors, 2016-06-15

Re: [PATCH] HP-UX does not have select.h

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:44:00

"H.Merijn Brand" [off-list ref] writes:
HP-UX does not have select.h, but it offers all select () functionality.
The defines are in <sys/types.h> and <X11/fd.h>
Will apply the patch as-is for now, only because I do not want major
surgery during rc period, but I think is can be improved.

POSIX.1-2001 expects <sys/select.h> declares select(2).  With earlier
standards, including <sys/time.h>, <sys/types.h> and <unistd.h> would
have given it.

HP-UX cannot be the only pre-POSIX system; "#ifndef _HPUX_SOURCE" feels
very wrong.

Besides, isn't _HPUX_SOURCE a feature-test macro?  Feature test macros
are for the application to define, and for the implementation (iow, the
header files) to find out what set of names the application wants to
see.  You are making the application examine the symbol to see what
implementation it is on, which feels backwards to me.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help