summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2015-10-23 12:27:35 +0200
committerBen Gamari <ben@smart-cactus.org>2015-10-23 17:43:55 +0200
commit7dae0743c8162021fa4d11c33c89b43e3e568991 (patch)
tree1c314395a08b90a203a67a15ee4e43486a5ce9b8 /configure.ac
parentfd63ea5686fe5b856c3ebdc5f28bf7a2547bd96f (diff)
downloadhaskell-7dae0743c8162021fa4d11c33c89b43e3e568991.tar.gz
Verify minimum required version of sphinx-build
CentOS 6.6 includes sphinx-build 0.6.6 which is woefully inadequate to build the users guide. In particular it fails as it lacks `sphinx.ext.extlinks`, which was introduced in 1.0.0. Looking at the changelog it appears that 1.0.0 ought to work.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac9
1 files changed, 9 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 6b01076898..925846a3a9 100644
--- a/configure.ac
+++ b/configure.ac
@@ -772,6 +772,15 @@ fi
dnl ** check for Sphinx toolchain
AC_PATH_PROG(SPHINXBUILD,sphinx-build)
+AC_CACHE_CHECK([for version of sphinx-build], sphinx_version,
+changequote(, )dnl
+[if test -n "$SPHINXBUILD"; then
+ sphinx_version=`"$SPHINXBUILD" --version | sed 's/Sphinx (sphinx-build) \([0-9]\.[0-9]\.[0-9]\)/\1/'`;
+fi;
+changequote([, ])dnl
+])
+FP_COMPARE_VERSIONS([$sphinx_version],-lt,1.0.0,
+ [AC_MSG_ERROR([Sphinx version 1.0.0 or later is required to build documentation]); SPHINXBUILD=;])
dnl ** check for xelatex
AC_PATH_PROG(XELATEX,xelatex)