]> git.donarmstrong.com Git - lilypond.git/blob - stepmake/stepmake/help2man-rules.make
the distributed help2man is outdated and sucky. Use the Debian version instead.
[lilypond.git] / stepmake / stepmake / help2man-rules.make
1 # The distributed help2man sucks; use the Debian version instead.
2 ifeq ($(PYTHON),$(TARGET_PYTHON))
3 HELP2MAN_COMMAND = help2man $< > $@
4 else
5 HELP2MAN_COMMAND = help2man "env $$(basename $$(head -1 $<)) $<" > $@
6 endif
7
8 ifeq ($(strip $(CROSS)),no)
9 $(outdir)/%.1: $(outdir)/% $(buildscript-dir)/help2man
10         $(HELP2MAN_COMMAND)
11 else
12 # When cross building, some manpages will not build because the
13 # executable does not run.  We assume the manpages to be generated
14 # during a previous compile for the build host, with config=for-build,
15 # in the directory $(outdir)-for-build.
16 $(outdir)/%.1: $(outdir:%=%-for-build)/%.1
17         cp $< $@
18 endif
19
20 ifneq ($(outdir),./out)
21 $(outdir)/%.1: out/%.1
22         cp $< $@
23 endif