summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartyn Russell <martyn@lanedo.com>2011-10-03 11:27:37 +0100
committerMartyn Russell <martyn@lanedo.com>2011-10-06 17:33:16 +0100
commit71d7703319136394820217f40f3d73cca3fdb2dd (patch)
treee4aa760ddeb96c07f1927e0290a2d4234d940346
parent04d1f13e2319e5c9d2632f52872ffd402b7dede1 (diff)
downloadtracker-71d7703319136394820217f40f3d73cca3fdb2dd.tar.gz
build: Don't use HAVE_GTK_DOC to determine building docs
Now we use ENABLE_GTK_DOC like other projects and have updated configure according to the latest recommendations from the gtk-doc documentation. Additionally, we only use ENABLE_GTK_DOC to disable building ontology documentation because we use that before detection of the other tools we need when building documentation (such as dia and graphviz). Fixes GB#659995.
-rw-r--r--configure.ac14
-rw-r--r--docs/Makefile.am14
-rw-r--r--docs/reference/Makefile.am6
3 files changed, 26 insertions, 8 deletions
diff --git a/configure.ac b/configure.ac
index f79d50f1a..ab5c9a6f7 100644
--- a/configure.ac
+++ b/configure.ac
@@ -548,11 +548,20 @@ AM_CONDITIONAL(DIST_FUNCTIONAL_TESTS, test "x$enable_functional_tests" != "xno")
# Check for gtk-doc and docbook-tools
####################################################################
+# Check for GTK_DOC_CHECK availability. The GTK_DOC_CHECK invocation
+# must be on its own line, gtkdocize relies on it
+m4_ifdef([GTK_DOC_CHECK], [
GTK_DOC_CHECK([1.8])
-if test "x$enable_gtk_doc" != "xno"; then
- AC_DEFINE(HAVE_GTK_DOC, 1, [Define if we have gtk-doc (with gtk-doc)])
+# NOTE: We need to use a separate automake conditional for this
+# to make this work with the tarballs.
+AM_CONDITIONAL([ENABLE_GTK_DOC], test "x$enable_gtk_doc" = xyes)
+],
+[
+AM_CONDITIONAL([ENABLE_GTK_DOC], false)
+])
+if test "x$enable_gtk_doc" != xno; then
# Check for dia if we are building gtk_doc
AC_PATH_PROG(DIA, dia)
AC_SUBST(DIA)
@@ -570,7 +579,6 @@ if test "x$enable_gtk_doc" != "xno"; then
fi
fi
-AM_CONDITIONAL(HAVE_GTK_DOC, test "$enable_gtk_doc" = "yes")
AM_CONDITIONAL(HAVE_GRAPHVIZ_FDP, test -n "$GRAPHVIZ_FDP")
####################################################################
diff --git a/docs/Makefile.am b/docs/Makefile.am
index 65626260b..ac913b07c 100644
--- a/docs/Makefile.am
+++ b/docs/Makefile.am
@@ -1,7 +1,15 @@
include $(top_srcdir)/Makefile.decl
-SUBDIRS = manpages design
+SUBDIRS = manpages design tools reference
-if HAVE_GTK_DOC
-SUBDIRS += tools reference
+# require gtk-doc when making dist
+#
+if ENABLE_GTK_DOC
+dist-check-gtk-doc:
+else
+dist-check-gtk-doc:
+ @echo "*** gtk-doc must be enabled in order to make dist"
+ @false
endif
+
+dist-hook: dist-check-gtk-doc
diff --git a/docs/reference/Makefile.am b/docs/reference/Makefile.am
index f10d7cd9b..a4158bfbc 100644
--- a/docs/reference/Makefile.am
+++ b/docs/reference/Makefile.am
@@ -4,6 +4,8 @@ SUBDIRS = \
libtracker-sparql \
libtracker-client \
libtracker-extract \
- libtracker-miner \
- ontology
+ libtracker-miner
+if ENABLE_GTK_DOC
+SUBDIRS += ontology
+endif