From c44f82cf4ce08e0f307a6ce6753049269bb968b4 Mon Sep 17 00:00:00 2001 From: Jason Ish Date: Thu, 10 Oct 2019 16:32:21 -0600 Subject: [PATCH] configure: fix python major version check on python 2.6 Python 2.6 doesn't use a named tuple for the version info, instead use the index of the major version which works on Python 2.6 upwards. --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 0f7abcb303..ef96ddfc2c 100644 --- a/configure.ac +++ b/configure.ac @@ -124,7 +124,7 @@ # Get the Python major version. This is only for information # messages displayed during configure. if test "x$HAVE_PYTHON" != "xno"; then - pymv="$($HAVE_PYTHON -c 'import sys; print(sys.version_info.major);')" + pymv="$($HAVE_PYTHON -c 'import sys; print(sys.version_info[[0]]);')" fi # Check for python-distutils (setup). -- 2.47.2