Skip to content

Commit

Permalink
ax_python_devel: check success of import by return code rather than b…
Browse files Browse the repository at this point in the history
…y stderr

In Python 3.7, when you have C locale it will be automatically coerced
to C.UTF-8 and warning will be printed to stderr. This breaks AX_PYTHON_DEVEL.

Signed-off-by: Igor Gnatenko <ignatenko@redhat.com>
  • Loading branch information
Igor Gnatenko committed Mar 14, 2017
1 parent 4d7ae62 commit 883a2ab
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions m4/ax_python_devel.m4
Expand Up @@ -67,7 +67,7 @@
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.

#serial 19
#serial 20

AU_ALIAS([AC_PYTHON_DEVEL], [AX_PYTHON_DEVEL])
AC_DEFUN([AX_PYTHON_DEVEL],[
Expand Down Expand Up @@ -137,7 +137,7 @@ variable to configure. See ``configure --help'' for reference.
#
AC_MSG_CHECKING([for the distutils Python package])
ac_distutils_result=`$PYTHON -c "import distutils" 2>&1`
if test -z "$ac_distutils_result"; then
if test $? -eq 0; then
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])
Expand Down

0 comments on commit 883a2ab

Please sign in to comment.