[gvfs] build: Add --disable-documentation option



commit f746c4488961851df9a0f11e04511693e427dd03
Author: Colin Walters <walters verbum org>
Date:   Sat Jun 30 10:52:25 2012 -0400

    build: Add --disable-documentation option
    
    Some embedded users may not want it, and for gnome-ostree right now I
    don't have the Docbook infrastrucutre set up.

 Makefile.am  |    5 ++++-
 configure.ac |   12 +++++++++++-
 2 files changed, 15 insertions(+), 2 deletions(-)
---
diff --git a/Makefile.am b/Makefile.am
index fc351f6..f013a7d 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -8,10 +8,13 @@ SUBDIRS = \
 	monitor \
 	po   \
 	programs \
-	man \
 	test \
 	$(NULL)
 
+if BUILD_DOCUMENTATION
+SUBDIRS += man
+endif
+
 ACLOCAL_AMFLAGS = ${ACLOCAL_FLAGS}
 
 DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc
diff --git a/configure.ac b/configure.ac
index 763d539..8f89621 100644
--- a/configure.ac
+++ b/configure.ac
@@ -19,7 +19,17 @@ AC_PATH_PROG(PKG_CONFIG, pkg-config, no)
 AC_PATH_PROG(GIO_QUERYMODULES, gio-querymodules, no)
 AM_PROG_CC_C_O
 AC_PROG_SED
-AC_PATH_PROG(XSLTPROC, xsltproc, no)
+AC_ARG_ENABLE(documentation,
+              AC_HELP_STRING([--enable-documentation],
+                             [build documentation]),,
+              enable_documentation=yes)
+if test x$enable_documentation = xyes; then
+   AC_PATH_PROG([XSLTPROC], [xsltproc])
+   if test x$XSLTPROC = x; then
+      AC_MSG_ERROR([xsltproc is required to build documentation])
+   fi
+fi
+AM_CONDITIONAL(BUILD_DOCUMENTATION, test x$enable_documentation = xyes)
 
 m4_ifdef([AM_SILENT_RULES],[AM_SILENT_RULES([yes])])
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]