From 2b9dac397bd97909876bbda8532e2cbce9d8a77f Mon Sep 17 00:00:00 2001 From: Jon TURNEY Date: Wed, 21 Apr 2010 12:58:54 +0100 Subject: Make XF86VIDMODE extension optional Code in glx/glxcmds.c which uses the XF86VIDMODE extension is already guarded. Also use that guard to control inclusion of the xf86vmode.h header, and only enable that guard if the XF86VIDMODE extension is found by pkgconfig. This changes the behaviour on platforms which XF86VIDMODE exists, in that XF86VIDMODE used to be mandatory, but is now optional. Presumably other build systems are already arranging for -DXF86VIDMODE to be supplied to the complier when glxcmds.c is compiled, so are not affected by this change Signed-off-by: Jon TURNEY --- configure.ac | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index d3d74ac265a..a7ee0f5763c 100644 --- a/configure.ac +++ b/configure.ac @@ -626,8 +626,15 @@ dri) # find the DRI deps for libGL if test "$x11_pkgconfig" = yes; then + dri_modules="x11 xext xdamage xfixes" + + # add xf86vidmode if available + PKG_CHECK_MODULES([XF86VIDMODE], [xxf86vm], HAVE_XF86VIDMODE=yes, HAVE_XF86VIDMODE=no) + if test "$HAVE_XF86VIDMODE" = yes ; then + dri_modules="$dri_modules xxf86vm" + fi + # add xcb modules if necessary - dri_modules="x11 xext xxf86vm xdamage xfixes" if test "$enable_xcb" = yes; then dri_modules="$dri_modules x11-xcb xcb-glx" fi @@ -676,6 +683,8 @@ AC_SUBST([GLESv2_LIB_DEPS]) AC_SUBST([GLESv2_PC_LIB_PRIV]) +AC_SUBST([HAVE_XF86VIDMODE]) + dnl dnl More X11 setup dnl -- cgit v1.2.3