Commit | Line | Data |
---|---|---|
bd6766d3 | 1 | #### -*- Makefile -*- for the Emacs Manual and other documentation. |
e65be2d5 | 2 | |
4e6835db | 3 | # Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. |
e65be2d5 JR |
4 | |
5 | # This file is part of GNU Emacs. | |
6 | ||
7 | # GNU Emacs is free software; you can redistribute it and/or modify | |
8 | # it under the terms of the GNU General Public License as published by | |
9 | # the Free Software Foundation; either version 2, or (at your option) | |
10 | # any later version. | |
11 | ||
12 | # GNU Emacs is distributed in the hope that it will be useful, | |
13 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | |
14 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
15 | # GNU General Public License for more details. | |
16 | ||
17 | # You should have received a copy of the GNU General Public License | |
18 | # along with GNU Emacs; see the file COPYING. If not, write to | |
364c38d3 LK |
19 | # the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
20 | # Boston, MA 02110-1301, USA. | |
e65be2d5 JR |
21 | |
22 | # Where to find the source code. The source code for Emacs's C kernel is | |
23 | # expected to be in $(srcdir)/src, and the source code for Emacs's | |
24 | # utility programs is expected to be in $(srcdir)/lib-src. This is | |
25 | # set by the configure script's `--srcdir' option. | |
26 | srcdir=. | |
27 | ||
28 | infodir = $(srcdir)/../info | |
29 | ||
30 | # The makeinfo program is part of the Texinfo distribution. | |
2e2698e0 | 31 | MAKEINFO = makeinfo --force |
0498520b | 32 | MULTI_INSTALL_INFO = $(srcdir)\..\nt\multi-install-info.bat |
b2f68d95 | 33 | INFO_TARGETS = $(infodir)/emacs $(infodir)/ccmode \ |
2e2698e0 EZ |
34 | $(infodir)/cl $(infodir)/dired-x $(infodir)/ediff \ |
35 | $(infodir)/forms $(infodir)/gnus $(infodir)/message \ | |
36 | $(infodir)/sieve $(infodir)/pgg $(infodir)/emacs-mime \ | |
37 | $(infodir)/info $(infodir)/mh-e $(infodir)/reftex \ | |
38 | $(infodir)/sc $(infodir)/vip $(infodir)/viper \ | |
39 | $(infodir)/widget $(infodir)/efaq $(infodir)/ada-mode \ | |
40 | $(infodir)/autotype $(infodir)/calc $(infodir)/idlwave \ | |
41 | $(infodir)/eudc $(infodir)/ebrowse $(infodir)/pcl-cvs \ | |
42 | $(infodir)/woman $(infodir)/eshell $(infodir)/org \ | |
43 | $(infodir)/url $(infodir)/speedbar $(infodir)/tramp \ | |
b9e7231d | 44 | $(infodir)/ses $(infodir)/smtpmail $(infodir)/flymake \ |
597993cf | 45 | $(infodir)/newsticker $(infodir)/rcirc $(infodir)/erc |
e65be2d5 | 46 | DVI_TARGETS = emacs.dvi calc.dvi cc-mode.dvi cl.dvi dired-x.dvi \ |
2e2698e0 EZ |
47 | ediff.dvi forms.dvi gnus.dvi message.dvi emacs-mime.dvi \ |
48 | gnus.dvi message.dvi sieve.dvi pgg.dvi mh-e.dvi \ | |
e65be2d5 JR |
49 | reftex.dvi sc.dvi vip.dvi viper.dvi widget.dvi faq.dvi \ |
50 | ada-mode.dvi autotype.dvi idlwave.dvi eudc.dvi ebrowse.dvi \ | |
2e2698e0 | 51 | pcl-cvs.dvi woman.dvi eshell.dvi org.dvi url.dvi \ |
e8d1b5bf | 52 | speedbar.dvi tramp.dvi ses.dvi smtpmail.dvi flymake.dvi \ |
597993cf | 53 | newsticker.dvi emacs-xtra.dvi rcirc.dvi erc.dvi |
e65be2d5 JR |
54 | INFOSOURCES = info.texi |
55 | ||
56 | # The following rule does not work with all versions of `make'. | |
57 | .SUFFIXES: .texi .dvi | |
58 | .texi.dvi: | |
59 | texi2dvi $< | |
60 | ||
61 | TEXI2DVI = texi2dvi | |
0498520b | 62 | ENVADD = $(srcdir)\..\nt\envadd.bat "TEXINPUTS=$(srcdir);$(TEXINPUTS)" \ |
e65be2d5 JR |
63 | "MAKEINFO=$(MAKEINFO) -I$(srcdir)" /C |
64 | ||
b2f68d95 EZ |
65 | EMACS_XTRA=\ |
66 | $(srcdir)/arevert-xtra.texi \ | |
67 | $(srcdir)/cal-xtra.texi \ | |
68 | $(srcdir)/dired-xtra.texi \ | |
69 | $(srcdir)/picture-xtra.texi \ | |
70 | $(srcdir)/emerge-xtra.texi \ | |
71 | $(srcdir)/vc-xtra.texi \ | |
72 | $(srcdir)/vc1-xtra.texi \ | |
73 | $(srcdir)/vc2-xtra.texi \ | |
74 | $(srcdir)/fortran-xtra.texi \ | |
75 | $(srcdir)/msdog-xtra.texi | |
76 | ||
e65be2d5 JR |
77 | EMACSSOURCES= \ |
78 | $(srcdir)/emacs.texi \ | |
79 | $(srcdir)/doclicense.texi \ | |
80 | $(srcdir)/screen.texi \ | |
81 | $(srcdir)/commands.texi \ | |
82 | $(srcdir)/entering.texi \ | |
83 | $(srcdir)/basic.texi \ | |
84 | $(srcdir)/mini.texi \ | |
85 | $(srcdir)/m-x.texi \ | |
86 | $(srcdir)/help.texi \ | |
87 | $(srcdir)/mark.texi \ | |
88 | $(srcdir)/killing.texi \ | |
89 | $(srcdir)/regs.texi \ | |
90 | $(srcdir)/display.texi \ | |
91 | $(srcdir)/search.texi \ | |
92 | $(srcdir)/fixit.texi \ | |
93 | $(srcdir)/files.texi \ | |
94 | $(srcdir)/buffers.texi \ | |
95 | $(srcdir)/windows.texi \ | |
96 | $(srcdir)/frames.texi \ | |
97 | $(srcdir)/mule.texi \ | |
98 | $(srcdir)/major.texi \ | |
99 | $(srcdir)/indent.texi \ | |
100 | $(srcdir)/text.texi \ | |
101 | $(srcdir)/programs.texi \ | |
102 | $(srcdir)/building.texi \ | |
103 | $(srcdir)/maintaining.texi \ | |
104 | $(srcdir)/abbrevs.texi \ | |
e65be2d5 JR |
105 | $(srcdir)/sending.texi \ |
106 | $(srcdir)/rmail.texi \ | |
107 | $(srcdir)/dired.texi \ | |
108 | $(srcdir)/calendar.texi \ | |
109 | $(srcdir)/misc.texi \ | |
110 | $(srcdir)/custom.texi \ | |
111 | $(srcdir)/trouble.texi \ | |
112 | $(srcdir)/cmdargs.texi \ | |
113 | $(srcdir)/xresources.texi \ | |
114 | $(srcdir)/anti.texi \ | |
115 | $(srcdir)/macos.texi \ | |
116 | $(srcdir)/msdog.texi \ | |
117 | $(srcdir)/gnu.texi \ | |
118 | $(srcdir)/glossary.texi \ | |
119 | $(srcdir)/ack.texi \ | |
b2f68d95 EZ |
120 | $(srcdir)/kmacro.texi \ |
121 | $(EMACS_XTRA) | |
e65be2d5 JR |
122 | |
123 | info: $(INFO_TARGETS) | |
e65be2d5 JR |
124 | |
125 | dvi: $(DVI_TARGETS) | |
126 | ||
127 | # Note that all the Info targets build the Info files | |
128 | # in srcdir. There is no provision for Info files | |
129 | # to exist in the build directory. | |
130 | # In a distribution of Emacs, the Info files should be up to date. | |
131 | ||
132 | # The following target uses an explicit -o switch to work around | |
133 | # the @setfilename directive in info.texi, which is required for | |
134 | # the Texinfo distribution. | |
2de2a338 JR |
135 | # Some Windows ports of makeinfo seem to require -o to come before the |
136 | # texi filename, contrary to GNU standards. | |
e65be2d5 | 137 | |
55c097c0 EZ |
138 | $(infodir)/dir: |
139 | $(MULTI_INSTALL_INFO) --info-dir=$(infodir) $(INFO_TARGETS) | |
140 | ||
e65be2d5 | 141 | $(infodir)/info: $(INFOSOURCES) |
2de2a338 | 142 | $(MAKEINFO) --no-split -o $@ info.texi |
e65be2d5 JR |
143 | |
144 | info.dvi: $(INFOSOURCES) | |
145 | $(ENVADD) $(TEXI2DVI) $(srcdir)/info.texi | |
146 | ||
147 | $(infodir)/emacs: $(EMACSSOURCES) | |
148 | $(MAKEINFO) emacs.texi | |
149 | ||
59e24ad3 | 150 | emacs.dvi: $(EMACSSOURCES) |
e65be2d5 JR |
151 | $(ENVADD) $(TEXI2DVI) $(srcdir)/emacs.texi |
152 | ||
153 | # This target is here so you could easily get the list of the *.texi | |
154 | # files which belong to the Emacs manual (as opposed to the separate | |
155 | # manuals for CL, CC Mode, Ebrowse, etc.). With this target, you can | |
156 | # say things like "grep foo `make emacsman`". | |
157 | emacsman: | |
158 | @echo $(EMACSSOURCES) | |
159 | ||
160 | $(infodir)/ccmode: cc-mode.texi | |
161 | $(MAKEINFO) cc-mode.texi | |
162 | cc-mode.dvi: cc-mode.texi | |
163 | $(ENVADD) $(TEXI2DVI) $(srcdir)/cc-mode.texi | |
164 | ||
165 | $(infodir)/ada-mode: ada-mode.texi | |
166 | $(MAKEINFO) ada-mode.texi | |
167 | ada-mode.dvi: ada-mode.texi | |
168 | $(ENVADD) $(TEXI2DVI) $(srcdir)/ada-mode.texi | |
169 | ||
170 | $(infodir)/pcl-cvs: pcl-cvs.texi | |
171 | $(MAKEINFO) pcl-cvs.texi | |
172 | pcl-cvs.dvi: pcl-cvs.texi | |
173 | $(ENVADD) $(TEXI2DVI) $(srcdir)/pcl-cvs.texi | |
174 | ||
175 | $(infodir)/eshell: eshell.texi | |
176 | $(MAKEINFO) eshell.texi | |
177 | eshell.dvi: eshell.texi | |
178 | $(ENVADD) $(TEXI2DVI) $(srcdir)/eshell.texi | |
179 | ||
180 | $(infodir)/cl: cl.texi | |
181 | $(MAKEINFO) cl.texi | |
182 | cl.dvi: cl.texi | |
183 | $(ENVADD) $(TEXI2DVI) $(srcdir)/cl.texi | |
184 | ||
185 | $(infodir)/dired-x: dired-x.texi | |
186 | $(MAKEINFO) dired-x.texi | |
187 | dired-x.dvi: dired-x.texi | |
188 | $(ENVADD) $(TEXI2DVI) $(srcdir)/dired-x.texi | |
189 | ||
190 | $(infodir)/ediff: ediff.texi | |
191 | $(MAKEINFO) ediff.texi | |
192 | ediff.dvi: ediff.texi | |
193 | $(ENVADD) $(TEXI2DVI) $(srcdir)/ediff.texi | |
194 | ||
305fa183 JB |
195 | $(infodir)/flymake: flymake.texi |
196 | $(MAKEINFO) flymake.texi | |
197 | flymake.dvi: flymake.texi | |
198 | $(ENVADD) $(TEXI2DVI) $(srcdir)/flymake.texi | |
199 | ||
e65be2d5 JR |
200 | $(infodir)/forms: forms.texi |
201 | $(MAKEINFO) forms.texi | |
202 | forms.dvi: forms.texi | |
203 | $(ENVADD) $(TEXI2DVI) $(srcdir)/forms.texi | |
204 | ||
23f87bed | 205 | # gnus/message/emacs-mime/sieve/pgg are part of Gnus: |
e65be2d5 JR |
206 | $(infodir)/gnus: gnus.texi |
207 | $(MAKEINFO) gnus.texi | |
208 | gnus.dvi: gnus.texi | |
2e2698e0 | 209 | sed -e "/@iflatex/,/@end iflatex/d" $(srcdir)/gnus.texi > gnustmp.texi |
e65be2d5 JR |
210 | $(ENVADD) $(TEXI2DVI) gnustmp.texi |
211 | cp gnustmp.dvi $*.dvi | |
212 | rm gnustmp.* | |
8d63d890 | 213 | # |
e65be2d5 JR |
214 | $(infodir)/message: message.texi |
215 | $(MAKEINFO) message.texi | |
216 | message.dvi: message.texi | |
217 | $(ENVADD) $(TEXI2DVI) $(srcdir)/message.texi | |
8d63d890 | 218 | # |
23f87bed MB |
219 | $(infodir)/emacs-mime: emacs-mime.texi |
220 | $(MAKEINFO) emacs-mime.texi | |
221 | emacs-mime.dvi: emacs-mime.texi | |
222 | $(ENVADD) $(TEXI2DVI) $(srcdir)/emacs-mime.texi | |
8d63d890 RS |
223 | # |
224 | $(infodir)/sieve: sieve.texi | |
33ca3973 | 225 | $(MAKEINFO) sieve.texi |
23f87bed | 226 | sieve.dvi: sieve.texi |
33ca3973 | 227 | $(ENVADD) $(TEXI2DVI) $(srcdir)/sieve.texi |
8d63d890 RS |
228 | # |
229 | $(infodir)/pgg: pgg.texi | |
33ca3973 | 230 | $(MAKEINFO) pgg.texi |
23f87bed | 231 | pgg.dvi: pgg.texi |
33ca3973 | 232 | $(ENVADD) $(TEXI2DVI) $(srcdir)/pgg.texi |
e65be2d5 JR |
233 | |
234 | $(infodir)/mh-e: mh-e.texi | |
235 | $(MAKEINFO) mh-e.texi | |
236 | mh-e.dvi: mh-e.texi | |
237 | $(ENVADD) $(TEXI2DVI) $(srcdir)/mh-e.texi | |
238 | ||
239 | $(infodir)/reftex: reftex.texi | |
240 | $(MAKEINFO) reftex.texi | |
241 | reftex.dvi: reftex.texi | |
242 | $(ENVADD) $(TEXI2DVI) $(srcdir)/reftex.texi | |
243 | ||
244 | $(infodir)/sc: sc.texi | |
245 | $(MAKEINFO) sc.texi | |
246 | sc.dvi: sc.texi | |
247 | $(ENVADD) $(TEXI2DVI) $(srcdir)/sc.texi | |
248 | ||
249 | $(infodir)/vip: vip.texi | |
250 | $(MAKEINFO) vip.texi | |
251 | vip.dvi: vip.texi | |
252 | $(ENVADD) $(TEXI2DVI) $(srcdir)/vip.texi | |
253 | ||
254 | $(infodir)/viper: viper.texi | |
255 | $(MAKEINFO) viper.texi | |
256 | viper.dvi: viper.texi | |
257 | $(ENVADD) $(TEXI2DVI) $(srcdir)/viper.texi | |
258 | ||
259 | $(infodir)/widget: widget.texi | |
260 | $(MAKEINFO) widget.texi | |
261 | widget.dvi: widget.texi | |
262 | $(ENVADD) $(TEXI2DVI) $(srcdir)/widget.texi | |
263 | ||
264 | $(infodir)/efaq: faq.texi | |
265 | $(MAKEINFO) faq.texi | |
266 | faq.dvi: faq.texi | |
267 | $(ENVADD) $(TEXI2DVI) $(srcdir)/faq.texi | |
268 | ||
269 | ../etc/GNU: gnu1.texi gnu.texi | |
270 | $(MAKEINFO) --no-headers -o ../etc/GNU gnu1.texi | |
271 | ||
272 | $(infodir)/autotype: autotype.texi | |
273 | $(MAKEINFO) autotype.texi | |
274 | autotype.dvi: autotype.texi | |
275 | $(ENVADD) $(TEXI2DVI) $(srcdir)/autotype.texi | |
276 | ||
277 | $(infodir)/calc: calc.texi | |
278 | $(MAKEINFO) calc.texi | |
279 | ||
280 | calc.dvi: calc.texi | |
281 | $(ENVADD) $(TEXI2DVI) $(srcdir)/calc.texi | |
282 | ||
283 | # This is produced with --no-split to avoid making files whose | |
284 | # names clash on DOS 8+3 filesystems | |
285 | $(infodir)/idlwave: idlwave.texi | |
286 | $(MAKEINFO) --no-split idlwave.texi | |
287 | idlwave.dvi: idlwave.texi | |
288 | $(ENVADD) $(TEXI2DVI) $(srcdir)/idlwave.texi | |
289 | ||
290 | $(infodir)/eudc: eudc.texi | |
291 | $(MAKEINFO) eudc.texi | |
292 | eudc.dvi: eudc.texi | |
293 | $(ENVADD) $(TEXI2DVI) $(srcdir)/eudc.texi | |
294 | ||
295 | $(infodir)/ebrowse: ebrowse.texi | |
296 | $(MAKEINFO) ebrowse.texi | |
297 | ebrowse.dvi: ebrowse.texi | |
298 | $(ENVADD) $(TEXI2DVI) $(srcdir)/ebrowse.texi | |
299 | ||
300 | $(infodir)/woman: woman.texi | |
301 | $(MAKEINFO) woman.texi | |
302 | woman.dvi: woman.texi | |
303 | $(ENVADD) $(TEXI2DVI) $(srcdir)/woman.texi | |
304 | ||
305 | $(infodir)/speedbar: speedbar.texi | |
306 | $(MAKEINFO) speedbar.texi | |
307 | speedbar.dvi: speedbar.texi | |
308 | $(ENVADD) $(TEXI2DVI) $(srcdir)/speedbar.texi | |
309 | ||
e65be2d5 JR |
310 | $(infodir)/tramp: tramp.texi |
311 | $(MAKEINFO) tramp.texi | |
312 | tramp.dvi: tramp.texi | |
313 | $(ENVADD) $(TEXI2DVI) $(srcdir)/tramp.texi | |
314 | ||
315 | $(infodir)/ses: ses.texi | |
316 | $(MAKEINFO) ses.texi | |
317 | ses.dvi: ses.texi | |
318 | $(ENVADD) $(TEXI2DVI) $(srcdir)/ses.texi | |
319 | ||
320 | $(infodir)/smtpmail: smtpmail.texi | |
321 | $(MAKEINFO) smtpmail.texi | |
322 | smtpmail.dvi: smtpmail.texi | |
323 | $(ENVADD) $(TEXI2DVI) $(srcdir)/smtpmail.texi | |
324 | ||
b2f68d95 | 325 | emacs-xtra.dvi: emacs-xtra.texi $(EMACS_XTRA) |
e8d1b5bf JB |
326 | $(ENVADD) $(TEXI2DVI) $(srcdir)/emacs-xtra.texi |
327 | ||
e2bcbfbb LT |
328 | $(infodir)/org: org.texi |
329 | $(MAKEINFO) org.texi | |
e2bcbfbb LT |
330 | org.dvi: org.texi |
331 | $(ENVADD) $(TEXI2DVI) $(srcdir)/org.texi | |
332 | ||
333 | $(infodir)/url: url.texi | |
334 | $(MAKEINFO) url.texi | |
e2bcbfbb LT |
335 | url.dvi: url.texi |
336 | $(ENVADD) $(TEXI2DVI) $(srcdir)/url.texi | |
337 | ||
b9e7231d EZ |
338 | $(infodir)/newsticker: newsticker.texi |
339 | $(MAKEINFO) newsticker.texi | |
340 | newsticker.dvi: newsticker.texi | |
3e7269d9 | 341 | $(ENVADD) $(TEXI2DVI) $(srcdir)/newsticker.texi |
b9e7231d | 342 | |
cf064cd9 EZ |
343 | $(infodir)/rcirc: rcirc.texi |
344 | $(MAKEINFO) rcirc.texi | |
345 | rcirc.dvi: rcirc.texi | |
346 | $(ENVADD) $(TEXI2DVI) $(srcdir)/rcirc.texi | |
347 | ||
597993cf MB |
348 | $(infodir)/erc: erc.texi |
349 | $(MAKEINFO) erc.texi | |
350 | erc.dvi: erc.texi | |
351 | $(ENVADD) $(TEXI2DVI) $(srcdir)/erc.texi | |
352 | ||
e65be2d5 | 353 | mostlyclean: |
5bb0fcd1 | 354 | - $(DEL) *.log *.cp *.fn *.ky *.pg *.vr core *.tp *.core gnustmp.* |
e65be2d5 JR |
355 | |
356 | clean: mostlyclean | |
5bb0fcd1 JB |
357 | - $(DEL) *.dvi |
358 | - $(DEL) $(infodir)/emacs* $(infodir)/ccmode* \ | |
359 | $(infodir)/cl* $(infodir)/dired-x* \ | |
360 | $(infodir)/ediff* $(infodir)/forms* \ | |
361 | $(infodir)/gnus* $(infodir)/info* \ | |
362 | $(infodir)/message* $(infodir)/mh-e* \ | |
363 | $(infodir)/reftex* $(infodir)/sc* \ | |
e8d1b5bf JB |
364 | $(infodir)/vip* $(infodir)/widget* \ |
365 | $(infodir)/efaq* $(infodir)/ada-mode* \ | |
366 | $(infodir)/autotype* $(infodir)/calc* \ | |
367 | $(infodir)/idlwave* $(infodir)/eudc* \ | |
368 | $(infodir)/ebrowse* $(infodir)/pcl-cvs* \ | |
369 | $(infodir)/woman* $(infodir)/eshell* \ | |
5bb0fcd1 | 370 | $(infodir)/speedbar* $(infodir)/tramp* \ |
e8d1b5bf | 371 | $(infodir)/ses* $(infodir)/smtpmail* \ |
e2bcbfbb | 372 | $(infodir)/url* $(infodir)/org* \ |
da2134bc JB |
373 | $(infodir)/flymake* $(infodir)/newsticker* \ |
374 | $(infodir)/sieve* $(infodir)/pgg* \ | |
375 | $(infodir)/erc* $(infodir)/rcirc* | |
e65be2d5 JR |
376 | |
377 | distclean: clean | |
378 | ||
379 | maintainer-clean: distclean | |
5bb0fcd1 | 380 | - $(DEL) *.aux *.cps *.fns *.kys *.pgs *.vrs *.toc |
e65be2d5 JR |
381 | # Don't delete these, because they are outside the current directory. |
382 | # for file in $(INFO_TARGETS); do rm -f $${file}*; done | |
383 | ||
384 | ||
385 | # Formerly this directory had texindex.c and getopt.c in it | |
386 | # and this makefile built them to make texindex. | |
387 | # That caused trouble because this is run entirely in the source directory. | |
388 | # Since we expect to get texi2dvi from elsewhere, | |
389 | # it is ok to expect texindex from elsewhere also. |