[gxml] * fix autotool files and add some stub wiki ones to fix doc generation



commit 0c047444f385c6ca337d3ef2e42c9f857d67c191
Author: Richard Schwarting <aquarichy gmail com>
Date:   Mon Aug 13 15:35:08 2012 -0400

    * fix autotool files and add some stub wiki ones to fix doc generation

 configure.ac                |   14 ++++-----
 docs/Makefile.am            |   60 +++++++++++++++++++++++++++++++++----------
 docs/wiki/concepts.valadoc  |    3 ++
 docs/wiki/debugging.valadoc |    2 +
 docs/wiki/glossary.valadoc  |    1 +
 5 files changed, 58 insertions(+), 22 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index af7f839..bb232e5 100644
--- a/configure.ac
+++ b/configure.ac
@@ -73,11 +73,7 @@ PKG_CHECK_MODULES(GIO, $GIO_MODULES)
 AC_SUBST(GIO_CFLAGS)
 AC_SUBST(GIO_LIBS)
 
-dnl Check for GObject Introspection
-GOBJECT_INTROSPECTION_CHECK([0.6.7])
-
-
-
+dnl Documentation
 AC_ARG_ENABLE([docs],
               AS_HELP_STRING([--enable-docs],[Enable documentation generation]),
 	      [enable_docs=$enableval], [enable_docs=no])
@@ -96,7 +92,8 @@ if test "x$enable_docs" = "xyes" -a "x$have_valadoc" != "xyes"; then
   AC_MSG_ERROR([Doc building requested for valadoc but not installed.])
 fi
 
-
+dnl Check for GObject Introspection
+GOBJECT_INTROSPECTION_CHECK([0.6.7])
 
 AC_ARG_ENABLE([gi-system-install],
     AS_HELP_STRING([--enable-gi-system-install], [Install GObject Introspection files along with system installed files [default=yes]]),
@@ -114,6 +111,7 @@ po/Makefile.in])
 dnl Print configuration summary
 echo ""
 echo " Configuration summary for GXml"
-echo "   Installation prefix = $prefix"
-echo "   Enable GObject Introspection System Install: `if test x$enable_gi_system_install != xno; then echo yes; else echo no; fi`"
+echo "   Installation prefix:                          $prefix"
+echo "   Enable GObject Introspection System Install:  `if test x$enable_gi_system_install != xno; then echo yes; else echo no; fi`"
+echo "   Documentation:                                ${have_valadoc}"
 echo ""
diff --git a/docs/Makefile.am b/docs/Makefile.am
index a04e74c..1da70cd 100644
--- a/docs/Makefile.am
+++ b/docs/Makefile.am
@@ -1,7 +1,16 @@
 # inspired by folks' documentation Makefile.am
 
 # distclean_dirs? 
-# phony_deps? 
+# phony_deps?
+distclean_dirs = \
+	gxml \
+	gtk-doc \
+	$(NULL)
+
+phony_deps = \
+	gxml-doc \
+	gxml-gtk-doc \
+	$(NULL)
 
 gxml_wiki_pages = \
 	concepts \
@@ -12,13 +21,14 @@ gxml_wiki_pages = \
 # Huh, gxml_wiki_files isn't defined for a while down below
 EXTRA_DIST = $(gxml_wiki_files)
 
+
+
 # ---------------------------------------------------------
 
 gxmldocdir=$(datadir)/devhelp/references/gxml
 gxmlimgdir=$(datadir)/devhelp/references/gxml/img
 
 gxmlgtkdocdir=$(datadir)/gtk-doc/html/gxml
-# gxmlgtkimgdir=$(datadir)/gtk-doc/html/gxml/img
 
 common_doc_files = \
 	*.css \
@@ -28,16 +38,22 @@ common_doc_files = \
 	*.html \
 	$(NULL)
 
