aboutsummaryrefslogtreecommitdiff
path: root/common/evdev.c
diff options
context:
space:
mode:
Diffstat (limited to 'common/evdev.c')
-rw-r--r--common/evdev.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/common/evdev.c b/common/evdev.c
index fe6922d..f3b39c6 100644
--- a/common/evdev.c
+++ b/common/evdev.c
@@ -1,9 +1,16 @@
-#include <linux/input.h>
#include <stdlib.h>
#include <sys/ioctl.h>
-#include <sys/sysmacros.h>
#include <sys/types.h>
+#if defined(__linux__)
+#include <linux/input.h>
+#include <sys/sysmacros.h>
+#elif defined(__FreeBSD__)
+#include <dev/evdev/input.h>
+#else
+#error Unsupported platform
+#endif
+
#include "evdev.h"
int evdev_revoke(int fd) {