build: Fix manpage generation

Seems to be that docs/man/ctr.1.md and docs/man/containerd.1.md were
removed in #3637 and were not updated correctly in the Makefile, leading
to build failures like:

    + make man

    make: *** No rule to make target `man/ctr.1', needed by `man'.  Stop.

Changes the gen-manpages command to be specific on which manpages are to
be generated.

Signed-off-by: Eli Uriegas <eli.uriegas@docker.com>
This commit is contained in:
Eli Uriegas
2019-10-08 00:08:37 +00:00
parent 614c0858f2
commit 036db34f37
3 changed files with 29 additions and 17 deletions

View File

@@ -203,11 +203,19 @@ man: mandir $(addprefix man/,$(MANPAGES))
mandir:
@mkdir -p man
genman: FORCE
go run cmd/gen-manpages/main.go man/
# Kept for backwards compatability
genman: man/containerd.1 man/ctr.1
man/containerd.1: FORCE
@echo "$(WHALE) $@"
go run cmd/gen-manpages/main.go containerd man/
man/ctr.1: FORCE
@echo "$(WHALE) $@"
go run cmd/gen-manpages/main.go ctr man/
man/%: docs/man/%.md FORCE
@echo "$(WHALE) $<"
@echo "$(WHALE) $@"
go-md2man -in "$<" -out "$@"
define installmanpage