[gtk-doc] test: simplify per test Makefile.am and have test specific stuff in gtk-doc*.make



commit b8d0ea54918049ac246b46a636cf199915d69725
Author: Stefan Kost <ensonic users sf net>
Date:   Tue May 3 14:25:26 2011 +0300

    test: simplify per test Makefile.am and have test specific stuff in gtk-doc*.make
    
    Add the log redirects to the makefiles. This way we don't have differnt option
    placement in the rules anymore. We can now also echo the command we invoke to
    the log. This comes handy if one need to run in manually.

 tests/annotations/docs/Makefile.am  |   13 ++++-----
 tests/bugs/docs/Makefile.am         |   15 +++++------
 tests/empty/docs/Makefile.am        |   17 ++++++-------
 tests/fail/docs/Makefile.am         |   14 ++++------
 tests/gobject/docs-tmpl/Makefile.am |   12 ++++----
 tests/gobject/docs/Makefile.am      |   13 ++++-----
 tests/gtk-doc.make                  |   45 ++++++++++++++++++++--------------
 tests/gtk-doc.notmpl.make           |   36 ++++++++++++++++-----------
 8 files changed, 86 insertions(+), 79 deletions(-)
---
diff --git a/tests/annotations/docs/Makefile.am b/tests/annotations/docs/Makefile.am
index 77e27c6..5f7563b 100644
--- a/tests/annotations/docs/Makefile.am
+++ b/tests/annotations/docs/Makefile.am
@@ -15,26 +15,25 @@ DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.xml
 DOC_SOURCE_DIR=$(top_srcdir)/tests/annotations/src
 
 # Extra options to pass to gtkdoc-scangobj. Not normally needed.
-SCANGOBJ_OPTIONS=2>&1 | tee gtkdoc-scangobj.log
+SCANGOBJ_OPTIONS=
 
 # Extra options to supply to gtkdoc-scan.
 SCAN_OPTIONS=--deprecated-guards="GTKDOC_TESTER_DISABLE_DEPRECATED" \
-  --ignore-decorators="GLIB_VAR" \
-  2>&1 | tee gtkdoc-scan.log
+  --ignore-decorators="GLIB_VAR"
 
 # Extra options to supply to gtkdoc-mkdb.
-MKDB_OPTIONS=--xml-mode 2>&1 | tee gtkdoc-mkdb.log
+MKDB_OPTIONS=--xml-mode
 
 # Extra options to supply to gtkdoc-mktmpl
 # e.g. MKTMPL_OPTIONS=--only-section-tmpl
-MKTMPL_OPTIONS=2>&1 | tee gtkdoc-mktmpl.log
+MKTMPL_OPTIONS=
 
 # Extra options to supply to gtkdoc-mkhtml
-MKHTML_OPTIONS=2>&1 | tee ../gtkdoc-mkhtml.log
+MKHTML_OPTIONS=
 
 # Extra options to supply to gtkdoc-fixref. Not normally needed.
 # --html-dir=$(HTML_DIR)
