diff --git a/configure.ac b/configure.ac index c293b69..c8c476b 100644 --- a/configure.ac +++ b/configure.ac @@ -83,6 +83,9 @@ fi AM_CONDITIONAL([FBSD], [test "$bfbsd" = "yes"]) AC_SUBST(FBSD) +AC_ARG_WITH([python3], [AS_HELP_STRING([--with-python3], [use python3])], + [with_python3="yes"],[]) + # Checks for libraries. GLIB_REQUIRED=2.26.0 @@ -98,10 +101,10 @@ PKG_CHECK_MODULES(JANSSON, [jansson >= $JANSSON_REQUIRED]) AC_SUBST(JANSSON_CFLAGS) AC_SUBST(JANSSON_LIBS) -if test "$bwin32" = "true" -o "$bmac" = "yes"; then - AM_PATH_PYTHON([2.7]) -else +if test "$with_python3" = "yes"; then AM_PATH_PYTHON([3.5]) +else + AM_PATH_PYTHON([2.7]) fi if test "$bwin32" = true; then diff --git a/debian/rules b/debian/rules index d722d66..6a71479 100755 --- a/debian/rules +++ b/debian/rules @@ -6,7 +6,7 @@ override_dh_auto_configure: ./autogen.sh - dh_auto_configure -- --disable-compile-demo + dh_auto_configure -- --disable-compile-demo --with-python3 override_dh_strip: # emptying the dependency_libs field in .la files