9f66c4acde8c55bae9188381f3b390dea5f9c6a8
[ctsim.git] / doc / Makefile.am
1 docs := ctsim.tex texhelp.sty psbox.tex logo.eps logo.gif ctsim-sgp.tex ctsim-concepts.tex ctsim-gui.tex ctsim-install.tex ctsim-textui.tex ctsim-web.tex alphacalc.eps alphacalc.gif divergent.eps divergent.gif equiangular.eps equiangular.gif equilinear.eps equilinear.gif scangeometry.eps scangeometry.gif tex2rtf.ini ctsim.hpj bullet.bmp verbatim.sty mytitle.sty makeidx.sty mysober.sty fancyhea.sty ctsim-latex.bib ctsim-tex2rtf.bib
2
3 pkg=ctsim
4
5 EXTRA_DIST = $(docs) html
6
7 CLEANFILES=$(pkg).ps $(pkg)*.html $(pkg).hhc $(pkg).hhp $(pkg).hhk \
8         $(pkg).bib $(pkg).zip *.aux *.log *~ \#*~ \#*\# \.*~ \
9         $(pkg).ilg $(pkg).ind
10
11 all-local: htmlhelp html pdf
12
13 install-data-hook: $(pkg).htb
14         install -g root -o root -m 0644 $(pkg).htb $(datadir)
15
16 .PHONY: pdf
17 pdf: ctsim.dvi
18 $(pkg).pdf: $(pkg).dvi
19         dvipdfm $(pkg)
20
21 .PHONY: dvi
22 dvi: $(pkg).dvi
23 $(pkg).dvi: $(docs)
24         cp $(pkg)-latex.bib $(pkg).bib
25         latex $(pkg) > /dev/null
26         bibtex $(pkg) > /dev/null
27         latex $(pkg) > /dev/null
28         makeindex $(pkg) > /dev/null
29         latex $(pkg) > /dev/null
30
31 .PHONY: winhelp
32 winhelp: $(docs)
33         rm -f $(pkg).rtf $(pkg).cnt
34         cp $(pkg)-tex2rtf.bib $(pkg).bib
35         tex2rtf $(pkg).tex $(pkg).rtf -winhelp
36         hcw /c /m /e $(pkg).hpj
37         mv $(PKG).HLP $(pkg).hlp
38         cp $(pkg).hlp $(pkg).cnt ../msvc/$(pkg)/
39
40 .PHONY: htmlhelp
41 htmlhelp: $(docs)
42         rm -f $(pkg)*.html $(pkg).hhp $(pkg).hhc $(pkg).hhk $(pkg).zip
43         cp $(pkg)-tex2rtf.bib $(pkg).bib
44         tex2rtf $(pkg).tex $(pkg).html -html  > /dev/null
45         zip -q $(pkg).zip *.html *.gif $(pkg).hh[pck]
46         mv $(pkg).zip $(pkg).htb
47
48 html: htmlhelp
49         rm -rf html
50         mkdir html
51         cp *.gif html
52         mv *.html html
53
54