On Tue, Oct 06, 2009 at 04:56:05PM -0700, Jeremy Huddleston wrote: > > On Oct 6, 2009, at 15:45, Peter Hutterer wrote: > >> + PKG_CHECK_MODULES(RECORDPROTO_1_13, xtst [recordproto <= 1.13.2], >> HAVE_RECORDPROTO="yes", HAVE_RECORDPROTO="no") > > "< 1.13.99.1" feels nicer to me... just in case 1.13.3 happens for some > reason...
thanks, done. see below: >From d83025df07a0f29685b2400871a1f0e9a06e514f Mon Sep 17 00:00:00 2001 From: Peter Hutterer <[email protected]> Date: Tue, 6 Oct 2009 08:06:37 +1000 Subject: [PATCH] Require recordproto 1.13 or libXtst 1.1 for record support. The record.h header used to be in recordproto up to excluding 1.14, then moved to libXtst. Check for both and enable it dependent on which version we have. This avoids build errors on setups where a user updated recordproto but not libXtst. Signed-off-by: Peter Hutterer <[email protected]> Reviewed-by: Xavier Chantry <[email protected]> --- configure.ac | 9 ++++++++- tools/Makefile.am | 2 +- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index e9e0560..44800ea 100644 --- a/configure.ac +++ b/configure.ac @@ -106,7 +106,14 @@ AC_ARG_ENABLE(tools, [build_tools="auto"]) if test "x$build_tools" != "xno"; then - PKG_CHECK_MODULES(XRECORD, xtst, AC_DEFINE([HAVE_XRECORD],[],[Use XRecord]), true) + # Record.h is either in recordproto up to 1.13.2 or in libXtst 1.1. + PKG_CHECK_MODULES(XTST_1_1, [xtst >= 1.0.99.1], HAVE_LIBXTST="yes", HAVE_LIBXTST="no") + PKG_CHECK_MODULES(RECORDPROTO_1_13, xtst [recordproto < 1.13.99.1], HAVE_RECORDPROTO="yes", HAVE_RECORDPROTO="no") + + if test "x$HAVE_LIBXTST" = "xyes" || test "x$HAVE_RECORDPROTO" = "xyes" ; then + AC_DEFINE([HAVE_XRECORD],[],[Use XRecord]) + fi + PKG_CHECK_MODULES(XI, x11 [xi >= 1.2] [xorg-server >= 1.6], BUILD_TOOLS="yes"; AC_DEFINE(BUILD_TOOLS, 1, "Build synclient and syndaemon"), BUILD_TOOLS="no"; diff --git a/tools/Makefile.am b/tools/Makefile.am index 35c04a1..65820ff 100644 --- a/tools/Makefile.am +++ b/tools/Makefile.am @@ -29,7 +29,7 @@ synclient_SOURCES = synclient.c synclient_LDFLAGS = -lm $(XI_LIBS) syndaemon_SOURCES = syndaemon.c -syndaemon_LDFLAGS = $(XRECORD_LIBS) $(XI_LIBS) +syndaemon_LDFLAGS = $(XTST_1_1_LIBS) $(RECORDPROTO_1_13_LIBS) $(XI_LIBS) else all: @echo "Not building syndaemon and synclient." -- 1.6.3.rc1.2.g0164.dirty _______________________________________________ xorg-devel mailing list [email protected] http://lists.x.org/mailman/listinfo/xorg-devel
