Update runtime files
[MacVim/KaoriYa.git] / runtime / doc / Makefile
blob2f697508b0ea2e713ec0ed4ad698b71e1e59f2dd
2 # Makefile for the Vim documentation on Unix
4 # If you get "don't know how to make scratch", first run make in the source
5 # directory. Or remove the include below.
7 AWK = awk
9 # Set to $(VIMTARGET) when executed from src/Makefile.
10 VIMEXE = vim
12 # include the config.mk from the source directory. It's only needed to set
13 # AWK, used for "make html". Comment this out if the include gives problems.
14 include ../../src/auto/config.mk
16 DOCS = \
17 arabic.txt \
18 autocmd.txt \
19 change.txt \
20 cmdline.txt \
21 debug.txt \
22 debugger.txt \
23 develop.txt \
24 diff.txt \
25 digraph.txt \
26 editing.txt \
27 eval.txt \
28 farsi.txt \
29 filetype.txt \
30 fold.txt \
31 ft_ada.txt \
32 ft_sql.txt \
33 gui.txt \
34 gui_w16.txt \
35 gui_w32.txt \
36 gui_x11.txt \
37 hangulin.txt \
38 hebrew.txt \
39 help.txt \
40 howto.txt \
41 if_cscop.txt \
42 if_mzsch.txt \
43 if_ole.txt \
44 if_perl.txt \
45 if_pyth.txt \
46 if_ruby.txt \
47 if_sniff.txt \
48 if_tcl.txt \
49 indent.txt \
50 index.txt \
51 insert.txt \
52 intro.txt \
53 map.txt \
54 mbyte.txt \
55 message.txt \
56 mlang.txt \
57 motion.txt \
58 netbeans.txt \
59 options.txt \
60 os_390.txt \
61 os_amiga.txt \
62 os_beos.txt \
63 os_dos.txt \
64 os_mac.txt \
65 os_mint.txt \
66 os_msdos.txt \
67 os_os2.txt \
68 os_qnx.txt \
69 os_risc.txt \
70 os_unix.txt \
71 os_vms.txt \
72 os_win32.txt \
73 pattern.txt \
74 pi_getscript.txt \
75 pi_gzip.txt \
76 pi_netrw.txt \
77 pi_paren.txt \
78 pi_spec.txt \
79 pi_tar.txt \
80 pi_vimball.txt \
81 pi_zip.txt \
82 print.txt \
83 quickfix.txt \
84 quickref.txt \
85 quotes.txt \
86 recover.txt \
87 remote.txt \
88 repeat.txt \
89 rileft.txt \
90 russian.txt \
91 scroll.txt \
92 sign.txt \
93 spell.txt \
94 sponsor.txt \
95 starting.txt \
96 syntax.txt \
97 tabpage.txt \
98 tagsrch.txt \
99 term.txt \
100 tips.txt \
101 todo.txt \
102 uganda.txt \
103 undo.txt \
104 usr_01.txt \
105 usr_02.txt \
106 usr_03.txt \
107 usr_04.txt \
108 usr_05.txt \
109 usr_06.txt \
110 usr_07.txt \
111 usr_08.txt \
112 usr_09.txt \
113 usr_10.txt \
114 usr_11.txt \
115 usr_12.txt \
116 usr_20.txt \
117 usr_21.txt \
118 usr_22.txt \
119 usr_23.txt \
120 usr_24.txt \
121 usr_25.txt \
122 usr_26.txt \
123 usr_27.txt \
124 usr_28.txt \
125 usr_29.txt \
126 usr_30.txt \
127 usr_31.txt \
128 usr_32.txt \
129 usr_40.txt \
130 usr_41.txt \
131 usr_42.txt \
132 usr_43.txt \
133 usr_44.txt \
134 usr_45.txt \
135 usr_90.txt \
136 usr_toc.txt \
137 various.txt \
138 version4.txt \
139 version5.txt \
140 version6.txt \
141 version7.txt \
142 vi_diff.txt \
143 visual.txt \
144 windows.txt \
145 workshop.txt
147 HTMLS = \
148 arabic.html \
149 autocmd.html \
150 change.html \
151 cmdline.html \
152 debug.html \
153 debugger.html \
154 develop.html \
155 diff.html \
156 digraph.html \
157 editing.html \
158 eval.html \
159 farsi.html \
160 filetype.html \
161 fold.html \
162 ft_ada.html \
163 ft_sql.html \
164 gui.html \
165 gui_w16.html \
166 gui_w32.html \
167 gui_x11.html \
168 hangulin.html \
169 hebrew.html \
170 howto.html \
171 if_cscop.html \
172 if_mzsch.html \
173 if_ole.html \
174 if_perl.html \
175 if_pyth.html \
176 if_ruby.html \
177 if_sniff.html \
178 if_tcl.html \
179 indent.html \
180 index.html \
181 insert.html \
182 intro.html \
183 map.html \
184 mbyte.html \
185 message.html \
186 mlang.html \
187 motion.html \
188 netbeans.html \
189 options.html \
190 os_390.html \
191 os_amiga.html \
192 os_beos.html \
193 os_dos.html \
194 os_mac.html \
195 os_mint.html \
196 os_msdos.html \
197 os_os2.html \
198 os_qnx.html \
199 os_risc.html \
200 os_unix.html \
201 os_vms.html \
202 os_win32.html \
203 pattern.html \
204 pi_getscript.html \
205 pi_gzip.html \
206 pi_netrw.html \
207 pi_paren.html \
208 pi_spec.html \
209 pi_tar.html \
210 pi_vimball.html \
211 pi_zip.html \
212 print.html \
213 quickfix.html \
214 quickref.html \
215 quotes.html \
216 recover.html \
217 remote.html \
218 repeat.html \
219 rileft.html \
220 russian.html \
221 scroll.html \
222 sign.html \
223 spell.html \
224 sponsor.html \
225 starting.html \
226 syntax.html \
227 tabpage.html \
228 tags.html \
229 tagsrch.html \
230 term.html \
231 tips.html \
232 todo.html \
233 uganda.html \
234 undo.html \
235 usr_01.html \
236 usr_02.html \
237 usr_03.html \
238 usr_04.html \
239 usr_05.html \
240 usr_06.html \
241 usr_07.html \
242 usr_08.html \
243 usr_09.html \
244 usr_10.html \
245 usr_11.html \
246 usr_12.html \
247 usr_20.html \
248 usr_21.html \
249 usr_22.html \
250 usr_23.html \
251 usr_24.html \
252 usr_25.html \
253 usr_26.html \
254 usr_27.html \
255 usr_28.html \
256 usr_29.html \
257 usr_30.html \
258 usr_31.html \
259 usr_32.html \
260 usr_40.html \
261 usr_41.html \
262 usr_42.html \
263 usr_43.html \
264 usr_44.html \
265 usr_45.html \
266 usr_90.html \
267 usr_toc.html \
268 various.html \
269 version4.html \
270 version5.html \
271 version6.html \
272 version7.html \
273 vi_diff.html \
274 vimindex.html \
275 visual.html \
276 windows.html \
277 workshop.html
279 CONVERTED = \
280 vim-fr.UTF-8.1 \
281 evim-fr.UTF-8.1 \
282 vimdiff-fr.UTF-8.1 \
283 vimtutor-fr.UTF-8.1 \
284 xxd-fr.UTF-8.1 \
285 vim-it.UTF-8.1 \
286 evim-it.UTF-8.1 \
287 vimdiff-it.UTF-8.1 \
288 vimtutor-it.UTF-8.1 \
289 xxd-it.UTF-8.1 \
290 vim-pl.UTF-8.1 \
291 evim-pl.UTF-8.1 \
292 vimdiff-pl.UTF-8.1 \
293 vimtutor-pl.UTF-8.1 \
294 xxd-pl.UTF-8.1 \
295 vim-ru.UTF-8.1 \
296 evim-ru.UTF-8.1 \
297 vimdiff-ru.UTF-8.1 \
298 vimtutor-ru.UTF-8.1 \
299 xxd-ru.UTF-8.1
301 .SUFFIXES:
302 .SUFFIXES: .c .o .txt .html
304 all: tags vim.man evim.man vimdiff.man vimtutor.man xxd.man $(CONVERTED)
306 # Use Vim to generate the tags file. Can only be used when Vim has been
307 # compiled and installed. Supports multiple languages.
308 vimtags: $(DOCS)
309 $(VIMEXE) -u NONE -esX -c "helptags ++t ." -c quit
311 # Use "doctags" to generate the tags file. Only works for English!
312 tags: doctags $(DOCS)
313 ./doctags $(DOCS) | LANG=C LC_ALL=C sort >tags
314 uniq -d -2 tags
316 doctags: doctags.c
317 $(CC) doctags.c -o doctags
319 vim.man: vim.1
320 nroff -man vim.1 | sed -e s/.\b//g > vim.man
322 evim.man: evim.1
323 nroff -man evim.1 | sed -e s/.\b//g > evim.man
325 vimdiff.man: vimdiff.1
326 nroff -man vimdiff.1 | sed -e s/.\b//g > vimdiff.man
328 vimtutor.man: vimtutor.1
329 nroff -man vimtutor.1 | sed -e s/.\b//g > vimtutor.man
331 xxd.man: xxd.1
332 nroff -man xxd.1 | sed -e s/.\b//g > xxd.man
334 uganda.nsis.txt: uganda.txt
335 sed -e 's/[ ]*\*[-a-zA-Z0-9.]*\*//g' -e 's/vim:tw=78://' \
336 uganda.txt | uniq >uganda.nsis.txt
338 # Awk version of .txt to .html conversion.
339 html: noerrors tags tags.ref $(HTMLS)
340 @if test -f errors.log; then more errors.log; fi
342 noerrors:
343 -rm -f errors.log
345 .txt.html:
346 $(AWK) -f makehtml.awk $< >$@
348 # index.html is the starting point for HTML, but for the help files it is
349 # help.txt. Therefore use vimindex.html for index.txt.
350 index.html: help.txt
351 $(AWK) -f makehtml.awk help.txt >index.html
353 vimindex.html: index.txt
354 $(AWK) -f makehtml.awk index.txt >vimindex.html
356 tags.ref tags.html: tags
357 $(AWK) -f maketags.awk tags >tags.html
359 # Perl version of .txt to .html conversion.
360 # There can't be two rules to produce a .html from a .txt file.
361 # Just run over all .txt files each time one changes. It's fast anyway.
362 perlhtml: tags $(DOCS)
363 ./vim2html.pl tags $(DOCS)
365 clean:
366 -rm doctags *.html tags.ref
368 # These files are in the extra archive, skip if not present
370 arabic.txt:
371 touch arabic.txt
373 farsi.txt:
374 touch farsi.txt
376 hebrew.txt:
377 touch hebrew.txt
379 russian.txt:
380 touch russian.txt
382 gui_w16.txt:
383 touch gui_w16.txt
385 gui_w32.txt:
386 touch gui_w32.txt
388 if_ole.txt:
389 touch if_ole.txt
391 os_390.txt:
392 touch os_390.txt
394 os_amiga.txt:
395 touch os_amiga.txt
397 os_beos.txt:
398 touch os_beos.txt
400 os_dos.txt:
401 touch os_dos.txt
403 os_mac.txt:
404 touch os_mac.txt
406 os_mint.txt:
407 touch os_mint.txt
409 os_msdos.txt:
410 touch os_msdos.txt
412 os_os2.txt:
413 touch os_os2.txt
415 os_qnx.txt:
416 touch os_qnx.txt
418 os_risc.txt:
419 touch os_risc.txt
421 os_win32.txt:
422 touch os_win32.txt
424 # Note that $< works with GNU make while $> works for BSD make.
425 # Is there a solution that works for both??
426 vim-fr.UTF-8.1: vim-fr.1
427 iconv -f latin1 -t utf-8 $< >$@
429 evim-fr.UTF-8.1: evim-fr.1
430 iconv -f latin1 -t utf-8 $< >$@
432 vimdiff-fr.UTF-8.1: vimdiff-fr.1
433 iconv -f latin1 -t utf-8 $< >$@
435 vimtutor-fr.UTF-8.1: vimtutor-fr.1
436 iconv -f latin1 -t utf-8 $< >$@
438 xxd-fr.UTF-8.1: xxd-fr.1
439 iconv -f latin1 -t utf-8 $< >$@
441 vim-it.UTF-8.1: vim-it.1
442 iconv -f latin1 -t utf-8 $< >$@
444 evim-it.UTF-8.1: evim-it.1
445 iconv -f latin1 -t utf-8 $< >$@
447 vimdiff-it.UTF-8.1: vimdiff-it.1
448 iconv -f latin1 -t utf-8 $< >$@
450 vimtutor-it.UTF-8.1: vimtutor-it.1
451 iconv -f latin1 -t utf-8 $< >$@
453 xxd-it.UTF-8.1: xxd-it.1
454 iconv -f latin1 -t utf-8 $< >$@
456 vim-pl.UTF-8.1: vim-pl.1
457 iconv -f latin2 -t utf-8 $< >$@
459 evim-pl.UTF-8.1: evim-pl.1
460 iconv -f latin2 -t utf-8 $< >$@
462 vimdiff-pl.UTF-8.1: vimdiff-pl.1
463 iconv -f latin2 -t utf-8 $< >$@
465 vimtutor-pl.UTF-8.1: vimtutor-pl.1
466 iconv -f latin2 -t utf-8 $< >$@
468 xxd-pl.UTF-8.1: xxd-pl.1
469 iconv -f latin2 -t utf-8 $< >$@
471 vim-ru.UTF-8.1: vim-ru.1
472 iconv -f KOI8-R -t utf-8 $< >$@
474 evim-ru.UTF-8.1: evim-ru.1
475 iconv -f KOI8-R -t utf-8 $< >$@
477 vimdiff-ru.UTF-8.1: vimdiff-ru.1
478 iconv -f KOI8-R -t utf-8 $< >$@
480 vimtutor-ru.UTF-8.1: vimtutor-ru.1
481 iconv -f KOI8-R -t utf-8 $< >$@
483 xxd-ru.UTF-8.1: xxd-ru.1
484 iconv -f KOI8-R -t utf-8 $< >$@