X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-psi;a=blobdiff_plain;f=m4%2Fpoll.m4;fp=m4%2Fpoll.m4;h=2105a645e46f49df44fc43317e82b9b1b26215e4;hp=0000000000000000000000000000000000000000;hb=5abcb8724ac7046d62203ea643e9ce69f63a6a8a;hpb=63fa6c00c541b9462784337e15955d7c3027f2f3 diff --git a/m4/poll.m4 b/m4/poll.m4 new file mode 100644 index 0000000..2105a64 --- /dev/null +++ b/m4/poll.m4 @@ -0,0 +1,24 @@ +PSI_CHECK_POLL() { + AC_CHECK_HEADERS(poll.h) + + PSI_STRUCT(struct pollfd, [ + int fd, + short events, + short revents] + ) + + PSI_TYPE(nfds_t, uint) + + PSI_CONST(POLLIN, int) + PSI_CONST(POLLRDNORM, int) + PSI_CONST(POLLRDBAND, int) + PSI_CONST(POLLPRI, int) + PSI_CONST(POLLOUT, int) + PSI_CONST(POLLWRNORM, int) + PSI_CONST(POLLRWBAND, int) + PSI_CONST(POLLERR, int) + PSI_CONST(POLLHUP, int) + PSI_CONST(POLLNVAL, int) + + PSI_DECL(int poll, [(struct pollfd *fds, nfds_t nfds, int timeout)]) +}