]> git.sur5r.net Git - cc65/blob - doc/Makefile
Added c64.sgml
[cc65] / doc / Makefile
1 #
2 # Makefile for the cc65 documentation
3 #
4
5
6 # Default for the compiler lib search path as compiler define
7
8 SGML  = ar65.sgml       \
9         c64.sgml        \
10         ca65.sgml       \
11         cc65.sgml       \
12         cl65.sgml       \
13         co65.sgml       \
14         coding.sgml     \
15         da65.sgml       \
16         debugging.sgml  \
17         dio.sgml        \
18         funcref.sgml    \
19         geos.sgml       \
20         index.sgml      \
21         intro.sgml      \
22         ld65.sgml       \
23         library.sgml
24
25 TXT   = $(SGML:.sgml=.txt)
26 HTML  = $(SGML:.sgml=.html)
27 INFO  = $(SGML:.sgml=.info)
28 DVI   = $(SGML:.sgml=.dvi)
29 TEX   = $(SGML:.sgml=.tex)
30
31 # ------------------------------------------------------------------------------
32 # Rules to make targets
33
34 %.txt:  %.sgml
35         sgml2txt $<
36
37 %.html: %.sgml
38         sgml2html --split=1 $<
39
40 %.info: %.sgml
41         sgml2info $<
42
43 %.dvi:  %.sgml
44         sgml2latex $<
45
46 %.tex:  %.sgml
47         sgml2latex --output=tex $<
48
49 funcref.html:   funcref.sgml
50         sgml2html --split=2 $<
51
52 # ------------------------------------------------------------------------------
53 # Targets
54
55 .PHONY: all
56 all:    txt html info dvi
57
58 .PHONY: txt
59 txt:    $(TXT)
60
61 .PHONY: html
62 html:   $(HTML)
63
64 .PHONY: info
65 info:   $(INFO)
66
67 .PHONY: dvi
68 dvi:    $(DVI)
69
70 .PHONY: tex
71 tex:    $(TEX)
72
73 # The index.html target is special, since it does not get splitted
74 index.html:     index.sgml
75         sgml2html --split=0 $<
76
77 clean:
78         rm -f *~
79
80 zap:    clean
81         rm -f $(TXT) $(HTML) $(INFO) $(DVI) $(TEX) *.html *.info-* *.man
82
83 # ------------------------------------------------------------------------------
84 # Make the dependencies
85
86 .PHONY: depend dep
87 depend dep:     $(OBJS:.o=.c)
88         @echo "Creating dependency information"
89         $(CC) -MM $^ > .depend
90
91