configure.ac: Add check for python3 libs

They are needed since commit
c1e04e4069
("scripts/unocommands.py: Switch to python3"),
so add a corresponding check to configure.ac.

Change-Id: If0f1d2b474c3edb3fc63dc54292acd54f096b822
Reviewed-on: https://gerrit.libreoffice.org/81473
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Michael Weghorn <m.weghorn@posteo.de>
feature/calczoom
Michael Weghorn 2019-10-24 18:35:30 +02:00
parent cdec2c7870
commit f75366bc94
1 changed files with 11 additions and 0 deletions

View File

@ -50,6 +50,17 @@ AS_IF([test `uname -s` = Linux],
AS_IF([test -z "$SETCAP"],
[AC_MSG_ERROR([The setcap command is needed. It might be in a package called libcap-progs.])]))
# check for python modules
for MODULE in lxml polib; do
AC_MSG_CHECKING([for ${MODULE} for python3])
if /usr/bin/env python3 -c "import ${MODULE}" 2> /dev/null ; then
AC_MSG_RESULT([yes])
else
AC_MSG_RESULT([no])
AC_MSG_ERROR([${MODULE} for python3 is needed. It might be in a package called python3-${MODULE}.])
fi
done
# Declare options
AC_ARG_ENABLE([debug],
AS_HELP_STRING([--enable-debug],