]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
Build all the man pages in a single command.
authortcely <tcely@users.noreply.github.com>
Tue, 1 Aug 2017 11:31:14 +0000 (07:31 -0400)
committertcely <tcely@users.noreply.github.com>
Thu, 24 May 2018 15:32:44 +0000 (11:32 -0400)
docs/Makefile.am

index 015414afd35c7d64a3bb201a51074e03e2eed12f..a0393a846ad1d0c4b0bf0f4b47271fa70c8db466 100644 (file)
@@ -61,10 +61,13 @@ EXTRA_DIST = $(MANPAGES_DIST)
 
 if HAVE_VIRTUALENV
 if !HAVE_MANPAGES
-$(MANPAGES_DIST): %: manpages/%.rst .venv
-       outputdir="`mktemp -u -d mans.XXXXXX`"; .venv/bin/python -msphinx -b man . "$$outputdir" "$<" && mv "$${outputdir}/$@" "$@"; rm -rf "$$outputdir"
+$(MANPAGES_DIST): %: manpages/%.rst mans
+       mv "mans/$@" "$@" || { rm -rf mans; false; }
 endif # if !HAVE_MANPAGES
 
+mans: .venv
+       rm -rf "$@"; .venv/bin/python -msphinx -b man manpages "$@"
+
 .venv: requirements.txt
        virtualenv .venv
        .venv/bin/pip install -U pip setuptools setuptools-git