-FIXXREF_OPTIONS=--extra-dir=$(glib_prefix)/share/gtk-doc/html 2>&1 | tee gtkdoc-fixxref.log
+FIXXREF_OPTIONS=--extra-dir=$(glib_prefix)/share/gtk-doc/html
 
 # Used for dependencies. The docs will be rebuilt if any of these change.
 HFILE_GLOB=$(top_srcdir)/tests/annotations/src/*.h
diff --git a/tests/bugs/docs/Makefile.am b/tests/bugs/docs/Makefile.am
index 75ad3f6..e008d3a 100644
--- a/tests/bugs/docs/Makefile.am
+++ b/tests/bugs/docs/Makefile.am
@@ -15,27 +15,26 @@ DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.xml
 DOC_SOURCE_DIR=$(top_srcdir)/tests/bugs/src
 
 # Extra options to pass to gtkdoc-scangobj. Not normally needed.
-SCANGOBJ_OPTIONS=2>&1 | tee gtkdoc-scangobj.log
+SCANGOBJ_OPTIONS=
 
 # Extra options to supply to gtkdoc-scan.
 SCAN_OPTIONS=--deprecated-guards="GTKDOC_TESTER_DISABLE_DEPRECATED" \
-  --ignore-decorators="GLIB_VAR|GTKDOC_GNUC_CONST" \
-  --rebuild-types \
-  2>&1 | tee gtkdoc-scan.log
+  --ignore-decorators='GLIB_VAR|GTKDOC_GNUC_CONST' \
+  --rebuild-types
 
 # Extra options to supply to gtkdoc-mkdb.
-MKDB_OPTIONS=--xml-mode 2>&1 | tee gtkdoc-mkdb.log
+MKDB_OPTIONS=--xml-mode
 
 # Extra options to supply to gtkdoc-mktmpl
 # e.g. MKTMPL_OPTIONS=--only-section-tmpl
-MKTMPL_OPTIONS=2>&1 | tee gtkdoc-mktmpl.log
+MKTMPL_OPTIONS=
 
 # Extra options to supply to gtkdoc-mkhtml
-MKHTML_OPTIONS=2>&1 | tee ../gtkdoc-mkhtml.log
+MKHTML_OPTIONS=
 
 # Extra options to supply to gtkdoc-fixref. Not normally needed.
 # --html-dir=$(HTML_DIR)
-FIXXREF_OPTIONS=--extra-dir=$(glib_prefix)/share/gtk-doc/html 2>&1 | tee gtkdoc-fixxref.log
+FIXXREF_OPTIONS=--extra-dir=$(glib_prefix)/share/gtk-doc/html
 
 # Used for dependencies. The docs will be rebuilt if any of these change.
 HFILE_GLOB=$(top_srcdir)/tests/bugs/src/*.h
diff --git a/tests/empty/docs/Makefile.am b/tests/empty/docs/Makefile.am
index 4c28740..2e1f0e4 100644
--- a/tests/empty/docs/Makefile.am
+++ b/tests/empty/docs/Makefile.am
@@ -1,6 +1,6 @@
 ## Process this file with automake to produce Makefile.in
 
-# this tests bootstraps gtk-doc, that includes generating a default 
+# this tests bootstraps gtk-doc, that includes generating a default
 # DOC_MAIN_SGML_FILE
 # right now that fails with parallel make, as make cannot see that what is a
 # dependency for another target is generated as needed
@@ -21,26 +21,25 @@ DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.xml
 DOC_SOURCE_DIR=$(top_srcdir)/tests/empty/src
 
 # Extra options to pass to gtkdoc-scangobj. Not normally needed.
-SCANGOBJ_OPTIONS=2>&1 | tee gtkdoc-scangobj.log
+SCANGOBJ_OPTIONS=
 
 # Extra options to supply to gtkdoc-scan.
 SCAN_OPTIONS=--deprecated-guards="GTKDOC_TESTER_DISABLE_DEPRECATED" \
-  --rebuild-sections \
-  2>&1 | tee gtkdoc-scan.log
+  --rebuild-sections
 
 # Extra options to supply to gtkdoc-mkdb.
-MKDB_OPTIONS=--xml-mode 2>&1 | tee gtkdoc-mkdb.log
+MKDB_OPTIONS=--xml-mode
 
 # Extra options to supply to gtkdoc-mktmpl
 # e.g. MKTMPL_OPTIONS=--only-section-tmpl
-MKTMPL_OPTIONS=2>&1 | tee gtkdoc-mktmpl.log
+MKTMPL_OPTIONS=
 
 # Extra options to supply to gtkdoc-mkhtml
-MKHTML_OPTIONS=2>&1 | tee ../gtkdoc-mkhtml.log
+MKHTML_OPTIONS=
 
 # Extra options to supply to gtkdoc-fixref. Not normally needed.
 # --html-dir=$(HTML_DIR)
-FIXXREF_OPTIONS=--extra-dir=$(glib_prefix)/share/gtk-doc/html 2>&1 | tee gtkdoc-fixxref.log
+FIXXREF_OPTIONS=--extra-dir=$(glib_prefix)/share/gtk-doc/html
 
 # Used for dependencies. The docs will be rebuilt if any of these change.
 HFILE_GLOB=$(top_srcdir)/tests/empty/src/*.h
@@ -50,7 +49,7 @@ CFILE_GLOB=$(top_srcdir)/tests/empty/src/*.c
 IGNORE_HFILES=config.h
 
 # Images to copy into HTML directory.
-HTML_IMAGES = 
+HTML_IMAGES =
 
 # Extra SGML files that are included by $(DOC_MAIN_SGML_FILE).
 # e.g. content_files=running.sgml building.sgml changes-2.0.sgml
diff --git a/tests/fail/docs/Makefile.am b/tests/fail/docs/Makefile.am
index 7893c28..a1a7096 100644
--- a/tests/fail/docs/Makefile.am
+++ b/tests/fail/docs/Makefile.am
@@ -15,26 +15,24 @@ DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.xml
 DOC_SOURCE_DIR=$(top_srcdir)/tests/fail/src
 
 # Extra options to pass to gtkdoc-scangobj. Not normally needed.
-SCANGOBJ_OPTIONS=2>&1 | tee gtkdoc-scangobj.log
+SCANGOBJ_OPTIONS=
 
 # Extra options to supply to gtkdoc-scan.
 SCAN_OPTIONS=--deprecated-guards="GTKDOC_TESTER_DISABLE_DEPRECATED" \
-  --ignore-decorators="GLIB_VAR" \
-  2>&1 | tee gtkdoc-scan.log
+  --ignore-decorators="GLIB_VAR"
 
 # Extra options to supply to gtkdoc-mkdb.
-MKDB_OPTIONS=--xml-mode 2>&1 | tee gtkdoc-mkdb.log
-
+MKDB_OPTIONS=
 # Extra options to supply to gtkdoc-mktmpl
 # e.g. MKTMPL_OPTIONS=--only-section-tmpl
-MKTMPL_OPTIONS=2>&1 | tee gtkdoc-mktmpl.log
+MKTMPL_OPTIONS=
 
 # Extra options to supply to gtkdoc-mkhtml
-MKHTML_OPTIONS=2>&1 | tee ../gtkdoc-mkhtml.log
+MKHTML_OPTIONS=
 
 # Extra options to supply to gtkdoc-fixref. Not normally needed.
 # --html-dir=$(HTML_DIR)
-FIXXREF_OPTIONS=--extra-dir=$(glib_prefix)/share/gtk-doc/html 2>&1 | tee gtkdoc-fixxref.log
+FIXXREF_OPTIONS=--extra-dir=$(glib_prefix)/share/gtk-doc/html
 
 # Used for dependencies. The docs will be rebuilt if any of these change.
 HFILE_GLOB=$(top_srcdir)/tests/fail/src/*.h
diff --git a/tests/gobject/docs-tmpl/Makefile.am b/tests/gobject/docs-tmpl/Makefile.am
index 44f8f8e..402b0b2 100644
--- a/tests/gobject/docs-tmpl/Makefile.am
+++ b/tests/gobject/docs-tmpl/Makefile.am
@@ -15,24 +15,24 @@ DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.xml
 DOC_SOURCE_DIR=$(top_srcdir)/tests/gobject/src
 
 # Extra options to pass to gtkdoc-scangobj. Not normally needed.
-SCANGOBJ_OPTIONS=2>&1 | tee gtkdoc-scangobj.log
+SCANGOBJ_OPTIONS=
 
 # Extra options to supply to gtkdoc-scan.
-SCAN_OPTIONS=--deprecated-guards="GTKDOC_TESTER_DISABLE_DEPRECATED" 2>&1 | tee gtkdoc-scan.log
+SCAN_OPTIONS=--deprecated-guards="GTKDOC_TESTER_DISABLE_DEPRECATED"
 
 # Extra options to supply to gtkdoc-mkdb.
-MKDB_OPTIONS=--xml-mode 2>&1 | tee gtkdoc-mkdb.log
+MKDB_OPTIONS=--xml-mode
 
 # Extra options to supply to gtkdoc-mktmpl
 # e.g. MKTMPL_OPTIONS=--only-section-tmpl
-MKTMPL_OPTIONS=2>&1 | tee gtkdoc-mktmpl.log
+MKTMPL_OPTIONS=
 
 # Extra options to supply to gtkdoc-mkhtml
-MKHTML_OPTIONS=2>&1 | tee ../gtkdoc-mkhtml.log
+MKHTML_OPTIONS=
 
 # Extra options to supply to gtkdoc-fixref. Not normally needed.
 # --html-dir=$(HTML_DIR)
-FIXXREF_OPTIONS=--extra-dir=$(glib_prefix)/share/gtk-doc/html 2>&1 | tee gtkdoc-fixxref.log
+FIXXREF_OPTIONS=--extra-dir=$(glib_prefix)/share/gtk-doc/html
 
 # Used for dependencies. The docs will be rebuilt if any of these change.
 HFILE_GLOB=$(top_srcdir)/tests/gobject/src/*.h
diff --git a/tests/gobject/docs/Makefile.am b/tests/gobject/docs/Makefile.am
index 70851f3..5b8db29 100644
--- a/tests/gobject/docs/Makefile.am
+++ b/tests/gobject/docs/Makefile.am
@@ -15,26 +15,25 @@ DOC_MAIN_SGML_FILE=$(DOC_MODULE)-docs.xml
 DOC_SOURCE_DIR=$(top_srcdir)/tests/gobject/src
 
 # Extra options to pass to gtkdoc-scangobj. Not normally needed.
-SCANGOBJ_OPTIONS=2>&1 | tee gtkdoc-scangobj.log
+SCANGOBJ_OPTIONS=
 
 # Extra options to supply to gtkdoc-scan.
 SCAN_OPTIONS=--deprecated-guards="GTKDOC_TESTER_DISABLE_DEPRECATED" \
-  --rebuild-types \
-  2>&1 | tee gtkdoc-scan.log
+  --rebuild-types
 
 # Extra options to supply to gtkdoc-mkdb.
-MKDB_OPTIONS=--xml-mode 2>&1 | tee gtkdoc-mkdb.log
+MKDB_OPTIONS=--xml-mode
 
 # Extra options to supply to gtkdoc-mktmpl
 # e.g. MKTMPL_OPTIONS=--only-section-tmpl
-MKTMPL_OPTIONS=2>&1 | tee gtkdoc-mktmpl.log
+MKTMPL_OPTIONS=
 
 # Extra options to supply to gtkdoc-mkhtml
-MKHTML_OPTIONS=2>&1 | tee ../gtkdoc-mkhtml.log
+MKHTML_OPTIONS=
 
 # Extra options to supply to gtkdoc-fixref. Not normally needed.
 # --html-dir=$(HTML_DIR)
-FIXXREF_OPTIONS=--extra-dir=$(glib_prefix)/share/gtk-doc/html 2>&1 | tee gtkdoc-fixxref.log
+FIXXREF_OPTIONS=--extra-dir=$(glib_prefix)/share/gtk-doc/html
 
 # Used for dependencies. The docs will be rebuilt if any of these change.
 HFILE_GLOB=$(top_srcdir)/tests/gobject/src/*.h
diff --git a/tests/gtk-doc.make b/tests/gtk-doc.make
index aed0aed..caf080f 100644
--- a/tests/gtk-doc.make
+++ b/tests/gtk-doc.make
@@ -67,16 +67,16 @@ $(REPORT_FILES): sgml-build.stamp
 setup-build.stamp:
 	@echo >ts `date +%s.%N`;
 	- if test "$(abs_srcdir)" != "$(abs_builddir)" ; then \
-	   echo '  DOC   Preparing build'; \
-	   files=`echo $(SETUP_FILES) $(expand_content_files) $(DOC_MODULE).types`; \
-	   if test "x$$files" != "x" ; then \
-	       for file in $$files ; do \
-	           test -f $(abs_srcdir)/$$file && \
-	               cp -p $(abs_srcdir)/$$file $(abs_builddir)/; \
-	       done \
-	   fi; \
-	   test -f $(abs_srcdir)/tmpl && \
-	       cp -rp $(abs_srcdir)/tmpl $(abs_builddir)/; \
+	    echo '  DOC   Preparing build'; \
+	    files=`echo $(SETUP_FILES) $(expand_content_files) $(DOC_MODULE).types`; \
+	    if test "x$$files" != "x" ; then \
+	        for file in $$files ; do \
+	            test -f $(abs_srcdir)/$$file && \
+	                cp -pu $(abs_srcdir)/$$file $(abs_builddir)/ || true; \
+	        done; \
+	    fi; \
+	    test -f $(abs_srcdir)/tmpl && \
+	        cp -rp $(abs_srcdir)/tmpl $(abs_builddir)/; \
 	fi
 	@touch setup-build.stamp
 
@@ -89,8 +89,9 @@ scan-build.stamp: $(HFILE_GLOB) $(CFILE_GLOB)
 	for i in $(DOC_SOURCE_DIR) ; do \
 	    _source_dir="$${_source_dir} --source-dir=$$i" ; \
 	done ; \
+	echo "gtkdoc-scan --module=$(DOC_MODULE) --ignore-headers="$(IGNORE_HFILES)" $${_source_dir} $(SCAN_OPTIONS) $(EXTRA_HFILES)"  >gtkdoc-scan.log; \
 	PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) \
-	gtkdoc-scan --module=$(DOC_MODULE) --ignore-headers="$(IGNORE_HFILES)" $${_source_dir} $(EXTRA_HFILES) $(SCAN_OPTIONS)
+	gtkdoc-scan --module=$(DOC_MODULE) --ignore-headers="$(IGNORE_HFILES)" $${_source_dir} $(SCAN_OPTIONS) $(EXTRA_HFILES) 2>&1 | tee -a gtkdoc-scan.log
 	@if grep -l '^..*$$' $(DOC_MODULE).types > /dev/null 2>&1 ; then \
 		ts1=`cat ts`;ts2=`date +%s.%N`;tsd=`echo $$ts2-$$ts1 | bc`; \
 	    echo "  DOC   `date --utc --date @0$$tsd +%H:%M:%S.%N`: Introspecting gobjects"; \
@@ -98,9 +99,10 @@ scan-build.stamp: $(HFILE_GLOB) $(CFILE_GLOB)
 	    if test "x$(V)" = "x1"; then \
 	        scanobj_options="--verbose"; \
 	    fi; \
+	    echo "gtkdoc-scangobj $(SCANGOBJ_OPTIONS) --module=$(DOC_MODULE) $$scanobj_options" >gtkdoc-scangobj.log; \
 	    PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) \
 	    CC="$(GTKDOC_CC)" LD="$(GTKDOC_LD)" RUN="$(GTKDOC_RUN)" CFLAGS="$(GTKDOC_CFLAGS) $(CFLAGS)" LDFLAGS="$(GTKDOC_LIBS) $(LDFLAGS)" \
-	    gtkdoc-scangobj --module=$(DOC_MODULE) $$scanobj_options $(SCANGOBJ_OPTIONS); \
+	    gtkdoc-scangobj $(SCANGOBJ_OPTIONS) --module=$(DOC_MODULE) $$scanobj_options 2>&1 | tee -a gtkdoc-scangobj.log; \
 	else \
 	    for i in $(SCANOBJ_FILES) ; do \
 	        test -f $$i || touch $$i ; \
@@ -116,8 +118,9 @@ $(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DOC_MODULE)-sections.txt $(DOC_MODULE)
 tmpl-build.stamp: setup-build.stamp $(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DOC_MODULE)-sections.txt $(DOC_MODULE)-overrides.txt
 	@ts1=`cat ts`;ts2=`date +%s.%N`;tsd=`echo $$ts2-$$ts1 | bc`; \
 	echo "  DOC   `date --utc --date @0$$tsd +%H:%M:%S.%N`: Rebuilding template files"
-	@PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) \
-	gtkdoc-mktmpl --module=$(DOC_MODULE) $(MKTMPL_OPTIONS)
+	@echo "gtkdoc-mktmpl --module=$(DOC_MODULE) $(MKTMPL_OPTIONS)" >gtkdoc-mktmpl.log; \
+	PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) \
+	gtkdoc-mktmpl --module=$(DOC_MODULE) $(MKTMPL_OPTIONS) 2>&1 | tee -a gtkdoc-mktmpl.log
 	@if test "$(abs_srcdir)" != "$(abs_builddir)" ; then \
 	  if test -w $(abs_srcdir) ; then \
 	    cp -rp $(abs_builddir)/tmpl $(abs_srcdir)/; \
@@ -140,8 +143,9 @@ sgml-build.stamp: tmpl.stamp $(DOC_MODULE)-sections.txt $(srcdir)/tmpl/*.sgml $(
 	for i in $(DOC_SOURCE_DIR) ; do \
 	    _source_dir="$${_source_dir} --source-dir=$$i" ; \
 	done ; \
+	echo "gtkdoc-mkdb --module=$(DOC_MODULE) --output-format=xml --expand-content-files="$(expand_content_files)" --main-sgml-file=$(DOC_MAIN_SGML_FILE) $${_source_dir} $(MKDB_OPTIONS)" >gtkdoc-mkdb.log; \
 	PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) \
-	gtkdoc-mkdb --module=$(DOC_MODULE) --output-format=xml --expand-content-files="$(expand_content_files)" --main-sgml-file=$(DOC_MAIN_SGML_FILE) $${_source_dir} $(MKDB_OPTIONS)
+	gtkdoc-mkdb --module=$(DOC_MODULE) --output-format=xml --expand-content-files="$(expand_content_files)" --main-sgml-file=$(DOC_MAIN_SGML_FILE) $${_source_dir} $(MKDB_OPTIONS) 2>&1 | tee -a gtkdoc-mkdb.log
 	@touch sgml-build.stamp
 
 sgml.stamp: sgml-build.stamp
@@ -158,8 +162,9 @@ html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files)
 	if test "x$(V)" = "x1"; then \
 	  mkhtml_options="$$mkhtml_options --verbose"; \
 	fi; \
+	echo "gtkdoc-mkhtml --uninstalled --path="$(abs_srcdir)" $$mkhtml_options $(MKHTML_OPTIONS) $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE)" >gtkdoc-mkhtml.log; \
 	cd html && PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) ABS_TOP_SRCDIR=$(abs_top_srcdir) \
-	gtkdoc-mkhtml --uninstalled --path="$(abs_srcdir)" $$mkhtml_options $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE) $(MKHTML_OPTIONS)
+	gtkdoc-mkhtml --uninstalled --path="$(abs_srcdir)" $$mkhtml_options $(MKHTML_OPTIONS) $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE) 2>&1 | tee -a ../gtkdoc-mkhtml.log
 	- test "x$(HTML_IMAGES)" = "x" || \
 	for file in $(HTML_IMAGES) ; do \
 	  if test -f $(abs_srcdir)/$$file ; then \
@@ -171,8 +176,9 @@ html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files)
 	done;
 	@ts1=`cat ts`;ts2=`date +%s.%N`;tsd=`echo $$ts2-$$ts1 | bc`; \
 	echo "  DOC   `date --utc --date @0$$tsd +%H:%M:%S.%N`: Fixing cross-references"
-	@PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) \
-	gtkdoc-fixxref --module=$(DOC_MODULE) --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)
+	@echo "gtkdoc-fixxref --module=$(DOC_MODULE) --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)" >gtkdoc-fixxref.log; \
+	PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) \
+	gtkdoc-fixxref --module=$(DOC_MODULE) --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS) 2>&1 | tee -a gtkdoc-fixxref.log
 	@touch html-build.stamp
 
 #### pdf ####
@@ -194,8 +200,9 @@ pdf-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files)
 	    fi; \
 	  done; \
 	fi; \
+	echo "gtkdoc-mkpdf --uninstalled --path="$(abs_srcdir)" $$mkpdf_options $(DOC_MODULE) $(DOC_MAIN_SGML_FILE) $(MKPDF_OPTIONS)" >gtkdoc-mkpdf.log; \
 	PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) ABS_TOP_SRCDIR=$(abs_top_srcdir) \
-	gtkdoc-mkpdf --uninstalled --path="$(abs_srcdir)" $$mkpdf_options $(DOC_MODULE) $(DOC_MAIN_SGML_FILE) $(MKPDF_OPTIONS)
+	gtkdoc-mkpdf --uninstalled --path="$(abs_srcdir)" $$mkpdf_options $(DOC_MODULE) $(DOC_MAIN_SGML_FILE) $(MKPDF_OPTIONS) 2>&1 | tee -a gtkdoc-mkpdf.log
 	@touch pdf-build.stamp
 
 ##############
diff --git a/tests/gtk-doc.notmpl.make b/tests/gtk-doc.notmpl.make
index 4789be2..96cfafa 100644
--- a/tests/gtk-doc.notmpl.make
+++ b/tests/gtk-doc.notmpl.make
@@ -67,14 +67,14 @@ $(REPORT_FILES): sgml-build.stamp
 setup-build.stamp:
 	@echo >ts `date +%s.%N`;
 	- if test "$(abs_srcdir)" != "$(abs_builddir)" ; then \
-	   echo '  DOC   Preparing build'; \
-	   files=`echo $(SETUP_FILES) $(expand_content_files) $(DOC_MODULE).types`; \
-	   if test "x$$files" != "x" ; then \
-	       for file in $$files ; do \
-	           test -f $(abs_srcdir)/$$file && \
-	               cp -p $(abs_srcdir)/$$file $(abs_builddir)/; \
-	       done \
-	   fi \
+	    echo '  DOC   Preparing build'; \
+	    files=`echo $(SETUP_FILES) $(expand_content_files) $(DOC_MODULE).types`; \
+	    if test "x$$files" != "x" ; then \
+	        for file in $$files ; do \
+	            test -f $(abs_srcdir)/$$file && \
+	                cp -pu $(abs_srcdir)/$$file $(abs_builddir)/ || true; \
+	        done; \
+	    fi; \
 	fi
 	@touch setup-build.stamp
 
@@ -87,8 +87,9 @@ scan-build.stamp: $(HFILE_GLOB) $(CFILE_GLOB)
 	for i in $(DOC_SOURCE_DIR) ; do \
 	    _source_dir="$${_source_dir} --source-dir=$$i" ; \
 	done ; \
+	echo "gtkdoc-scan --module=$(DOC_MODULE) --ignore-headers="$(IGNORE_HFILES)" $${_source_dir} $(SCAN_OPTIONS) $(EXTRA_HFILES)"  >gtkdoc-scan.log; \
 	PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) \
-	gtkdoc-scan --module=$(DOC_MODULE) --ignore-headers="$(IGNORE_HFILES)" $${_source_dir} $(EXTRA_HFILES) $(SCAN_OPTIONS)
+	gtkdoc-scan --module=$(DOC_MODULE) --ignore-headers="$(IGNORE_HFILES)" $${_source_dir} $(SCAN_OPTIONS) $(EXTRA_HFILES) 2>&1 | tee -a gtkdoc-scan.log
 	@if grep -l '^..*$$' $(DOC_MODULE).types > /dev/null 2>&1 ; then \
 		ts1=`cat ts`;ts2=`date +%s.%N`;tsd=`echo $$ts2-$$ts1 | bc`; \
 	    echo "  DOC   `date --utc --date @0$$tsd +%H:%M:%S.%N`: Introspecting gobjects"; \
@@ -96,9 +97,10 @@ scan-build.stamp: $(HFILE_GLOB) $(CFILE_GLOB)
 	    if test "x$(V)" = "x1"; then \
 	        scanobj_options="--verbose"; \
 	    fi; \
+	    echo "gtkdoc-scangobj $(SCANGOBJ_OPTIONS) --module=$(DOC_MODULE) $$scanobj_options" >gtkdoc-scangobj.log; \
 	    PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) \
 	    CC="$(GTKDOC_CC)" LD="$(GTKDOC_LD)" RUN="$(GTKDOC_RUN)" CFLAGS="$(GTKDOC_CFLAGS) $(CFLAGS)" LDFLAGS="$(GTKDOC_LIBS) $(LDFLAGS)" \
-	    gtkdoc-scangobj --module=$(DOC_MODULE) $$scanobj_options $(SCANGOBJ_OPTIONS); \
+	    gtkdoc-scangobj $(SCANGOBJ_OPTIONS) --module=$(DOC_MODULE) $$scanobj_options 2>&1 | tee -a gtkdoc-scangobj.log; \
 	else \
 	    for i in $(SCANOBJ_FILES) ; do \
 	        test -f $$i || touch $$i ; \
@@ -118,8 +120,9 @@ sgml-build.stamp: setup-build.stamp $(DOC_MODULE)-decl.txt $(SCANOBJ_FILES) $(DO
 	for i in $(DOC_SOURCE_DIR) ; do \
 	    _source_dir="$${_source_dir} --source-dir=$$i" ; \
 	done ; \
+	echo "gtkdoc-mkdb --module=$(DOC_MODULE) --output-format=xml --expand-content-files="$(expand_content_files)" --main-sgml-file=$(DOC_MAIN_SGML_FILE) $${_source_dir} $(MKDB_OPTIONS)" >gtkdoc-mkdb.log; \
 	PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) \
-	gtkdoc-mkdb --module=$(DOC_MODULE) --output-format=xml --expand-content-files="$(expand_content_files)" --main-sgml-file=$(DOC_MAIN_SGML_FILE) $${_source_dir} $(MKDB_OPTIONS)
+	gtkdoc-mkdb --module=$(DOC_MODULE) --output-format=xml --expand-content-files="$(expand_content_files)" --main-sgml-file=$(DOC_MAIN_SGML_FILE) $${_source_dir} $(MKDB_OPTIONS) 2>&1 | tee -a gtkdoc-mkdb.log
 	@touch sgml-build.stamp
 
 sgml.stamp: sgml-build.stamp
@@ -136,8 +139,9 @@ html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files)
 	if test "x$(V)" = "x1"; then \
 	  mkhtml_options="$$mkhtml_options --verbose"; \
 	fi; \
+	echo "gtkdoc-mkhtml --uninstalled --path="$(abs_srcdir)" $$mkhtml_options $(MKHTML_OPTIONS) $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE)" >gtkdoc-mkhtml.log; \
 	cd html && PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) ABS_TOP_SRCDIR=$(abs_top_srcdir) \
-	gtkdoc-mkhtml --uninstalled --path="$(abs_srcdir)" $$mkhtml_options $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE) $(MKHTML_OPTIONS)
+	gtkdoc-mkhtml --uninstalled --path="$(abs_srcdir)" $$mkhtml_options $(MKHTML_OPTIONS) $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE) 2>&1 | tee -a ../gtkdoc-mkhtml.log
 	- test "x$(HTML_IMAGES)" = "x" || \
 	for file in $(HTML_IMAGES) ; do \
 	  if test -f $(abs_srcdir)/$$file ; then \
@@ -149,8 +153,9 @@ html-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files)
 	done;
 	@ts1=`cat ts`;ts2=`date +%s.%N`;tsd=`echo $$ts2-$$ts1 | bc`; \
 	echo "  DOC   `date --utc --date @0$$tsd +%H:%M:%S.%N`: Fixing cross-references"
-	@PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) \
-	gtkdoc-fixxref --module=$(DOC_MODULE) --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)
+	@echo "gtkdoc-fixxref --module=$(DOC_MODULE) --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS)" >gtkdoc-fixxref.log; \
+	PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) \
+	gtkdoc-fixxref --module=$(DOC_MODULE) --module-dir=html --html-dir=$(HTML_DIR) $(FIXXREF_OPTIONS) 2>&1 | tee -a gtkdoc-fixxref.log
 	@touch html-build.stamp
 
 #### pdf ####
@@ -172,8 +177,9 @@ pdf-build.stamp: sgml.stamp $(DOC_MAIN_SGML_FILE) $(content_files)
 	    fi; \
 	  done; \
 	fi; \
+	echo "gtkdoc-mkpdf --uninstalled --path="$(abs_srcdir)" $$mkpdf_options $(DOC_MODULE) $(DOC_MAIN_SGML_FILE) $(MKPDF_OPTIONS)" >gtkdoc-mkpdf.log; \
 	PATH=$(abs_top_builddir):$(PATH) PERL5LIB=$(abs_top_builddir):$(PERL5LIB) ABS_TOP_SRCDIR=$(abs_top_srcdir) \
-	gtkdoc-mkpdf --uninstalled --path="$(abs_srcdir)" $$mkpdf_options $(DOC_MODULE) $(DOC_MAIN_SGML_FILE) $(MKPDF_OPTIONS)
+	gtkdoc-mkpdf --uninstalled --path="$(abs_srcdir)" $$mkpdf_options $(DOC_MODULE) $(DOC_MAIN_SGML_FILE) $(MKPDF_OPTIONS) 2>&1 | tee -a gtkdoc-mkpdf.log
 	@touch pdf-build.stamp
 
 ##############



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