configure.in
changeset 4577 87a2d87786d4
parent 4454 be387681d876
child 4604 d7535d7a40ea
     1.1 --- a/configure.in	Sun May 30 20:06:30 2010 +0530
     1.2 +++ b/configure.in	Mon May 31 13:27:27 2010 +0530
     1.3 @@ -1128,16 +1128,13 @@
     1.4                                  ])
     1.5                  if test x$have_xrandr_h_hdr = xyes; then
     1.6                      if test x$enable_x11_shared = xyes && test x$xrandr_lib != x ; then
     1.7 -                        echo "-- dynamic libXrender -> $xrender_lib"
     1.8                          echo "-- dynamic libXrandr -> $xrandr_lib"
     1.9 -                        AC_DEFINE_UNQUOTED(SDL_VIDEO_DRIVER_X11_DYNAMIC_XRENDER, "$xrender_lib")
    1.10                          AC_DEFINE_UNQUOTED(SDL_VIDEO_DRIVER_X11_DYNAMIC_XRANDR, "$xrandr_lib")
    1.11                          definitely_enable_video_x11_xrandr=yes
    1.12                      else
    1.13 -                        AC_CHECK_LIB(Xrender, XRenderQueryExtension, have_xrender_lib=yes)
    1.14                          AC_CHECK_LIB(Xrandr, XRRQueryExtension, have_xrandr_lib=yes)
    1.15 -                        if test x$have_xrender_lib = xyes && test x$have_xrandr_lib = xyes ; then
    1.16 -                            EXTRA_LDFLAGS="$EXTRA_LDFLAGS -lXrandr -lXrender"
    1.17 +                        if test x$have_xrandr_lib = xyes ; then
    1.18 +                            EXTRA_LDFLAGS="$EXTRA_LDFLAGS -lXrandr"
    1.19                              definitely_enable_video_x11_xrandr=yes
    1.20                          fi
    1.21                      fi
    1.22 @@ -1199,6 +1196,32 @@
    1.23              if test x$definitely_enable_video_x11_scrnsaver = xyes; then
    1.24                  AC_DEFINE(SDL_VIDEO_DRIVER_X11_SCRNSAVER)
    1.25              fi
    1.26 +            AC_ARG_ENABLE(video-x11-xrender,
    1.27 +AC_HELP_STRING([--enable-video-x11-xrender], [enable X11 Xrender extension [[default=yes]]]),
    1.28 +                            , enable_video_x11_xrender=yes)
    1.29 +            if test x$enable_video_x11_xrender = xyes; then
    1.30 +                AC_CHECK_HEADER(X11/extensions/Xrender.h,
    1.31 +                                have_xrender_h_hdr=yes,
    1.32 +                                have_xrender_h_hdr=no,
    1.33 +                                [#include <X11/Xlib.h>
    1.34 +                                ])
    1.35 +                if test x$have_xrender_h_hdr = xyes; then
    1.36 +                    if test x$enable_x11_shared = xyes && test x$xrender_lib != x ; then
    1.37 +                        echo "-- dynamic libXrender -> $xrender_lib"
    1.38 +                        AC_DEFINE_UNQUOTED(SDL_VIDEO_DRIVER_X11_DYNAMIC_XRENDER, "$xrender_lib")
    1.39 +                        definitely_enable_video_x11_xrender=yes
    1.40 +                    else
    1.41 +                        AC_CHECK_LIB(Xrender, XRenderQueryExtension, have_xrender_lib=yes)
    1.42 +                        if test x$have_xrender_lib = xyes ; then
    1.43 +                            EXTRA_LDFLAGS="$EXTRA_LDFLAGS -lXrender"
    1.44 +                            definitely_enable_video_x11_xrender=yes
    1.45 +                        fi
    1.46 +                    fi
    1.47 +                fi
    1.48 +            fi
    1.49 +            if test x$definitely_enable_video_x11_xrender = xyes; then
    1.50 +                AC_DEFINE(SDL_VIDEO_DRIVER_X11_XRENDER)
    1.51 +            fi
    1.52  
    1.53              AC_ARG_ENABLE(render-x11,
    1.54  AC_HELP_STRING([--enable-render-x11], [enable the X11 render driver [[default=yes]]]),