-$(gxmldoc_DATA): gxml-docs
-# $(gxmldoc_DATA) ($gxmlimg_DATA): gxml-docs
+gxmldoc_DATA = \
+	gxml/gxml/gxml.devhelp2 \
+	$(addprefix gxml/gxml/,$(common_doc_files)) \
+	$(NULL)
+
+gxmlgtkdoc_DATA = gtk-doc/gxml/html/*
+
+# gxmlimg_DATA = gxml/gxml/img/*.png
+
+# $(gxmldoc_DATA) ($gxmlimg_DATA): gxml-doc
+$(gxmldoc_DATA): gxml-doc
 $(gxmlgtkdoc_DATA): gxml-gtk-doc
 
 
 # -------------------------------------------------------
 
-# to define:
-# top_builddir AM_V_GEN VALADOC top_srcdir addprefix? PACKAGE_VERSION
-
 valadoc_flags = \
 	--force \
 	--package-version $(PACKAGE_VERSION) \
@@ -47,12 +63,13 @@ valadoc_flags = \
 gxml_doc_files_blacklist = \
 	$(NULL)
 
+# this expands the list of files, so we can filter out elements
 gxml_doc_files_all = \
-	$(wildcard $(top_srcdir)/folks/*.vala) \
+	$(wildcard $(top_srcdir)/gxml/*.vala) \
 	$(NULL)
 
 gxml_wiki_files = \
-	$(addprefix wiki/,$(addsuffix .valadoc,$(folks_wiki_pages))) \
+	$(addprefix wiki/,$(addsuffix .valadoc,$(gxml_wiki_pages))) \
 	$(NULL)
 
 # TODO: Fix this.  Sorting done to "work around the native doclet portino of bgo#662784" - folks
@@ -62,29 +79,44 @@ gxml_doc_files = \
 
 # todo: find out what dependencies I want/need to set
 gxml_doc_deps = \
+	gio-2.0 \
+	gee-0.8 \
+	libxml-2.0 \
 	$(NULL)
 
 valadoc_flags_gxml = \
 	$(valadoc_flags) \
 	-X $(top_srcdir)/gxml/gxml.h \
-	$(addprefix --pkg=,$(gxml_doc_deps)) \
 	--vapidir=$(top_srcdir)/gxml \
+	--vapidir=$(top_srcdir)/vapi \
+	$(addprefix --pkg=,$(gxml_doc_deps)) \
 	--wiki=$(top_srcdir)/docs/wiki \
 	$(gxml_doc_files) \
 	$(NULL)
 
+
+#	$(AM_V_GEN)$(VALADOC) 
 gxml-doc: $(gxml_doc_files) $(gxml_wiki_files)
-	$(AM_V_GEN)$(VALADOC) \
+	$(VALADOC) \
 		-o gxml/ \
 		--doclet=devhelp \
 		$(valadoc_flags_gxml) \
 		$(NULL)
 
-
+# TODO: need to figure out how to not rely on -0.2 in this Makefile.am
+# AM_V_GEN: what does it do?  It appears to prettify output but also obscure errors :D
+#	$(AM_V_GEN)$(VALADOC)
 gxml-gtk-doc: $(gxml_doc_files) $(gxml_wiki_files)
-	$(AM_V_GEN)$(VALADOC) \
-		-X -l -X $(top_builddir)/gxml/.libs/libgxml.so \
+	$(VALADOC) \
+		-X -l -X $(top_builddir)/gxml/.libs/libgxml-0.2.so \
 		-o gtk-doc/gxml \
 		--doclet=gtkdoc \
 		$(valadoc_flags_gxml) \
 		$(NULL)
+
+.PHONY: $(phony_deps)
+
+# Hack, because I don't know how to make the other ones targets :D
+# all: gxml-gtk-doc gxml-doc
+
+-include $(top_srcdir)/git.mk
diff --git a/docs/wiki/concepts.valadoc b/docs/wiki/concepts.valadoc
index e69de29..490374e 100644
--- a/docs/wiki/concepts.valadoc
+++ b/docs/wiki/concepts.valadoc
@@ -0,0 +1,3 @@
+GXml primarily provides a DOM tree representation of an XML structure.
+It also provides serialization services through the GXml.Serialization
+class and the GXml.Serializable interface.
diff --git a/docs/wiki/debugging.valadoc b/docs/wiki/debugging.valadoc
index e69de29..f5c31b1 100644
--- a/docs/wiki/debugging.valadoc
+++ b/docs/wiki/debugging.valadoc
@@ -0,0 +1,2 @@
+The best way to debug GXml is to write tests for it.  There are a lot
+of unit tests already.  Feel free to add more.
diff --git a/docs/wiki/glossary.valadoc b/docs/wiki/glossary.valadoc
index e69de29..089e9c8 100644
--- a/docs/wiki/glossary.valadoc
+++ b/docs/wiki/glossary.valadoc
@@ -0,0 +1 @@
+ * ''DOM'' Document Object Model



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