[Mesa-dev] [PATCH 2/2] configure.ac: Build dricommon when dri is enabled

Daniel Martin consume.noise at gmail.com
Wed Mar 6 01:17:27 PST 2013


On 5 March 2013 19:57, Matt Turner <mattst88 at gmail.com> wrote:
> Commit 67ef7559 added an || test "x$enable_dri" check, which was just
> wrong since the whole block was enclosed in if test "x$enable_dri". The
> comment added with it stated the actual intent: to enable when any DRI
> drivers were built.
> ---
>  configure.ac |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/configure.ac b/configure.ac
> index 925dc6b..a25ec2c 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -1079,7 +1079,7 @@ if test "x$enable_dri" = xyes; then
>      LIBS="$save_LIBS"
>
>      # if we are building any dri driver other than swrast or using the dri state tracker ...
> -    if test -n "$DRI_DIRS" -a x"$DRI_DIRS" != xswrast; then
> +    if test -n "$DRI_DIRS" -a "x$DRI_DIRS" != xswrast -o "x$HAVE_ST_DRI" = xyes; then

With this, the inner if-clause will always be choosen, as HAVE_ST_DRI
will be set to 'yes' somewhere above if 'enable_dri'. This prevents to
build swrast_dri only without libdrm.

Would it be possible to move the "dnl Gallium drivers" block above the
"dnl Set DRI_DIRS, DEFINES and LIB_DEPS" block, set an additional
"NEED_DRI_COMMON" where necessary and change the line to:
    if test -n "$DRI_DIRS" -a "x$DRI_DIRS" != xswrast -o
"x$NEED_DRI_COMMON" = xyes;

>          # ... libdrm is required
>          if test "x$have_libdrm" != xyes; then
>              AC_MSG_ERROR([DRI drivers requires libdrm >= $LIBDRM_REQUIRED])
> --
> 1.7.8.6


More information about the mesa-dev mailing list