From 7a34fda7dcdc90214ee99ae5c616e8c7dc8e784e Mon Sep 17 00:00:00 2001 From: John Cupitt Date: Wed, 24 Nov 2021 18:43:19 +0000 Subject: [PATCH] add some tests to autogen.sh error from aytogen.sh if gtk-doc or goi are missing see https://github.com/libvips/libvips/issues/2554 --- autogen.sh | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/autogen.sh b/autogen.sh index e48c5cc1..fbb61f8c 100755 --- a/autogen.sh +++ b/autogen.sh @@ -9,10 +9,25 @@ olddir=$(pwd) cd $srcdir (test -f configure.ac) || { - echo "*** ERROR: Directory '$srcdir' does not look like the top-level project directory ***" + echo "*** ERROR: Directory '$srcdir' does not look like" >&2 + echo "*** like the top-level project directory" >&2 exit 1 } +if ! gtkdocize --version > /dev/null; then + echo "*** ERROR: You must have gtkdocize installed" >&2 + echo "*** to be able to reconfigure libvips." >&2 + exit 1 +fi + +# this will only detect the most basic kind of missing gio error, +# hopefully that's enough to catch this most times +if ! pkg-config gobject-introspection-1.0 --exists; then + echo "*** ERROR: You must have gobject-introspection installed" >&2 + echo "*** to be able to reconfigure libvips." >&2 + exit 1 +fi + # shellcheck disable=SC2016 PKG_NAME=$(autoconf --trace 'AC_INIT:$1' configure.ac)