14703a348ea41648e68bc60a570c7cad40e0a6c2
[YACASL2.git] / doc / Makefile
1 RMR := $(RM) -r
2 SED := sed
3
4 DOCS := install manual
5 CSS := style.css
6
7 prefix ?= ~
8 infodir ?= $(prefix)/share/info
9
10 .PHONY: base all info html htmls pdf distclean clean
11
12 base: install.txt info html
13
14 all: base htmls pdf
15
16 info: yacasl2.info
17
18 html: $(addsuffix .html,$(DOCS))
19         for f in $^; do $(SED) -i '' -e 's!dir\.html#Top!\.\./!g' $$f; done
20
21 htmls: $(addsuffix _html,$(DOCS))
22         for d in $^; do $(SED) -i '' -e 's!\.\./dir/index\.html!\.\./\.\./!g' $$d/index.html; done
23
24 pdf: $(addsuffix .pdf,$(DOCS))
25
26 yacasl2.info: manual.texi
27         $(MAKEINFO) $(MAKEINFO_FLAGS) $<
28
29 # makeで作成されたドキュメントはすべて削除
30 distclean: clean texinfo-distclean
31         $(RM) install.txt *.info *.html *_html *.pdf
32
33 # make baseで作成されたドキュメントは残す
34 clean: texinfo-clean
35         $(RM) *.bak
36
37 include texinfo.mk
38
39 include install-info.mk