[Openchrome-devel] [PATCH 2/2] Remove --(enable|disable)-dri configure option, it depends on whether the X server was built with or w/o DRI support.

James Simmons jsimmons
Wed Aug 1 15:00:38 PDT 2012



On Mon, 30 Jul 2012, Xavier Bachelot wrote:

> ---
>  configure.ac | 45 ++++++++++++++++++---------------------------
>  1 file changed, 18 insertions(+), 27 deletions(-)

Acked-by: James Simmons <jsimmons at infradead.org>

Tested it and had no problems. Please apply to the git repo.


 
> diff --git a/configure.ac b/configure.ac
> index 9f4cf3b..f98d13a 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -64,11 +64,6 @@ AC_ARG_WITH(xorg-module-dir,
>              [moduledir="$withval"],
>              [moduledir="$libdir/xorg/modules"])
>  -AC_ARG_ENABLE(dri, AC_HELP_STRING([--disable-dri],
> -                                  [Disable DRI support [[default=auto]]]),
> -              [DRI="$enableval"],
> -              [DRI=auto])
> -
>  AC_ARG_ENABLE(debug, AC_HELP_STRING([--enable-debug],
>  				    [Enable debugging support [[default=no]]]),
>                [DEBUG="$enableval"],
> @@ -115,33 +110,29 @@ if test x$XSERVER_LIBPCIACCESS = xyes; then
>         PKG_CHECK_MODULES([PCIACCESS], [pciaccess >= 0.8.0])
>  fi
>  -if test "$DRI" != no; then
> -        PKG_CHECK_MODULES(DRI, [libdrm >= 2.0 xf86driproto])
> -        save_CPPFLAGS="$CPPFLAGS"
> -        CPPFLAGS="$XORG_CFLAGS $DRI_CFLAGS"
> -        AC_CHECK_HEADER([dri.h],
> -                      [have_dri_h="yes"], [have_dri_h="no"],[-])
> -        AC_CHECK_HEADER([sarea.h],
> -                      [have_sarea_h="yes"], [have_sarea_h="no"],[-])
> +PKG_CHECK_MODULES(DRI, [libdrm >= 2.0 xf86driproto])
> +save_CPPFLAGS="$CPPFLAGS"
> +CPPFLAGS="$XORG_CFLAGS $DRI_CFLAGS"
> +AC_CHECK_HEADER([dri.h],
> +              [have_dri_h="yes"], [have_dri_h="no"],[-])
> +AC_CHECK_HEADER([sarea.h],
> +              [have_sarea_h="yes"], [have_sarea_h="no"],[-])
>  AC_PREPROC_IFELSE([AC_LANG_PROGRAM([[
>  #include <xorg-server.h>
>  #include <dristruct.h>
> -                      ]])],
> -                      [have_dristruct_h="yes"],
> [have_dristruct_h="no"],[-])
> -        AC_CHECK_HEADER([damage.h],
> -                      [have_damage_h="yes"], [have_damage_h="no"],[-])
> -        CPPFLAGS="$save_CPPFLAGS"
> -fi
> +              ]])],
> +              [have_dristruct_h="yes"], [have_dristruct_h="no"],[-])
> +AC_CHECK_HEADER([damage.h],
> +              [have_damage_h="yes"], [have_damage_h="no"],[-])
> +CPPFLAGS="$save_CPPFLAGS"
>   AC_MSG_CHECKING([whether to include DRI support])
> -if test x$DRI = xauto; then
> -        if test "$have_dri_h" = yes -a \
> -                "$have_sarea_h" = yes -a \
> -                "$have_dristruct_h" = yes; then
> -                DRI="yes"
> -        else
> -                DRI="no"
> -        fi
> +if test "$have_dri_h" = yes -a \
> +        "$have_sarea_h" = yes -a \
> +        "$have_dristruct_h" = yes; then
> +        DRI="yes"
> +else
> +        DRI="no"
>  fi
>  AC_MSG_RESULT([$DRI])
>  -- 1.7.11.2
> 
> 




More information about the Openchrome-devel mailing list