X-Git-Url: http://j8takagi.net/cgi-bin/gitweb.cgi?p=YACASL2.git;a=blobdiff_plain;f=doc%2FMakefile;h=dc8c3787f2b2f4ae55fe75a3bad106ecd98b89b9;hp=3c9b3be95e58ccf28d1b5756a44cad7d7e0d3af9;hb=7fbde1700bbe9d8f779033ad3b842d3dceb3e1c6;hpb=b3f91f53a0a715249df3582be19d064f831619a0 diff --git a/doc/Makefile b/doc/Makefile index 3c9b3be..dc8c378 100644 --- a/doc/Makefile +++ b/doc/Makefile @@ -1,48 +1,46 @@ -DOCNAME = yacasl2 -SRC = $(DOCNAME).texi -CSS = style.css +RMR := $(RM) -r +SED := sed -MV = mv -CP = cp -MKDIR = mkdir -RMRF = rm -rf -PTEX = ptex -TEXI2DVI = texi2dvi -DVI2PDF = dvipdfmx -MAKEINFO = makeinfo +DOCS := install manual +CSS := style.css -.PHONY: doc info htmlnosplit html pdf clean clean_docs clean_tex_tmp +prefix ?= ~ +infodir ?= $(prefix)/share/info -.INTERMEDIATE: $(DOCNAME).dvi +TEXITARGETS := install.html manual.html -doc: info htmlnosplit html pdf +INSTALL-INFO-TARGETS := yacasl2.info -info: $(DOCNAME).info +.PHONY: base all info html htmls pdf casl2_spec distclean clean -htmlnosplit: $(DOCNAME).html - $(MV) $< index.html +base: install.txt info html -html: $(SRC) $(CSS) - if test ! -e $@; then $(MKDIR) $@; fi; - $(CP) $(CSS) $@/$(CSS) - $(MAKEINFO) -o $@ --html --css-ref=$(CSS) $(SRC) +all: base htmls pdf casl2_spec -pdf: $(DOCNAME).pdf +info: yacasl2.info -$(DOCNAME).html: $(SRC) $(CSS) - $(MAKEINFO) -o $@ --no-split --html --css-include=$(CSS) $(SRC) +html: $(addsuffix .html,$(DOCS)) -$(DOCNAME).pdf: $(DOCNAME).dvi - $(DVI2PDF) $^ +htmls: $(addsuffix _html,$(DOCS)) -$(DOCNAME).dvi: $(SRC) - TEX=$(PTEX) $(TEXI2DVI) -q --texinfo=@afourpaper -o $@ $< - @$(MAKE) clean_tex_tmp +pdf: $(addsuffix .pdf,$(DOCS)) -clean: clean_docs clean_tex_tmp +casl2_spec: + $(MAKE) -C casl2_spec -clean_docs: - @$(RMRF) html $(DOCNAME).info $(DOCNAME).pdf $(DOCNAME).html +yacasl2.info: manual.texi + $(MAKEINFO) $(MAKEINFO_FLAGS) $< -clean_tex_tmp: - @$(RMRF) $(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で作成されたドキュメントはすべて削除 +distclean: clean texinfo-distclean + $(RM) install.txt *.info *.html *_html *.pdf + $(MAKE) -C casl2_spec distclean + +# make baseで作成されたドキュメントは残す +clean: texinfo-clean + $(RM) *.bak + $(MAKE) -C casl2_spec clean + +include texinfo.mk + +include install-info.mk