bpo-21536: Fix configure.ac for LIBPYTHON on Android/Cygwin (GH-13552)
authorE. M. Bray <erik.bray@lri.fr>
Fri, 24 May 2019 16:39:39 +0000 (18:39 +0200)
committerVictor Stinner <vstinner@redhat.com>
Fri, 24 May 2019 16:39:38 +0000 (18:39 +0200)
Add also missing AC_MSG_RESULT for AC_MSG_CHECKING(MACHDEP).

configure
configure.ac

index c76eb7affe54be2c4c29d452362e05939e7e9831..bc276ac58362bffa5ad8cd61b07e742f8f5cd271 100755 (executable)
--- a/configure
+++ b/configure
@@ -3292,6 +3292,8 @@ then
        '')     MACHDEP="unknown";;
     esac
 fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: \"$MACHDEP\"" >&5
+$as_echo "\"$MACHDEP\"" >&6; }
 
 
 if test "$cross_compiling" = yes; then
@@ -15131,10 +15133,10 @@ $as_echo "$LDVERSION" >&6; }
 
 # On Android and Cygwin the shared libraries must be linked with libpython.
 
-if test -z "$ANDROID_API_LEVEL" -o "$MACHDEP" != "cygwin"; then
-  LIBPYTHON=''
-else
+if test -n "$ANDROID_API_LEVEL" -o "$MACHDEP" = "cygwin"; then
   LIBPYTHON="-lpython${VERSION}${ABIFLAGS}"
+else
+  LIBPYTHON=''
 fi
 
 
index 99d99ae55c17f31359f6420b3a6ae367de59a185..5e565191f27de155150f962387f3c6de4dc22f93 100644 (file)
@@ -411,6 +411,7 @@ then
        '')     MACHDEP="unknown";;
     esac
 fi
+AC_MSG_RESULT("$MACHDEP")
 
 AC_SUBST(_PYTHON_HOST_PLATFORM)
 if test "$cross_compiling" = yes; then
@@ -4622,10 +4623,10 @@ AC_MSG_RESULT($LDVERSION)
 
 # On Android and Cygwin the shared libraries must be linked with libpython.
 AC_SUBST(LIBPYTHON)
-if test -z "$ANDROID_API_LEVEL" -o "$MACHDEP" != "cygwin"; then
-  LIBPYTHON=''
-else
+if test -n "$ANDROID_API_LEVEL" -o "$MACHDEP" = "cygwin"; then
   LIBPYTHON="-lpython${VERSION}${ABIFLAGS}"
+else
+  LIBPYTHON=''
 fi
 
 dnl define LIBPL after ABIFLAGS and LDVERSION is defined.