From: Jason Ish Date: Wed, 9 Oct 2019 04:56:35 +0000 (-0600) Subject: configure: detect python major version X-Git-Tag: suricata-5.0.0~29 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=c4b856ea9922fa52e039aa6f843bc8ad9d526bd3;p=thirdparty%2Fsuricata.git configure: detect python major version For informational purposes only when notifying what Python modules are required during ./configure. --- diff --git a/configure.ac b/configure.ac index 2405fed497..188c928875 100644 --- a/configure.ac +++ b/configure.ac @@ -121,6 +121,12 @@ fi AM_CONDITIONAL([HAVE_PYTHON], [test "x$enable_python" = "xyes"]) + # 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);')" + fi + # Check for python-distutils (setup). have_python_distutils="no" if test "x$enable_python" = "xyes"; then @@ -139,7 +145,7 @@ echo " Warning: Python distutils not found. Python tools will" echo " not be installed." echo "" - echo " Ubuntu/Debian: apt install `basename ${HAVE_PYTHON}`-distutils" + echo " Please install the distutils module for Python ${pymv}." echo "" fi