poll.h vs sys/poll.h on QNX Neutrino
Darren Tucker
dtucker at zip.com.au
Fri Sep 21 13:02:56 EST 2007
On Tue, Sep 18, 2007 at 05:52:45PM -0600, David Bacon wrote:
> [...] Some older
> systems, and some not-quite-XSI-compliant
> systems such as QNX Neutrino, still have
> <sys/poll.h> but not <poll.h>.
>
> I suggest having configure.ac look for
> both, and put the check for <poll.h> first
> in atomicio.c, as in:
Sounds reasonable. Could you please confirm that this works? You will need
to run "autoreconf" to rebuild configure, then re-run configure. Thanks.
Index: configure.ac
===================================================================
RCS file: /usr/local/src/security/openssh/cvs/openssh/configure.ac,v
retrieving revision 1.384
diff -u -p -r1.384 configure.ac
--- configure.ac 10 Sep 2007 23:24:18 -0000 1.384
+++ configure.ac 21 Sep 2007 02:59:09 -0000
@@ -223,6 +223,7 @@ AC_CHECK_HEADERS( \
sys/dir.h \
sys/mman.h \
sys/ndir.h \
+ sys/poll.h \
sys/prctl.h \
sys/pstat.h \
sys/select.h \
Index: atomicio.c
===================================================================
RCS file: /usr/local/src/security/openssh/cvs/openssh/atomicio.c,v
retrieving revision 1.35
diff -u -p -r1.35 atomicio.c
--- atomicio.c 25 Jun 2007 12:15:12 -0000 1.35
+++ atomicio.c 21 Sep 2007 02:57:54 -0000
@@ -34,6 +34,10 @@
#include <errno.h>
#ifdef HAVE_POLL_H
#include <poll.h>
+#else
+# ifdef HAVE_SYS_POLL_H
+# include <sys/poll.h>
+# endif
#endif
#include <string.h>
#include <unistd.h>
--
Darren Tucker (dtucker at zip.com.au)
GPG key 8FF4FA69 / D9A3 86E9 7EEE AF4B B2D4 37C9 C982 80C7 8FF4 FA69
Good judgement comes with experience. Unfortunately, the experience
usually comes from bad judgement.
More information about the openssh-unix-dev
mailing list