diff options
author | Peter Hutterer <peter.hutterer@who-t.net> | 2009-04-17 15:19:41 +1000 |
---|---|---|
committer | Peter Hutterer <peter.hutterer@who-t.net> | 2009-04-26 21:00:52 +1000 |
commit | 080caee95c46bb471d1442dcab246460cad8c7be (patch) | |
tree | 4d83acc9aadd1b31dfc64d386a5730702ddf6e90 /configure.ac | |
parent | b56ab7e0140c8fa7dcc58f6b8a087f7d6bece04f (diff) |
Only build synclient/syndaemon if property support is available.
Separate dependencies for driver and synclient/syndaemon.
Add option --enable-tools to explicitly build the tools (default: auto)
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 22 |
1 files changed, 19 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac index 4280fff..38dd2a0 100644 --- a/configure.ac +++ b/configure.ac @@ -96,9 +96,25 @@ CFLAGS="$CFLAGS $XORG_CFLAGS "' -I$(top_srcdir)/src' AC_SUBST([CFLAGS]) # Checks for libraries. -PKG_CHECK_MODULES(XLIB, x11) # needed for syndaemon -PKG_CHECK_MODULES(XRECORD, xtst, AC_DEFINE([HAVE_XRECORD],[],[Use XRecord]), true) -PKG_CHECK_MODULES(XI, xi); +AC_ARG_ENABLE(tools, + AC_HELP_STRING([--enable-tools], [Build synclient and syndaemon [[default=auto]]]), + [build_tools="$enableval"], + [build_tools="auto"]) + +if test "x$build_tools" != "xno"; then + PKG_CHECK_MODULES(XRECORD, xtst, AC_DEFINE([HAVE_XRECORD],[],[Use XRecord]), true) + 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"; + if test "x$build_tools" = "xyes"; then + AC_MSG_ERROR([Dependencies failed for synclient and syndaemon.]) + else + AC_MSG_WARN([Not building synclient and syndaemon.]) + fi + ) +fi +AM_CONDITIONAL(BUILD_TOOLS, [ test "$BUILD_TOOLS" = "yes" ]) +AC_SUBST(BUILD_TOOLS) # Checks for header files. AC_HEADER_STDC |