aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2014-12-15 10:44:20 +0000
committerWerner Koch <[email protected]>2014-12-15 10:44:20 +0000
commit754a987f6df59e2ba0e69aada65ae4aaf593c148 (patch)
treeb1140ed7ae2de6dcb9342aa175b9e72a22e7701c
parentAdd GPG_ERR_OBJ_TERM_STATE. (diff)
downloadlibgpg-error-754a987f6df59e2ba0e69aada65ae4aaf593c148.tar.gz
libgpg-error-754a987f6df59e2ba0e69aada65ae4aaf593c148.zip
Add configure option --disable-doc
* Makefile.am (doc) [!BUILD_DOC]: Do not recurse into doc/. * configure.ac (BUILD_DOC): New am_conditional and new option. -- We have this option already for GnuPG and should use it for all projects. Embedded platforms usually do not require documentation and being able to disable the building avoids a lot of build dependencies. Suggested-by: Hans-Christoph Steiner <[email protected]>
-rw-r--r--Makefile.am8
-rw-r--r--configure.ac11
2 files changed, 16 insertions, 3 deletions
diff --git a/Makefile.am b/Makefile.am
index c6edd12..42cd0c4 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -33,7 +33,13 @@ else
lang_subdirs =
endif
-SUBDIRS = m4 src doc tests po $(lang_subdirs)
+if BUILD_DOC
+doc = doc
+else
+doc =
+endif
+
+SUBDIRS = m4 src $(doc) tests po $(lang_subdirs)
dist-hook: gen-ChangeLog
diff --git a/configure.ac b/configure.ac
index 9683c81..27fda63 100644
--- a/configure.ac
+++ b/configure.ac
@@ -508,10 +508,17 @@ AC_DEFINE_UNQUOTED(BUILD_TIMESTAMP, "$BUILD_TIMESTAMP",
-AC_ARG_ENABLE(languages,
-[ --disable-languages do not build support for other languages than C])
+AC_ARG_ENABLE(languages, AC_HELP_STRING([--disable-languages],
+ [do not build support for other languages than C]))
AM_CONDITIONAL([LANGUAGES_SOME], [test "x$enable_languages" != xno])
+build_doc=yes
+AC_ARG_ENABLE([doc], AC_HELP_STRING([--disable-doc],
+ [do not build the documentation]),
+ build_doc=$enableval, build_doc=yes)
+AM_CONDITIONAL([BUILD_DOC], [test "x$enable_languages" != xno])
+
+
#
# Substitution
#