diff options
author | Daniel Stone <daniel@fooishbar.org> | 2006-08-10 20:28:06 +0300 |
---|---|---|
committer | Daniel Stone <daniels@endtroducing.fooishbar.org> | 2006-08-10 20:28:06 +0300 |
commit | 6d8d4abaaacf08140b673472d985117d448a62e7 (patch) | |
tree | 2d05a0eaf809efaadcc14dc8a8105f7d92482500 /configure.ac | |
parent | cec284f2b3e948deb9e56a1a8519fddf693ab952 (diff) |
configure.ac: allow conditional building of XF86{DGA,Misc,VidMode}
Allow conditional building of the above three extensions, defaulting to
auto.
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 55 |
1 files changed, 33 insertions, 22 deletions
diff --git a/configure.ac b/configure.ac index dffa472f9..62a384860 100644 --- a/configure.ac +++ b/configure.ac @@ -404,7 +404,7 @@ AC_ARG_ENABLE(xtrap, AS_HELP_STRING([--disable-xtrap], [Build XTrap ext AC_ARG_ENABLE(record, AS_HELP_STRING([--disable-record], [Build Record extension (default: enabled)]), [RECORD=$enableval], [RECORD=yes]) AC_ARG_ENABLE(xv, AS_HELP_STRING([--disable-xv], [Build Xv extension (default: enabled)]), [XV=$enableval], [XV=yes]) AC_ARG_ENABLE(xvmc, AS_HELP_STRING([--disable-xvmc], [Build XvMC extension (default: enabled)]), [XVMC=$enableval], [XVMC=yes]) -AC_ARG_ENABLE(dga, AS_HELP_STRING([--disable-dga], [Build DGA extension (default: enabled)]), [DGA=$enableval], [DGA=yes]) +AC_ARG_ENABLE(dga, AS_HELP_STRING([--disable-dga], [Build DGA extension (default: auto)]), [DGA=$enableval], [DGA=auto]) AC_ARG_ENABLE(screensaver, AS_HELP_STRING([--disable-screensaver], [Build ScreenSaver extension (default: enabled)]), [SCREENSAVER=$enableval], [SCREENSAVER=yes]) AC_ARG_ENABLE(xdmcp, AS_HELP_STRING([--disable-xdmcp], [Build XDMCP extension (default: auto)]), [XDMCP=$enableval], [XDMCP=auto]) AC_ARG_ENABLE(xdm-auth-1, AS_HELP_STRING([--disable-xdm-auth-1], [Build XDM-Auth-1 extension (default: auto)]), [XDMAUTH=$enableval], [XDMAUTH=auto]) @@ -413,8 +413,8 @@ AC_ARG_ENABLE(aiglx, AS_HELP_STRING([--enable-aiglx], [Build accelerate AC_ARG_ENABLE(glx-tls, AS_HELP_STRING([--enable-glx-tls], [Build GLX with TLS support (default: disabled)]), [GLX_USE_TLS=$enableval], [GLX_USE_TLS=no]) AC_ARG_ENABLE(dri, AS_HELP_STRING([--enable-dri], [Build DRI extension (default: auto)]), [DRI=$enableval]) AC_ARG_ENABLE(xinerama, AS_HELP_STRING([--disable-xinerama], [Build Xinerama extension (default: enabled)]), [XINERAMA=$enableval], [XINERAMA=yes]) -AC_ARG_ENABLE(xf86vidmode, AS_HELP_STRING([--disable-xf86vidmode], [Build XF86VidMode extension (default: enabled)]), [XF86VIDMODE=$enableval], [XF86VIDMODE=yes]) -AC_ARG_ENABLE(xf86misc, AS_HELP_STRING([--disable-xf86misc], [Build XF86Misc extension (default: enabled)]), [XF86MISC=$enableval], [XF86MISC=yes]) +AC_ARG_ENABLE(xf86vidmode, AS_HELP_STRING([--disable-xf86vidmode], [Build XF86VidMode extension (default: auto)]), [XF86VIDMODE=$enableval], [XF86VIDMODE=auto]) +AC_ARG_ENABLE(xf86misc, AS_HELP_STRING([--disable-xf86misc], [Build XF86Misc extension (default: auto)]), [XF86MISC=$enableval], [XF86MISC=auto]) AC_ARG_ENABLE(xcsecurity, AS_HELP_STRING([--disable-xcsecurity], [Build Security extension (default: enabled)]), [XCSECURITY=$enableval], [XCSECURITY=yes]) AC_ARG_ENABLE(xevie, AS_HELP_STRING([--disable-xevie], [Build XEvIE extension (default: enabled)]), [XEVIE=$enableval], [XEVIE=yes]) AC_ARG_ENABLE(appgroup, AS_HELP_STRING([--disable-appgroup], [Build XC-APPGROUP extension (default: enabled)]), [APPGROUP=$enableval], [APPGROUP=yes]) @@ -544,10 +544,6 @@ if test "x$XVMC" = xyes; then AC_DEFINE(XvMCExtension, 1, [Build XvMC extension]) fi -AM_CONDITIONAL(DGA, [test "x$DGA" = xyes]) -if test "x$DGA" = xyes; then - AC_DEFINE(DGA, 1, [Support DGA extension]) -fi AM_CONDITIONAL(COMPOSITE, [test "x$COMPOSITE" = xyes]) if test "x$COMPOSITE" = xyes; then @@ -696,14 +692,6 @@ if test "x$DPMSExtension" = xyes; then AC_DEFINE(DPMSExtension, 1, [Support DPMS extension]) fi -if test "x$XF86VIDMODE" = xyes; then - AC_DEFINE(XF86VIDMODE, 1, [Support XFree86 Video Mode extension]) -fi - -if test "x$XF86MISC" = xyes; then - AC_DEFINE(XF86MISC, 1, [Support XFree86 miscellaneous extensions]) -fi - if test "x$XPRINT" = xauto; then PKG_CHECK_MODULES([XPRINTPROTO], [printproto], [XPRINT=yes], [XPRINT=no]) fi @@ -1069,13 +1057,36 @@ if test "x$XORG" = xyes -o "x$XGL" = xyes; then XORG_CFLAGS="$XORGSERVER_CFLAGS -DHAVE_XORG_CONFIG_H" XORG_LIBS="$COMPOSITE_LIB $MI_LIB $FIXES_LIB $XEXTXORG_LIB $GLX_LIBS $RENDER_LIB $RANDR_LIB $DAMAGE_LIB $MIEXT_DAMAGE_LIB $MIEXT_SHADOW_LIB $XI_LIB $XKB_LIB $XPSTUBS_LIB $OS_LIB" - AC_DEFINE(XF86VIDMODE, 1, [Support XFree86 Video Mode extension]) - AC_DEFINE(XF86MISC, 1, [Support XFree86 miscellaneous extensions]) + if test "x$DGA" = xauto; then + PKG_CHECK_MODULES(DGA, dgaproto, [DGA=yes], [DGA=no]) + fi + if test "x$DGA" = xyes; then + XORG_MODULES="$XORG_MODULES xf86dgaproto" + AC_DEFINE(DGA, 1, [Support DGA extension]) + AC_DEFINE(XFreeXDGA, 1, [Build XDGA support]) + fi + + if test "x$XF86MISC" = xauto; then + PKG_CHECK_MODULES(XF86MISC, xf86miscproto, [XF86MISC=yes], [XF86MISC=no]) + fi + if test "x$XF86MISC" = xyes; then + XORG_MODULES="$XORG_MODULES xf86miscproto" + AC_DEFINE(XF86MISC, 1, [Support XFree86 miscellaneous extensions]) + fi - XORG_MODULES="xf86miscproto xf86vidmodeproto xf86dgaproto" - PKG_CHECK_MODULES(XORG_MODULES, [$XORG_MODULES]) - XORG_CFLAGS="$XORG_CFLAGS $XORG_MODULES_CFLAGS" - XORG_LIBS="$XORG_LIBS $XORG_MODULES_LIBS" + if test "x$XF86VIDMOE" = xauto; then + PKG_CHECK_MODULES(XF86VIDMODE, xf86vidmode, [DGA=yes], [DGA=no]) + fi + if test "x$XF86VIDMODE" = xyes; then + XORG_MODULES="$XORG_MODULES xf86vidmodeproto" + AC_DEFINE(XF86VIDMODE, 1, [Support XFree86 Video Mode extension]) + fi + + if test -n "$XORG_MODULES"; then + PKG_CHECK_MODULES(XORG_MODULES, [$XORG_MODULES]) + XORG_CFLAGS="$XORG_CFLAGS $XORG_MODULES_CFLAGS" + XORG_LIBS="$XORG_LIBS $XORG_MODULES_LIBS" + fi dnl Check to see if dlopen is in default libraries (like Solaris, which dnl has it in libc), or if libdl is needed to get it. @@ -1312,6 +1323,7 @@ AM_CONDITIONAL([SOLARIS_ASM_INLINE], [test "x$solaris_asm_inline" = xyes]) AM_CONDITIONAL(MFB, [test "x$XORG" = xyes]) AM_CONDITIONAL(CFB, [test "x$XORG" = xyes]) AM_CONDITIONAL(AFB, [test "x$XORG" = xyes]) +AM_CONDITIONAL(DGA, [test "x$DGA" = xyes]) dnl Xprint DDX @@ -1572,7 +1584,6 @@ AC_DEFINE_DIR(XKM_OUTPUT_DIR, XKBOUTPUT, [Path to XKB output dir]) AC_SUBST(XKB_COMPILED_DIR) dnl and the rest of these are generic, so they're in config.h -AC_DEFINE(XFreeXDGA, 1, [Build XDGA support]) AC_DEFINE(XResExtension, 1, [Build XRes extension]) dnl CYGWIN does not define fd_set if _POSIX_SOURCE is defined |