]> git.netwichtig.de Git - user/henk/code/exim.git/blob - doc/doc-docbook/Makefile
First pass update for 4.60 documentation.
[user/henk/code/exim.git] / doc / doc-docbook / Makefile
1 # $Cambridge: exim/doc/doc-docbook/Makefile,v 1.2 2005/11/10 12:30:13 ph10 Exp $
2
3 # Make file for Exim documentation from Asciidoc source.
4
5 notarget:;    @echo "** You must specify a target, in the form x.y, where x is 'filter', 'spec',"
6               @echo "** or 'test', and y is 'xml', 'fo', 'ps', 'pdf', 'html', 'txt', or 'info'."
7               @echo "** One other possible target is 'exim.8'".
8               exit 1
9
10
11 ############################## MAN PAGE ################################
12
13 exim.8: spec.xml
14               ./x2man
15
16 ########################################################################
17
18
19 ############################### FILTER #################################
20
21 filter.xml:   filter.ascd MyAsciidoc.conf
22               asciidoc -d book -b docbook -f MyAsciidoc.conf filter.ascd
23
24 filter-fo.xml: filter.xml Pre-xml
25               Pre-xml -bookinfo <filter.xml >filter-fo.xml
26
27 filter-html.xml: filter.xml Pre-xml
28               Pre-xml -html <filter.xml >filter-html.xml
29
30 filter-txt.xml: filter.xml Pre-xml
31               Pre-xml -ascii -html <filter.xml >filter-txt.xml
32
33 filter.fo:    filter-fo.xml MyStyle-filter-fo.xsl MyStyle-fo.xsl MyStyle.xsl
34               /bin/rm -rf filter.fo filter-fo.fo
35               xmlto -x MyStyle-filter-fo.xsl fo filter-fo.xml
36               /bin/mv -f filter-fo.fo filter.fo
37
38 filter.ps:    filter.fo
39               fop filter.fo -ps filter-tmp.ps
40               mv filter-tmp.ps filter.ps
41
42 filter.pdf:   filter.fo
43               fop filter.fo -pdf filter-tmp.pdf
44               mv filter-tmp.pdf filter.pdf
45
46 filter.html:  filter-html.xml TidyHTML-filter MyStyle-nochunk-html.xsl MyStyle-html.xsl MyStyle.xsl
47               /bin/rm -rf filter.html filter-html.html
48               xmlto -x MyStyle-nochunk-html.xsl html-nochunks filter-html.xml
49               /bin/mv -f filter-html.html filter.html
50               ./TidyHTML-filter
51
52 filter.txt:   filter-txt.xml Tidytxt MyStyle-txt-html.xsl MyStyle-html.xsl MyStyle.xsl
53               /bin/rm -rf filter-txt.html
54               xmlto -x MyStyle-txt-html.xsl html-nochunks filter-txt.xml
55               w3m -dump filter-txt.html >filter.txt
56
57 # I have not found a way of making docbook2texi write its output anywhere
58 # other than the file name that it makes up. The --to-stdout option does not
59 # work.
60
61 filter.info:  filter-txt.xml
62               docbook2texi filter-txt.xml
63               perl -ne 's/conceptindex/cindex/;s/optionindex/findex/;print;' \
64                 <exim_filtering.texi | Tidytxt >filter.texinfo
65               /bin/rm -rf exim_filtering.texi
66               makeinfo -o filter.info filter.texinfo
67
68 ########################################################################
69
70
71 ################################ SPEC ##################################
72
73 spec.xml:     spec.ascd MyAsciidoc.conf
74               asciidoc -d book -b docbook -f MyAsciidoc.conf spec.ascd
75
76 spec-fo.xml:  spec.xml Pre-xml
77               Pre-xml <spec.xml >spec-fo.xml
78
79 spec-html.xml: spec.xml Pre-xml
80               Pre-xml -abstract -html -oneindex <spec.xml >spec-html.xml
81
82 spec-txt.xml: spec.xml Pre-xml
83               Pre-xml -abstract -ascii -html -noindex <spec.xml >spec-txt.xml
84
85 spec.fo:      spec-fo.xml MyStyle-spec-fo.xsl MyStyle-fo.xsl MyStyle.xsl MyTitleStyle.xsl
86               /bin/rm -rf spec.fo spec-fo.fo
87               xmlto -x MyStyle-spec-fo.xsl fo spec-fo.xml
88               /bin/mv -f spec-fo.fo spec.fo
89
90 spec.ps:      spec.fo
91               FOP_OPTS=-Xmx512m fop spec.fo -ps spec-tmp.ps
92               mv spec-tmp.ps spec.ps
93
94 spec.pdf:     spec.fo
95               FOP_OPTS=-Xmx512m fop spec.fo -pdf spec-tmp.pdf
96               mv spec-tmp.pdf spec.pdf
97
98 spec.html:    spec-html.xml TidyHTML-spec MyStyle-chunk-html.xsl MyStyle-html.xsl MyStyle.xsl
99               /bin/rm -rf spec.html
100               xmlto -x MyStyle-chunk-html.xsl -o spec.html html spec-html.xml
101               ./TidyHTML-spec
102
103 spec.txt:     spec-txt.xml Tidytxt MyStyle-txt-html.xsl MyStyle-html.xsl MyStyle.xsl
104               /bin/rm -rf spec-txt.html
105               xmlto -x MyStyle-txt-html.xsl html-nochunks spec-txt.xml
106               w3m -dump spec-txt.html | Tidytxt >spec.txt
107
108 # I have not found a way of making docbook2texi write its output anywhere
109 # other than the file name that it makes up. The --to-stdout option does not
110 # work.
111
112 spec.info:    spec-txt.xml
113               docbook2texi spec-txt.xml
114               perl -ne 's/conceptindex/cindex/;s/optionindex/findex/;print;' \
115                 <the_exim_mta.texi >spec.texinfo
116               /bin/rm -rf the_exim_mta.texi
117               makeinfo -o spec.info spec.texinfo
118
119 ########################################################################
120
121
122 ################################ TEST ##################################
123
124 # These targets (similar to the above)  are for running little tests.
125
126 test.xml:     test.ascd MyAsciidoc.conf
127               asciidoc -d book -b docbook -f MyAsciidoc.conf test.ascd
128
129 test-fo.xml:  test.xml Pre-xml
130               ./Pre-xml <test.xml >test-fo.xml
131
132 test-html.xml: test.xml Pre-xml
133               ./Pre-xml -abstract -html -oneindex <test.xml >test-html.xml
134
135 test-txt.xml: test.xml Pre-xml
136               ./Pre-xml -abstract -ascii -html -noindex <test.xml >test-txt.xml
137
138 test.fo:      test-fo.xml MyStyle-spec-fo.xsl MyStyle-fo.xsl MyStyle.xsl MyTitleStyle.xsl
139               /bin/rm -rf test.fo test-fo.fo
140               xmlto -x MyStyle-spec-fo.xsl fo test-fo.xml
141               /bin/mv -f test-fo.fo test.fo
142
143 test.ps:      test.fo
144               fop test.fo -ps test-tmp.ps
145               mv test-tmp.ps test.ps
146
147 test.pdf:     test.fo
148               fop test.fo -pdf test-tmp.pdf
149               mv test-tmp.pdf test.pdf
150
151 test.html:    test-html.xml MyStyle-nochunk-html.xsl MyStyle-html.xsl MyStyle.xsl
152               /bin/rm -rf test.html test-html.html
153               xmlto -x MyStyle-nochunk-html.xsl html-nochunks test-html.xml
154               /bin/mv -f test-html.html test.html
155
156 test.txt:     test-txt.xml Tidytxt MyStyle-txt-html.xsl MyStyle-html.xsl MyStyle.xsl
157               /bin/rm -rf test-txt.html
158               xmlto -x MyStyle-txt-html.xsl html-nochunks test-txt.xml
159               w3m -dump test-txt.html | Tidytxt >test.txt
160
161 # I have not found a way of making docbook2texi write its output anywhere
162 # other than the file name that it makes up. The --to-stdout option does not
163 # work.
164
165 test.info:    test-txt.xml
166               docbook2texi test-txt.xml
167               perl -ne 's/conceptindex/cindex/;s/optionindex/findex/;print;' \
168                 <short_title.texi >test.texinfo
169               /bin/rm -rf short_title.texi
170               makeinfo -o test.info test.texinfo
171
172 ########################################################################
173
174
175 ################################ CLEAN #################################
176
177 clean:; /bin/rm -rf exim.8 \
178               filter*.xml spec*.xml test*.xml \
179               *.fo *.html *.pdf *.ps \
180               filter*.txt spec*.txt test*.txt \
181               *.info* *.texinfo *.texi
182
183 ########################################################################