[PATCH 1/3] configure: Let configure --enable/disable-aiglx control building of AIGLX for all DDXs

Jon TURNEY jon.turney at dronecode.org.uk
Thu Apr 14 05:46:49 PDT 2011


Let configure --enable/disable-aiglx control building of AIGLX for all DDXs. Currently
we can't use --enable/disable-aiglx to control if Xwin DDX is built with AIGLX enabled,
as at the moment it's forced off if we aren't building the X.Org DDX DRI loader

Rearrange things a bit, introducing a new automake conditional, AIGLX_DRI_LOADER to
specifically indicate if the X.Org DDX DRI loader should be built, and replace the previous
X.Org DDX-specific uses of the AIGLX conditional with that

As before, AIGLX_DRI_LOADER is only enabled if all of --enable-glx, --enable-aiglx and
--enable-dri are

This allows the general conditional AIGLX to control if AIGLX is built for the XWin DDX as
well

Perhaps some more refactoring could be done here to make the configuration of DRI1 and
DRI2 loaders orthogonal, so they can be configured independently.

The C #define AIGLX set by AC_DEFINE(AIGLX) seems to be obsolete, I can't find anything
which checks it

Signed-off-by: Jon TURNEY <jon.turney at dronecode.org.uk>
---
 configure.ac                   |   12 +++++++-----
 glx/Makefile.am                |    2 +-
 hw/xfree86/dixmods/Makefile.am |    2 +-
 3 files changed, 9 insertions(+), 7 deletions(-)

diff --git a/configure.ac b/configure.ac
index 9e04ff0..729fb96 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1006,12 +1006,14 @@ else
 fi
 AM_CONDITIONAL(GLX, test "x$GLX" = xyes)
 
-if test "x$AIGLX" = xyes -a "x$GLX" = xyes -a "x$DRI" = xyes; then
+if test "x$GLX" = xno; then
+        AIGLX=no
+fi
+
+if test "x$AIGLX" = xyes -a "x$DRI" = xyes; then
 	AC_DEFINE(AIGLX, 1, [Build AIGLX loader])
-else
-	AIGLX=no
 fi
-AM_CONDITIONAL(AIGLX, test "x$AIGLX" = xyes)
+AM_CONDITIONAL(AIGLX_DRI_LOADER, test "x$DRI" = xyes && test "x$AIGLX" = xyes)
 
 if test "x$GLX_USE_TLS" = xyes ; then
 	GLX_DEFINES="-DGLX_USE_TLS -DPTHREADS"
@@ -1855,7 +1857,7 @@ AM_CONDITIONAL(XWIN, [test "x$XWIN" = xyes])
 AM_CONDITIONAL(XWIN_MULTIWINDOW, [test "x$XWIN" = xyes])
 AM_CONDITIONAL(XWIN_MULTIWINDOWEXTWM, [test "x$XWIN" = xyes && test "x$WINDOWSWM" = xyes])
 AM_CONDITIONAL(XWIN_CLIPBOARD, [test "x$XWIN" = xyes])
-AM_CONDITIONAL(XWIN_GLX_WINDOWS, [test "x$XWIN" = xyes && false])
+AM_CONDITIONAL(XWIN_GLX_WINDOWS, [test "x$XWIN" = xyes && test "x$AIGLX" = xyes])
 AM_CONDITIONAL(XWIN_NATIVEGDI, [test "x$XWIN" = xyes])
 AM_CONDITIONAL(XWIN_PRIMARYFB, [test "x$XWIN" = xyes])
 AM_CONDITIONAL(XWIN_RANDR, [test "x$XWIN" = xyes])
diff --git a/glx/Makefile.am b/glx/Makefile.am
index 72531f2..e0c74b7 100644
--- a/glx/Makefile.am
+++ b/glx/Makefile.am
@@ -1,4 +1,4 @@
-if AIGLX
+if AIGLX_DRI_LOADER
 GLXDRI_LIBRARY = libglxdri.la
 endif
 
diff --git a/hw/xfree86/dixmods/Makefile.am b/hw/xfree86/dixmods/Makefile.am
index 365f006..1a162ab 100644
--- a/hw/xfree86/dixmods/Makefile.am
+++ b/hw/xfree86/dixmods/Makefile.am
@@ -45,7 +45,7 @@ libwfb_la_SOURCES = $(top_builddir)/fb/fbcmap_mi.c fbmodule.c
 libwfb_la_CFLAGS = $(AM_CFLAGS) -DFB_ACCESS_WRAPPER
 
 libglx_la_LDFLAGS = -avoid-version
-if AIGLX
+if AIGLX_DRI_LOADER
 GLXDRI_LIBRARY = $(top_builddir)/glx/libglxdri.la
 endif
 libglx_la_LIBADD = \
-- 
1.7.4



More information about the xorg-devel mailing list