small fix
[fw/sdcc] / doc / Makefile
1 include ../Makefile.common
2
3 MANUAL = sdccman
4 TSS = test_suite_spec
5
6 all: $(MANUAL).html $(MANUAL).pdf $(MANUAL).txt \
7         $(TSS).html $(TSS).pdf $(TSS).txt
8
9 install:
10         $(INSTALL) -d $(docdir)
11         cp -rf *.html *.txt *.pdf $(MANUAL).html $(TSS).html z80 avr $(docdir)
12
13 uninstall:
14         rm -rf $(docdir)
15
16
17 $(MANUAL).html: $(MANUAL).tex $(MANUAL).ind ;#$(MANUAL).glo
18         mkdir -p $@
19         latex2html -split 5 -show_section_numbers -dir $(MANUAL).html $(MANUAL)
20
21 $(TSS).html: $(TSS).tex
22         mkdir -p $@
23         latex2html -split 0 -dir $(TSS).html $(TSS)
24
25 %.txt: %.lyx
26         lyx -e text $<
27
28 %.pdf: %.tex %.dvi
29         which pdflatex > /dev/null && pdflatex $* || dvipdf $*
30
31 %.dvi: %.tex
32         latex $<
33
34 %.tex: %.lyx
35         lyx -e latex $<
36
37 %.ind: %.dvi
38         makeindex -s l2hidx.ist $*
39
40 %.glo: %.dvi
41         # the glossary, not implemented yet
42         # makeindex -s l2hglo.ist -o $@ $<
43
44 # Deleting all files created by building the program
45 # --------------------------------------------------
46 clean:
47 # The directories are still in CVS, so don't delete them
48 #       rm -rf $(MANUAL).html $(TSS).html
49         rm -f $(MANUAL).html/* $(TSS).html/*
50         rm -f $(MANUAL).txt $(TSS).txt *.pdf *.dvi *.tex *.ind *.glo *.aux *.idx *.ilg *.log *.toc
51
52 # Deleting all files created by configuring or building the program
53 # -----------------------------------------------------------------
54 distclean: clean
55
56 # Like clean but some files may still exist
57 # -----------------------------------------
58 mostlyclean: clean
59
60 # Deleting everything that can reconstructed by this Makefile. It deletes
61 # everything deleted by distclean plus files created by bison, etc.
62 # -----------------------------------------------------------------------
63 realclean: distclean
64