]> git.sur5r.net Git - cc65/blob - doc/Makefile
Document the symbols section and the new -D and --define options
[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  = apple2.sgml     \
9         ar65.sgml       \
10         atari.sgml      \
11         atmos.sgml      \
12         c128.sgml       \
13         c16.sgml        \
14         c64.sgml        \
15         ca65.sgml       \
16         ca65html.sgml   \
17         cbm610.sgml     \
18         cc65.sgml       \
19         cl65.sgml       \
20         co65.sgml       \
21         coding.sgml     \
22         da65.sgml       \
23         debugging.sgml  \
24         dio.sgml        \
25         funcref.sgml    \
26         geos.sgml       \
27         index.sgml      \
28         intro.sgml      \
29         ld65.sgml       \
30         library.sgml    \
31         lynx.sgml       \
32         nes.sgml        \
33         plus4.sgml      \
34         vic20.sgml
35
36 TXT   = $(SGML:.sgml=.txt)
37 HTML  = $(SGML:.sgml=.html)
38 INFO  = $(SGML:.sgml=.info)
39 DVI   = $(SGML:.sgml=.dvi)
40 TEX   = $(SGML:.sgml=.tex)
41
42 # ------------------------------------------------------------------------------
43 # Rules to make targets
44
45 %.txt:  %.sgml
46         sgml2txt $<
47
48 %.html: %.sgml
49         sgml2html --split=1 $<
50
51 %.info: %.sgml
52         sgml2info $<
53
54 %.dvi:  %.sgml
55         sgml2latex $<
56
57 %.tex:  %.sgml
58         sgml2latex --output=tex $<
59
60 # ------------------------------------------------------------------------------
61 # Targets
62
63 .PHONY: all
64 all:    txt html info dvi
65
66 .PHONY: txt
67 txt:    $(TXT)
68
69 .PHONY: html
70 html:   $(HTML)
71
72 .PHONY: info
73 info:   $(INFO)
74
75 .PHONY: dvi
76 dvi:    $(DVI)
77
78 .PHONY: tex
79 tex:    $(TEX)
80
81 # The index.html target is special, since it does not get splitted
82 index.html:     index.sgml
83         sgml2html --split=0 $<
84
85 clean:
86         rm -f *~
87
88 zap:    clean
89         rm -f $(TXT) $(HTML) $(INFO) $(DVI) $(TEX) *.html *.info-* *.man
90
91 # ------------------------------------------------------------------------------
92 # Special target rules
93
94 coding.html:    coding.sgml
95         sgml2html --split=0 $<
96
97 funcref.html:   funcref.sgml
98         sgml2html --split=2 $<
99
100 index.html:     index.sgml
101         sgml2html --split=0 $<
102
103 # ------------------------------------------------------------------------------
104 # Make the dependencies
105
106 .PHONY: depend dep
107 depend dep:     $(OBJS:.o=.c)
108         @echo "Creating dependency information"
109         $(CC) -MM $^ > .depend
110
111