nicer make target for the pdf conversion

This commit is contained in:
Daniel Stenberg 2003-08-12 09:08:05 +00:00
parent b46745759b
commit c46da65263

View File

@ -124,20 +124,18 @@ EXTRA_DIST = $(man_MANS) $(HTMLPAGES) index.html $(PDFPAGES)
MAN2HTML= gnroff -man $< | man2html >$@ MAN2HTML= gnroff -man $< | man2html >$@
SUFFIXES = .1 .3 .html SUFFIXES = .3 .html
html: $(HTMLPAGES) html: $(HTMLPAGES)
.3.html: .3.html:
$(MAN2HTML) $(MAN2HTML)
.1.html: pdf: $(PDFPAGES)
$(MAN2HTML)
pdf: .3.pdf:
for file in $(man_MANS); do \ @(foo=`echo $@ | sed -e 's/\.[0-9]$$//g'`; \
foo=`echo $$file | sed -e 's/\.[0-9]$$//g'`; \ groff -Tps -man $< >$$foo.ps; \
groff -Tps -man $$file >$$foo.ps; \ ps2pdf $$foo.ps $@; \
ps2pdf $$foo.ps $$foo.pdf; \ rm $$foo.ps; \
rm $$foo.ps; \ echo "converted $< to $@")
done