X-Git-Url: http://j8takagi.net/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=doc%2FMakefile;h=7d575e24805d28f915d766e3d309b0dd2017f645;hb=1906078707b52a1534aba7c18630f9fe7a33b3ae;hp=200853981fed2ac7a1e5e206b608fdbe1c4e56ab;hpb=bdbb4708c0434ef7085486c381902f69fbbaf110;p=YACASL2.git diff --git a/doc/Makefile b/doc/Makefile index 2008539..7d575e2 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -1,42 +1,35 @@ -DOCNAME = yacasl2 -SRC = $(DOCNAME).texi -CSS = style.css +RMR := $(RM) -r -PTEX = ptex -TEXI2DVI = texi2dvi -DVI2PDF = dvipdfmx -MAKEINFO = makeinfo +DOCS := install manual +CSS := style.css -.PHONY: all htmlnosplit pdf clean +prefix ?= ~ +infodir ?= $(prefix)/share/info -.INTERMEDIATE: $(DOCNAME).dvi +.PHONY: base all info html htmls pdf distclean clean -doc: info htmlnosplit html pdf +base: install.txt info html -htmlnosplit: $(DOCNAME).html +all: base htmls pdf -html: $(SRC) $(CSS) - @if test ! -s $@; then mkdir $@; fi; - @cp $(CSS) $@/$(CSS) - @$(MAKEINFO) -o $@ --html --css-ref=style.css $(SRC) +info: yacasl2.info -pdf: $(DOCNAME).pdf +html: $(addsuffix .html,$(DOCS)) -info: $(DOCNAME).info +htmls: $(addsuffix _html,$(DOCS)) -$(DOCNAME).info: $(SRC) - @$(MAKEINFO) -o $@ $^ +pdf: $(addsuffix .pdf,$(DOCS)) -$(DOCNAME).html: $(SRC) $(CSS) - @$(MAKEINFO) -o $@ --no-split --html --css-include=$(CSS) $(SRC) +yacasl2.info: manual.texi + $(MAKEINFO) $(MAKEINFO_FLAGS) $< -$(DOCNAME).pdf: $(DOCNAME).dvi - @$(DVI2PDF) $^ +# makeで作成されたドキュメントはすべて削除 +distclean: clean texinfo-distclean + $(RM) install.txt *.info *.html *_html *.pdf -$(DOCNAME).dvi: $(SRC) - @TEX=$(PTEX) $(TEXI2DVI) -q --texinfo=@afourpaper -o $@ $< - @rm -rf $(DOCNAME).aux $(DOCNAME).cp $(DOCNAME).cps $(DOCNAME).fn $(DOCNAME).ky $(DOCNAME).log $(DOCNAME).pg $(DOCNAME).pgs $(DOCNAME).tmp $(DOCNAME).toc $(DOCNAME).tp $(DOCNAME).vr +# make baseで作成されたドキュメントは残す +clean: texinfo-clean -clean: - @rm -rf html $(DOCNAME).info $(DOCNAME).pdf $(DOCNAME).html $(DOCNAME).dvi - @rm -rf $(DOCNAME).aux $(DOCNAME).cp $(DOCNAME).cps $(DOCNAME).fn $(DOCNAME).ky $(DOCNAME).log $(DOCNAME).pg $(DOCNAME).pgs $(DOCNAME).tmp $(DOCNAME).toc $(DOCNAME).tp $(DOCNAME).vr +include texinfo.mk + +include install-info.mk