Skip to content

Commit

Permalink
fix python library for 3.10+ (#48)
Browse files Browse the repository at this point in the history
use sed to filter out major version and compare minor versions directly
  • Loading branch information
koysean authored Sep 27, 2023
1 parent c209a04 commit 5aa0d93
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion config/x_ac_python.m4
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,9 @@ AC_DEFUN([X_AC_PYTHON], [
AC_MSG_CHECKING([Python version])
python_version=`$PYTHON -c "import distutils.sysconfig; \
print(distutils.sysconfig.get_python_version());"`
python_minor_version=`echo $python_version | sed 's/.*\.\(.*\)/\1/'`
if test $python_version '>' 2.99 ; then
if test $python_version '<' 3.8 ; then
if test $python_minor_version -lt 8 ; then
m="m"
python_version=$python_version$m
else
Expand Down

0 comments on commit 5aa0d93

Please sign in to comment.