4 * Copyright (c) 1997-8 Graham Barr <gbarr@pobox.com>. All rights reserved.
5 * This program is free software; you can redistribute it and/or
6 * modify it under the same terms as Perl itself.
13 #if (defined(HAS_POLL) && defined(I_POLL)) || defined(POLLWRBAND)
15 #elif (defined(HAS_POLL) && defined(I_SYS_POLL))
16 # include <sys/poll.h>
21 /* We shall emulate poll using select */
23 #define EMULATE_POLL_WITH_SELECT
28 #define poll Perl_my_poll
30 typedef struct pollfd {
37 #define POLLPRI 0x0002
38 #define POLLOUT 0x0004
39 #define POLLRDNORM 0x0040
40 #define POLLWRNORM POLLOUT
41 #define POLLRDBAND 0x0080
42 #define POLLWRBAND 0x0100
43 #define POLLNORM POLLRDNORM
45 /* Return ONLY events (NON testable) */
47 #define POLLERR 0x0008
48 #define POLLHUP 0x0010
49 #define POLLNVAL 0x0020
51 int poll (struct pollfd *, unsigned long, int);
57 #endif /* HAS_SELECT */