[lttng-dev] [PATCH lttng-ust 3/4] Add silent rules support for docs

Michael Jeanson mjeanson at efficios.com
Thu Dec 20 15:22:41 EST 2018


Signed-off-by: Michael Jeanson <mjeanson at efficios.com>
---
 doc/man/Makefile.am | 17 +++++++++++++----
 1 file changed, 13 insertions(+), 4 deletions(-)

diff --git a/doc/man/Makefile.am b/doc/man/Makefile.am
index fcc4c5c7..f562bfd1 100644
--- a/doc/man/Makefile.am
+++ b/doc/man/Makefile.am
@@ -47,26 +47,35 @@ MAN = $(MAN1) $(MAN3)
 if MAN_PAGES_OPT
 # At this point, we know the user asked to build the man pages.
 if HAVE_ASCIIDOC_XMLTO
+
+asciidoc_verbose = $(asciidoc_verbose_ at AM_V@)
+asciidoc_verbose_ = $(asciidoc_verbose_ at AM_DEFAULT_V@)
+asciidoc_verbose_0 = @echo "  ASCIIDOC  " $@;
+
+xmlto_verbose = $(xmlto_verbose_ at AM_V@)
+xmlto_verbose_ = $(xmlto_verbose_ at AM_DEFAULT_V@)
+xmlto_verbose_0 = @echo "  XMLTO     " $@;
+
 # Tools to execute:
-ADOC = $(ASCIIDOC) -f $(ASCIIDOC_CONF) -d manpage \
+ADOC = $(asciidoc_verbose)$(ASCIIDOC) -f $(ASCIIDOC_CONF) -d manpage \
 	-a lttng_version="$(PACKAGE_VERSION)" \
 	-a lttng_ust_register_timeout="@LTTNG_UST_DEFAULT_CONSTRUCTOR_TIMEOUT_MS@"
 
 ADOC_DOCBOOK = $(ADOC) -b docbook
-XTO = $(XMLTO) -m $(XSL_FILE) man
+XTO = $(xmlto_verbose)$(XMLTO) -m $(XSL_FILE) man
 
 # Recipes:
 %.1.xml: $(srcdir)/%.1.txt $(COMMON_DEPS)
 	$(ADOC_DOCBOOK) -o $@ $<
 
 %.1: %.1.xml $(XSL_FILE)
-	$(XTO) $<
+	$(XTO) $< 2>/dev/null
 
 %.3.xml: $(srcdir)/%.3.txt $(COMMON_DEPS)
 	$(ADOC_DOCBOOK) -o $@ $<
 
 %.3: %.3.xml $(XSL_FILE)
-	$(XTO) $<
+	$(XTO) $< 2>/dev/null
 
 # Only clean the generated files if we have the tools to generate them again.
 CLEANFILES = $(MAN_XML) $(MAN)
-- 
2.17.1



More information about the lttng-dev mailing list