[Mesa-dev] [PATCH v2 3/5] configure: Enforce python 2.7.x

Eric Engestrom eric.engestrom at intel.com
Thu Aug 16 10:19:23 UTC 2018


On Wednesday, 2018-08-15 09:18:06 -0700, Dylan Baker wrote:
> We don't want to support older versions of python 2 anymore, and we
> don't support python 3.x in autotools currently.

Reviewed-by: Eric Engestrom <eric.engestrom at intel.com>

> ---
>  configure.ac | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/configure.ac b/configure.ac
> index c2155a541b0..78672734d06 100644
> --- a/configure.ac
> +++ b/configure.ac
> @@ -162,6 +162,13 @@ if test -z "$PYTHON2"; then
>          AC_MSG_ERROR([Python not found - unable to generate sources])
>      fi
>  else
> +    PYTHON_VERSION=`$PYTHON2 --version |& awk '{print $2}'`  dnl Yes, python2 prints it's version to stderr
> +    PYTHON_MAJOR=`echo $PYTHON_VERSION | cut -d . -f 1`
> +    PYTHON_MINOR=`echo $PYTHON_VERSION | cut -d . -f 2`
> +    if test $PYTHON_MAJOR -ne 2 -o $PYTHON_MINOR -ne 7; then
> +        AC_MSG_ERROR([Python version 2.7.x not found - unable to generate sources])
> +    fi
> +
>      if test "x$acv_mako_found" = xno; then
>          if test ! -f "$srcdir/src/mesa/main/format_unpack.c"; then
>              AC_MSG_ERROR([Python mako module v$PYTHON_MAKO_REQUIRED or higher not found])
> -- 
> 2.18.0
> 
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev


More information about the mesa-dev mailing list