summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--configure.ac14
-rw-r--r--src/Makefile.am6
-rw-r--r--src/eventcomm.c4
-rw-r--r--src/eventcomm.h4
4 files changed, 19 insertions, 9 deletions
diff --git a/configure.ac b/configure.ac
index 16cc04c..ad45502 100644
--- a/configure.ac
+++ b/configure.ac
@@ -44,6 +44,20 @@ AC_PROG_CC
AH_TOP([#include "xorg-server.h"])
+AC_MSG_CHECKING([if eventcomm will be built])
+case "${host}" in
+*linux*)
+ AC_MSG_RESULT([yes])
+ BUILD_EVENTCOMM="yes"
+ ;;
+*)
+ AC_MSG_RESULT([no])
+ BUILD_EVENTCOMM="no"
+ ;;
+esac
+AM_CONDITIONAL([BUILD_EVENTCOMM], [test "x${BUILD_EVENTCOMM}" = "xyes"])
+
+
#AC_DEFINE(XFree86LOADER,1,[Stub define for loadable drivers])
#
#AC_ARG_ENABLE(XINPUT, AS_HELP_STRING([--enable-xinput],
diff --git a/src/Makefile.am b/src/Makefile.am
index 98a14c0..04be371 100644
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -30,11 +30,15 @@
@DRIVER_NAME@_drv_la_SOURCES = @DRIVER_NAME@.c @DRIVER_NAME@.h \
alpscomm.c alpscomm.h \
- eventcomm.c eventcomm.h \
ps2comm.c ps2comm.h \
psmcomm.c psmcomm.h \
synproto.h
+if BUILD_EVENTCOMM
+@DRIVER_NAME@_drv_la_SOURCES += \
+ eventcomm.c eventcomm.h
+endif
+
bin_PROGRAMS = \
synclient \
syndaemon
diff --git a/src/eventcomm.c b/src/eventcomm.c
index 418c7bf..36c4c9e 100644
--- a/src/eventcomm.c
+++ b/src/eventcomm.c
@@ -24,8 +24,6 @@
* Peter Osterlund (petero2@telia.com)
*/
-#ifdef __LINUX
-
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
@@ -324,5 +322,3 @@ struct SynapticsProtocolOperations event_proto_operations = {
EventReadHwState,
EventAutoDevProbe
};
-
-#endif
diff --git a/src/eventcomm.h b/src/eventcomm.h
index 6f30e1e..a4a9a44 100644
--- a/src/eventcomm.h
+++ b/src/eventcomm.h
@@ -27,14 +27,10 @@
#ifndef _EVENTCOMM_H_
#define _EVENTCOMM_H_
-#ifdef __LINUX
-
#include <linux/input.h>
/* for auto-dev: */
#define DEV_INPUT_EVENT "/dev/input"
#define EVENT_DEV_NAME "event"
-#endif
-
#endif /* _EVENTCOMM_H_ */