From 9ba5447c9bbbd93808a56d9968b2e60f20bbd328 Mon Sep 17 00:00:00 2001 From: Damien Lespiau Date: Fri, 19 Nov 2010 14:31:51 -0500 Subject: [PATCH] evdev: Enable the compilation of the evdev backend for eglnative Not tested (but checked that it compiles). There's no reason to only enable the check for the cex100. Hopefully should work. We make sure not to enable both the evdev and the tslib backend at the same time as the DeviceManager is a singleton and we can't have both subclasses at the same time for now. --- configure.ac | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index 29beffbad..6427db88d 100644 --- a/configure.ac +++ b/configure.ac @@ -278,10 +278,23 @@ AS_CASE([$CLUTTER_FLAVOUR], [AC_DEFINE([HAVE_TSLIB], [1], [Have tslib for touchscreen handling])] ) + # evdev + PKG_CHECK_MODULES(EVDEV, [gudev-1.0 xkbcommon], + [have_evdev=yes], [have_evdev=no]) + AS_IF([test "x$have_evdev" = "xyes"], + [AC_DEFINE([HAVE_EVDEV], 1, + [Have evdev support for input handling])] + ) + + # Make sure we don't enable tslib and evdev at the same time, we + # don't support multiple event backends yet. + AS_IF([test "x$have_tslib" = "xyes" -a "x$have_evdev" = "xyes"], + [AC_MSG_ERROR([Can't enable both tslib and evdev events])]) + COGL_DRIVER="gles" - FLAVOUR_LIBS="$FLAVOUR_LIBS $TSLIB_LIBS" - FLAVOUR_CFLAGS="$FLAVOUR_CFLAGS $TSLIB_CFLAGS" + FLAVOUR_LIBS="$FLAVOUR_LIBS $TSLIB_LIBS $EVDEV_LIBS" + FLAVOUR_CFLAGS="$FLAVOUR_CFLAGS $TSLIB_CFLAGS $EVDEV_CFLAGS" CLUTTER_WINSYS=egl CLUTTER_SONAME_INFIX=eglnative