From 1a17e2aa68423530d9644f316bac8e9fc3335874 Mon Sep 17 00:00:00 2001 From: Jim Klimov Date: Thu, 31 Mar 2022 10:40:05 +0000 Subject: [PATCH] {.,docs,docs/man}/Makefile.am: add "all-man" target to build all possible man pages (vs ones for enabled drivers), and weave this and check targets to parent makefiles --- Makefile.am | 9 ++++++++- docs/Makefile.am | 7 +++++-- docs/man/Makefile.am | 6 +++++- 3 files changed, 18 insertions(+), 4 deletions(-) diff --git a/Makefile.am b/Makefile.am index 68882955f6..b42d639cab 100644 --- a/Makefile.am +++ b/Makefile.am @@ -108,7 +108,14 @@ spellcheck spellcheck-interactive: (cd $(builddir)/data && $(MAKE) -s $@) || RES=$$? ; \ exit $$RES -doc spellcheck-sortdict: +# Note: the "all-docs" and "check-docs" targets may require tools not +# found by `configure` script (and so avoided by conventional recipes) +# such as PDF generators, so it should only be called at developer's +# discretion, choice and risk. The "check-man" targets covers source +# texts, man pages and HTML rendering of man pages, as enabled by tools. +doc spellcheck-sortdict \ +all-docs check-docs \ +man all-man man-man check-man man-html all-html: cd $(srcdir)/docs && $(MAKE) $@ # This target adds syntax-checking for committed shell script files, diff --git a/docs/Makefile.am b/docs/Makefile.am index 3b8d433a61..1b93081736 100644 --- a/docs/Makefile.am +++ b/docs/Makefile.am @@ -87,7 +87,7 @@ doc: @DOC_BUILD_LIST@ # This target can be called by developers to go around the configure # script choices at their risk (e.g. missing tools are possible): -docs: pdf html-single html-chunked man +docs: pdf html-single html-chunked man-man html-man all-docs: docs @@ -130,7 +130,10 @@ check-html-chunked: $(ASCIIDOC_HTML_CHUNKED) # Note: usually the results from man-page check will be reported twice: # once as a SUBDIRS child makefile, and once via DOC_CHECK_LIST expansion -check-man: +# Note: default `make all` in the man directory caters to drivers etc. +# chosen during configure script execution. The "all-man" and "all-html" +# rules build everything documented. +check-man all-man man-man all-html html-man: cd $(top_builddir)/docs/man/ && $(MAKE) -f Makefile $@ man: diff --git a/docs/man/Makefile.am b/docs/man/Makefile.am index cc667814e0..11e1597b16 100644 --- a/docs/man/Makefile.am +++ b/docs/man/Makefile.am @@ -735,7 +735,11 @@ HTML_MANS = \ all: -html-man: $(HTML_MANS) index.html +all-html html-man: $(HTML_MANS) index.html + +# Have a way to build all man pages, not just those that fit currently +# configured drivers, daemons, developer aspect, etc. +all-man man-man: $(MAN_MANS) if WITH_MANS if ! SKIP_MANS