[Libguestfs] [PATCH] build: define HAVE_PYCODESTYLE in all the cases

Pino Toscano ptoscano at redhat.com
Wed Jan 15 14:38:10 UTC 2020


Fixes commit cad3ea9e74bcff0dd42dc2a3710c6b3fa6e868b1 in case Python is
disabled, or not available.
---
 m4/guestfs-python.m4 | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/m4/guestfs-python.m4 b/m4/guestfs-python.m4
index 505eba5df..2e736875c 100644
--- a/m4/guestfs-python.m4
+++ b/m4/guestfs-python.m4
@@ -88,7 +88,6 @@ AS_IF([test "x$enable_python" != "xno"],[
         AC_MSG_RESULT([$PYTHON_EXT_SUFFIX])
 
         AC_CHECK_PROGS([PYCODESTYLE],[pycodestyle],[no])
-        AM_CONDITIONAL([HAVE_PYCODESTYLE], [test "x$PYCODESTYLE" != "xno"])
     fi
 
     AC_SUBST(PYTHON_PREFIX)
@@ -98,3 +97,5 @@ AS_IF([test "x$enable_python" != "xno"],[
 ])
 AM_CONDITIONAL([HAVE_PYTHON],
     [test "x$PYTHON" != "xno" && test "x$have_python_module" = "x1" ])
+AM_CONDITIONAL([HAVE_PYCODESTYLE],
+    [test -n "$PYCODESTYLE" && test "x$PYCODESTYLE" != "xno"])
-- 
2.24.1




More information about the Libguestfs mailing list