fixes bug #253 Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com>
@@ -28,6 +28,11 @@
#include <linux/version.h>
#define __LINUX_KERNEL_VERSION LINUX_VERSION_CODE
+/* When was `poll' introduced? */
+#if __LINUX_KERNEL_VERSION >= 131584
+# define __ASSUME_POLL_SYSCALL 1
+#endif
+
/* Real-time signal became usable in 2.1.70. */
#if __LINUX_KERNEL_VERSION >= 131398
# define __ASSUME_REALTIME_SIGNALS 1
@@ -19,8 +19,9 @@
#include <sys/syscall.h>
#include <sys/poll.h>
+#include <bits/kernel-features.h>
-#ifdef __NR_poll
+#if defined __ASSUME_POLL_SYSCALL && defined __NR_poll
_syscall3(int, poll, struct pollfd *, fds,
unsigned long int, nfds, int, timeout)