summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: b80324b)
raw | patch | inline | side by side (parent: b80324b)
author | Sebastian Harl <sh@tokkee.org> | |
Sat, 31 Dec 2011 00:09:51 +0000 (01:09 +0100) | ||
committer | Sebastian Harl <sh@tokkee.org> | |
Sat, 31 Dec 2011 00:09:51 +0000 (01:09 +0100) |
If these tools are not found, don't try to build the documentation.
Makefile.am | patch | blob | history | |
configure.ac | patch | blob | history | |
doc/Makefile.am | patch | blob | history |
diff --git a/Makefile.am b/Makefile.am
index 61071f03dad38405667f8d2635f094a43ef8b70d..28f1bbd0bb83939af34817a582ae1c6f7b31657e 100644 (file)
--- a/Makefile.am
+++ b/Makefile.am
-SUBDIRS = doc src
+SUBDIRS = src
+if BUILD_DOCUMENTATION
+SUBDIRS += doc
+endif
EXTRA_DIST = autogen.sh version-gen.sh
diff --git a/configure.ac b/configure.ac
index ec99e903390ef841bc809b4c89498bf395685c3e..3ef87037520f52fbe3f297fc50233231558b7783 100644 (file)
--- a/configure.ac
+++ b/configure.ac
AC_CHECK_HEADERS(libgen.h)
dnl Check for dependencies.
+build_documentation="yes"
+
+have_xsltproc="yes"
+AC_PATH_PROG([XSLTPROC], [xsltproc])
+if test "x$XSLTPROC" = "x"; then
+ have_xsltproc="no"
+ build_documentation="no (missing xsltproc)"
+fi
+
+have_a2x="yes"
+AC_PATH_PROG([A2X], [a2x])
+if test "x$A2X" = "x"; then
+ have_a2x="no"
+ build_documentation="no (missing a2x)"
+fi
+AC_SUBST([A2X])
+
+AM_CONDITIONAL([BUILD_DOCUMENTATION], test "x$build_documentation" = "xyes")
+
PKG_CHECK_MODULES([CAIRO], [cairo])
PKG_CHECK_MODULES([GTK2], [gtk+-2.0])
PKG_CHECK_MODULES([POPPLER_GLIB], [poppler-glib])
package version: $PACKAGE_VERSION
build date: `date --utc '+%F %T'` (UTC)
+ Tools:
+ AsciiDoc (a2x): . . . . . . $have_a2x
+ xsltproc: . . . . . . . . . $have_xsltproc
+
Libraries:
libcairo: . . . . . . . . . `$PKG_CONFIG --modversion cairo`
libgtk-2.0: . . . . . . . . `$PKG_CONFIG --modversion gtk+-2.0`
libpoppler-glib: . . . . . `$PKG_CONFIG --modversion poppler-glib`
+ Features:
+ documentation: . . . . . . $build_documentation
+
This package is maintained by $PACKAGE_MAINTAINER.
Please report bugs to $PACKAGE_BUGREPORT.
diff --git a/doc/Makefile.am b/doc/Makefile.am
index 62399e67b2f22d9c96edf991cf9a8e6b16850c4e..c733c61aee8abbfaa42eba8e19376bdb35691161 100644 (file)
--- a/doc/Makefile.am
+++ b/doc/Makefile.am
tpdfview.1: tpdfview.txt ../version
.txt.1:
- a2x -d manpage -f manpage -atpdfv_version=$(PACKAGE_VERSION) $<
+ @A2X@ -d manpage -f manpage -atpdfv_version=$(PACKAGE_VERSION) $<