summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--configure.in8
-rw-r--r--hald/linux/addons/addon-acpi-buttons-toshiba.c7
-rw-r--r--hald/linux/addons/addon-input.c6
-rw-r--r--hald/linux/device.c7
-rw-r--r--hald/linux/probing/probe-input.c7
-rw-r--r--tools/hal-setup-keymap.c6
6 files changed, 36 insertions, 5 deletions
diff --git a/configure.in b/configure.in
index fc5a6916..90f10f36 100644
--- a/configure.in
+++ b/configure.in
@@ -919,6 +919,14 @@ fi
msg_sonypic=$have_sonypic
AM_CONDITIONAL(HAVE_SONYPIC, [test x$msg_sonypic = xyes], [Compiling Sony PIC])
+dnl use non-system input.h
+AC_ARG_WITH([linux-input-header],
+ AS_HELP_STRING([--with-linux-input-header=<path>],
+ [Use an given Linux input.h rather than that installed on the system (<linux/input.h>)]))
+if test "x$with_linux_input_header" != "x"; then
+ AC_DEFINE_UNQUOTED(HAL_LINUX_INPUT_HEADER_H, "$with_linux_input_header", [If set, the header to use instead of <linux/input.h>])
+fi
+
dnl
dnl SUBSETTING END
dnl
diff --git a/hald/linux/addons/addon-acpi-buttons-toshiba.c b/hald/linux/addons/addon-acpi-buttons-toshiba.c
index f3369927..f0dc09d3 100644
--- a/hald/linux/addons/addon-acpi-buttons-toshiba.c
+++ b/hald/linux/addons/addon-acpi-buttons-toshiba.c
@@ -29,7 +29,12 @@
# include <config.h>
#endif
-#include <linux/input.h>
+#ifdef HAL_LINUX_INPUT_HEADER_H
+ #include HAL_LINUX_INPUT_HEADER_H
+else
+ #include <linux/input.h>
+#endif
+
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
diff --git a/hald/linux/addons/addon-input.c b/hald/linux/addons/addon-input.c
index 2ba923b2..11d9ebc6 100644
--- a/hald/linux/addons/addon-input.c
+++ b/hald/linux/addons/addon-input.c
@@ -36,7 +36,11 @@
#include <sys/stat.h>
#include <fcntl.h>
-#include <linux/input.h>
+#ifdef HAL_LINUX_INPUT_HEADER_H
+ #include HAL_LINUX_INPUT_HEADER_H
+#else
+ #include <linux/input.h>
+#endif
#include <glib/gmain.h>
#include <glib/gprintf.h>
#include <dbus/dbus-glib-lowlevel.h>
diff --git a/hald/linux/device.c b/hald/linux/device.c
index 8cc12efa..0d30ff64 100644
--- a/hald/linux/device.c
+++ b/hald/linux/device.c
@@ -38,7 +38,12 @@
#include <unistd.h>
#include <asm/byteorder.h>
#include <fcntl.h>
-#include <linux/input.h>
+
+#ifdef HAL_LINUX_INPUT_HEADER_H
+ #include HAL_LINUX_INPUT_HEADER_H
+#else
+ #include <linux/input.h>
+#endif
#include <dbus/dbus.h>
#include <dbus/dbus-glib.h>
diff --git a/hald/linux/probing/probe-input.c b/hald/linux/probing/probe-input.c
index 6a107fbb..6ace0fac 100644
--- a/hald/linux/probing/probe-input.c
+++ b/hald/linux/probing/probe-input.c
@@ -29,13 +29,18 @@
#include <errno.h>
#include <fcntl.h>
-#include <linux/input.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
+#ifdef HAL_LINUX_INPUT_HEADER_H
+ #include HAL_LINUX_INPUT_HEADER_H
+#else
+ #include <linux/input.h>
+#endif
+
#include "libhal/libhal.h"
#include "../../logger.h"
diff --git a/tools/hal-setup-keymap.c b/tools/hal-setup-keymap.c
index 4ae82f50..24c51f94 100644
--- a/tools/hal-setup-keymap.c
+++ b/tools/hal-setup-keymap.c
@@ -31,7 +31,11 @@
#include <unistd.h>
#include <sys/ioctl.h>
-#include <linux/input.h>
+#ifdef HAL_LINUX_INPUT_HEADER_H
+ #include HAL_LINUX_INPUT_HEADER_H
+#else
+ #include <linux/input.h>
+#endif
#include "libhal/libhal.h"
#include "hal-setup-keymap-hash-name.h"