[cogl] build: Allow to compile a git checkout without gtk-doc



commit dc5d3785f6f0f00f39b25285d9c54f17582e4063
Author: Damien Lespiau <damien lespiau intel com>
Date:   Thu May 12 11:07:30 2011 +0100

    build: Allow to compile a git checkout without gtk-doc
    
    Gtk-doc can be hard to install on Windows. This patch enables people wanting to
    hack on Cogl itself from a Windows system to do so without the hassle to get
    gtk-doc installed first.

 autogen.sh                         |   13 +++++++------
 configure.ac                       |    3 ++-
 doc/reference/cogl-2.0/Makefile.am |    3 ++-
 doc/reference/cogl/Makefile.am     |    3 ++-
 4 files changed, 13 insertions(+), 9 deletions(-)
---
diff --git a/autogen.sh b/autogen.sh
index 6ca0de2..3f010ff 100755
--- a/autogen.sh
+++ b/autogen.sh
@@ -30,11 +30,9 @@ ECT."
 fi
 
 (gtkdocize --version) < /dev/null > /dev/null 2>&1 || {
-	echo
-	echo "You must have gtk-doc installed to compile $PROJECT."
-	echo "Install the appropriate package for your distribution,"
-	echo "or get the source tarball at http://ftp.gnome.org/pub/GNOME/sources/gtk-doc/";
-        exit 1
+	echo "You don't have gtk-doc installed to compile $PROJECT, and thus"
+	echo "won't be able to generate the $PROJECT documentation."
+	NOGTKDOC=1
 }
 
 # NOCONFIGURE is used by gnome-common
@@ -63,7 +61,10 @@ fi
 
 rm -rf autom4te.cache
 
-gtkdocize || exit $?
+if test -z "$NOGTKDOC"; then
+	gtkdocize || exit $?
+fi
+
 autoreconf -vfi || exit $?
 cd $ORIGDIR || exit $?
 
diff --git a/configure.ac b/configure.ac
index baa4109..1d36b43 100644
--- a/configure.ac
+++ b/configure.ac
@@ -697,7 +697,8 @@ AS_ALL_LINGUAS
 dnl ================================================================
 dnl Documentation stuff.
 dnl ================================================================
-GTK_DOC_CHECK([gtk_doc_req_version], [--flavour no-tmpl])
+m4_ifdef([GTK_DOC_CHECK],
+         [GTK_DOC_CHECK([gtk_doc_req_version], [--flavour no-tmpl])])
 AM_CONDITIONAL([BUILD_GTK_DOC], [test "x$enable_gtk_doc" = "xyes"])
 
 dnl ================================================================
diff --git a/doc/reference/cogl-2.0/Makefile.am b/doc/reference/cogl-2.0/Makefile.am
index ce5b8da..0c835fe 100644
--- a/doc/reference/cogl-2.0/Makefile.am
+++ b/doc/reference/cogl-2.0/Makefile.am
@@ -141,7 +141,8 @@ INCLUDES=-I$(top_srcdir) -I$(top_builddir)/cogl -DCOGL_ENABLE_EXPERIMENTAL_API $
 GTKDOC_LIBS=$(top_builddir)/cogl/libcogl.la $(COGL_DEP_LIBS)
 
 # This includes the standard gtk-doc make rules, copied by gtkdocize.
-include $(top_srcdir)/gtk-doc.make
+EXTRA_DIST =
+-include $(top_srcdir)/gtk-doc.make
 
 # Other files to distribute
 # e.g. EXTRA_DIST += version.xml.in
diff --git a/doc/reference/cogl/Makefile.am b/doc/reference/cogl/Makefile.am
index 05be7ad..8b00b8a 100644
--- a/doc/reference/cogl/Makefile.am
+++ b/doc/reference/cogl/Makefile.am
@@ -138,7 +138,8 @@ INCLUDES=-I$(top_srcdir) -I$(top_builddir)/cogl -DCOGL_ENABLE_EXPERIMENTAL_API $
 GTKDOC_LIBS=$(top_builddir)/cogl/libcogl.la $(COGL_DEP_LIBS)
 
 # This includes the standard gtk-doc make rules, copied by gtkdocize.
-include $(top_srcdir)/gtk-doc.make
+EXTRA_DIST =
+-include $(top_srcdir)/gtk-doc.make
 
 # Other files to distribute
 # e.g. EXTRA_DIST += version.xml.in



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