summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorDaniel Stone <daniel@fooishbar.org>2012-07-10 00:32:13 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2012-07-10 09:36:40 +0100
commit232217eef8f99f5678d65bf9aa5b898ef6d3b3c6 (patch)
tree22d00db9c82250c2e971b08cc312f51233efe117 /configure.ac
parent78dc0c04745ad4485b994f67833f4a155749f01d (diff)
i810: Make DGA optional
Don't build DGA when it's not available, or when we don't want it. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac20
1 files changed, 19 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index 15ed9b97..dde23f12 100644
--- a/configure.ac
+++ b/configure.ac
@@ -161,7 +161,6 @@ fi
PKG_CHECK_MODULES(XORG, [xorg-server >= $required_xorg_xserver_version xproto fontsproto pixman-1 >= $required_pixman_version $REQUIRED_MODULES])
-
AC_MSG_CHECKING([whether to include XAA support])
AC_ARG_ENABLE(xaa,
AS_HELP_STRING([--enable-xaa],
@@ -181,6 +180,25 @@ if test "x$XAA" = xyes; then
fi
AM_CONDITIONAL(XAA, test "x$XAA" = xyes)
+AC_MSG_CHECKING([whether to include DGA support])
+AC_ARG_ENABLE(dga,
+ AS_HELP_STRING([--enable-dga],
+ [Enable legacy Direct Graphics Access (DGA) [default=auto]]),
+ [DGA="$enableval"],
+ [DGA=auto])
+AC_MSG_RESULT([$DGA])
+AM_CONDITIONAL(DGA, test "x$DGA" != xno)
+if test "x$DGA" != xno; then
+ save_CFLAGS=$CFLAGS
+ CFLAGS=$XSERVER_CFLAGS
+ AC_CHECK_HEADERS([dgaproc.h], DGA=yes, DGA=no)
+ CFLAGS=$save_CFLAGS
+fi
+if test "x$DGA" = xyes; then
+ AC_DEFINE(USE_DGA, 1, [Enable DGA support])
+fi
+AM_CONDITIONAL(DGA, test "x$DGA" = xyes)
+
AC_ARG_WITH(default-accel,
AS_HELP_STRING([--with-default-accel],
[Select the default acceleration method [default=uxa if enabled, otherwise sna]]),