Commit | Line | Data |
---|---|---|
6aba47ca | 1 | ##Copyright (C) 1991, 1992, 1993, 1994, 1995, 1996, 1999, 2000, 2002, 2003, |
0fb0cc75 | 2 | ##2007, 2008, 2009 Free Software Foundation, Inc. |
c906108c SS |
3 | |
4 | # Makefile for GDB documentation. | |
5 | # This file is part of GDB. | |
6 | ||
7 | # This program 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 of the License, or | |
10 | # (at your option) any later version. | |
11 | # | |
12 | # This program 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 this program; if not, write to the Free Software | |
c02a867d | 19 | # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. |
c906108c SS |
20 | |
21 | srcdir = @srcdir@ | |
22 | VPATH = @srcdir@ | |
23 | ||
24 | prefix = @prefix@ | |
25 | ||
26 | infodir = @infodir@ | |
9453113a | 27 | pdfdir = $(prefix)/share/doc/gdb |
085dd6e6 | 28 | htmldir = $(prefix)/html |
c906108c SS |
29 | |
30 | SHELL = @SHELL@ | |
31 | ||
39ec5655 EZ |
32 | LN_S = @LN_S@ |
33 | ||
c906108c SS |
34 | INSTALL = @INSTALL@ |
35 | INSTALL_PROGRAM = @INSTALL_PROGRAM@ | |
36 | INSTALL_DATA = @INSTALL_DATA@ | |
37 | ||
9453113a DJ |
38 | mkinstalldirs = $(SHELL) $(srcdir)/../../mkinstalldirs |
39 | ||
c906108c SS |
40 | # main GDB source directory |
41 | gdbdir = $(srcdir)/.. | |
42 | ||
43 | # where to find texinfo; GDB dist should include a recent one | |
44 | TEXIDIR=${gdbdir}/../texinfo | |
45 | ||
46 | # where to find makeinfo, preferably one designed for texinfo-2 | |
47 | MAKEINFO=makeinfo | |
48 | ||
6d2ebf8b SS |
49 | # Note that texinfo 4.0's makeinfo --html can only generate a |
50 | # single file, which would be too large, so continue to use | |
51 | # texi2html. -sts 2000-03-28 | |
c80a96a8 MR |
52 | # Contrary to documentation, the current directory is not |
53 | # searched by texi2html, so specify it explicitly. | |
54 | # -macro 2007-07-26 | |
085dd6e6 | 55 | MAKEHTML = texi2html |
c80a96a8 | 56 | MAKEHTMLFLAGS = -menu -split_chapter -I . |
085dd6e6 | 57 | |
c906108c SS |
58 | # where to find texi2roff, ditto |
59 | TEXI2ROFF=texi2roff | |
60 | ||
be298bcc AC |
61 | # where to find texi2dvi, ditto |
62 | TEXI2DVI=texi2dvi | |
63 | ||
c16158bc JM |
64 | # Package version and bug-reporting URL. |
65 | PKGVERSION = @PKGVERSION@ | |
66 | BUGURL_TEXI = @REPORT_BUGS_TEXI@ | |
67 | ||
c906108c SS |
68 | # Where is the source dir for the READLINE library doc? |
69 | # Traditionally readline is in .. or . | |
70 | READLINE_DIR = ${gdbdir}/../readline/doc | |
71 | ||
7162c0ca EZ |
72 | # The GDB/MI docs come from a sibling directory ../mi |
73 | GDBMI_DIR = ${gdbdir}/mi | |
74 | ||
75 | SET_TEXINPUTS = \ | |
76 | TEXINPUTS=${TEXIDIR}:.:$(srcdir):$(READLINE_DIR):$(GDBMI_DIR):$$TEXINPUTS | |
c906108c | 77 | |
63ac3005 | 78 | # Files which should be generated via 'info' and installed by 'install-info' |
e6f672d2 | 79 | INFO_DEPS = gdb.info gdbint.info stabs.info annotate.info |
63ac3005 | 80 | |
9453113a DJ |
81 | # Files which should be generated via 'pdf' and installed by 'install-pdf' |
82 | PDFFILES = gdb.pdf gdbint.pdf stabs.pdf refcard.pdf annotate.pdf | |
83 | ||
c906108c SS |
84 | # There may be alternate predefined collections of switches to configure |
85 | # the GDB manual. Normally this is not done in synch with the software | |
86 | # config system, since this choice tends to be independent; most people | |
87 | # want a doc config of `all' for a generic manual, regardless of sw config. | |
88 | DOC_CONFIG = all | |
89 | ||
90 | # This list of sed edits will edit the GDB reference card | |
91 | # for what fonts and what papersize to use. | |
92 | # By default (NO edits applied), the refcard uses: | |
93 | # - Computer Modern (CM) fonts | |
94 | # - US letter paper (8.5x11in) | |
95 | # List some of the following files for alternative fonts and paper: | |
96 | # a4rc.sed use A4 paper (297 x 210 mm) | |
97 | # psrc.sed use PostScript fonts (Karl Berry short TeX names) | |
98 | # lpsrc.sed use PostScript fonts (full PostScript names in TeX) | |
99 | # e.g. for A4, Postscript: REFEDITS = a4rc.sed psrc.sed | |
100 | # for A4, CM fonts: REFEDITS = a4rc.sed | |
101 | # for US, PS fonts: REFEDITS = psrc.sed | |
102 | # for default: | |
103 | REFEDITS = | |
104 | ||
105 | # Don Knuth's TeX formatter | |
106 | TEX = tex | |
9453113a | 107 | PDFTEX = pdftex |
c906108c | 108 | |
c906108c SS |
109 | # Program to generate Postscript files from DVI files. |
110 | DVIPS = dvips | |
111 | ||
b0787093 AC |
112 | # Main GDB manual |
113 | GDB_DOC_SOURCE_INCLUDES = \ | |
aab4e0ec | 114 | $(srcdir)/fdl.texi \ |
b0787093 | 115 | $(srcdir)/gpl.texi \ |
f418dd93 | 116 | $(srcdir)/agentexpr.texi \ |
5bdf8622 | 117 | $(READLINE_DIR)/rluser.texi \ |
b0787093 AC |
118 | $(READLINE_DIR)/inc-hist.texinfo |
119 | GDB_DOC_BUILD_INCLUDES = \ | |
120 | gdb-cfg.texi \ | |
121 | GDBvn.texi | |
122 | GDB_DOC_FILES = \ | |
123 | $(srcdir)/gdb.texinfo \ | |
124 | $(GDB_DOC_SOURCE_INCLUDES) \ | |
125 | $(GDB_DOC_BUILD_INCLUDES) | |
126 | ||
127 | # Internals Manual | |
128 | GDBINT_DOC_SOURCE_INCLUDES = \ | |
bcd7e15f JB |
129 | $(srcdir)/fdl.texi \ |
130 | $(srcdir)/observer.texi | |
b0787093 AC |
131 | GDBINT_DOC_BUILD_INCLUDES = \ |
132 | gdb-cfg.texi \ | |
133 | GDBvn.texi | |
134 | GDBINT_DOC_FILES = \ | |
135 | $(srcdir)/gdbint.texinfo \ | |
136 | $(GDBINT_DOC_SOURCE_INCLUDES) \ | |
137 | $(GDBINT_DOC_BUILD_INCLUDES) | |
138 | ||
139 | # Stabs manual: All files | |
e5249f67 AC |
140 | STABS_DOC_SOURCE_INCLUDES = \ |
141 | $(srcdir)/fdl.texi | |
b0787093 AC |
142 | STABS_DOC_BUILD_INCLUDES = |
143 | STABS_DOC_FILES = \ | |
144 | $(srcdir)/stabs.texinfo \ | |
145 | $(STABS_DOC_SOURCE_INCLUDES) \ | |
146 | $(STABS_DOC_BUILD_INCLUDES) | |
c906108c | 147 | |
e6f672d2 AC |
148 | # Annotate migration document |
149 | ANNOTATE_DOC_SOURCE_INCLUDES = \ | |
150 | $(srcdir)/fdl.texi | |
151 | ANNOTATE_DOC_BUILD_INCLUDES = \ | |
152 | gdb-cfg.texi | |
153 | ANNOTATE_DOC_FILES = \ | |
154 | $(srcdir)/annotate.texinfo \ | |
155 | $(ANNOTATE_DOC_SOURCE_INCLUDES) \ | |
156 | $(ANNOTATE_DOC_BUILD_INCLUDES) | |
157 | ||
c906108c SS |
158 | #### Host, target, and site specific Makefile fragments come in here. |
159 | ### | |
160 | ||
35db0260 | 161 | all: |
c906108c | 162 | |
63ac3005 | 163 | info: $(INFO_DEPS) |
e6f672d2 AC |
164 | dvi: gdb.dvi gdbint.dvi stabs.dvi refcard.dvi annotate.dvi |
165 | ps: gdb.ps gdbint.ps stabs.ps refcard.ps annotate.ps | |
e5249f67 | 166 | html: gdb_toc.html gdbint_toc.html stabs_toc.html annotate_toc.html |
9453113a | 167 | pdf: $(PDFFILES) |
449f3b6c | 168 | all-doc: info dvi ps # pdf |
3555de01 | 169 | diststuff: info |
c906108c | 170 | |
63ac3005 | 171 | install-info: $(INFO_DEPS) |
c938e9b0 | 172 | $(SHELL) $(srcdir)/../../mkinstalldirs $(DESTDIR)$(infodir) |
63ac3005 EZ |
173 | @list='$(INFO_DEPS)'; \ |
174 | for file in $$list; do \ | |
175 | if test -f $$file; then d=.; else d=$(srcdir); fi; \ | |
176 | for ifile in `cd $$d && echo $$file $$file-[0-9] $$file-[0-9][0-9]`; do \ | |
177 | if test -f $$d/$$ifile; then \ | |
c938e9b0 L |
178 | echo " $(INSTALL_DATA) $$d/$$ifile $(DESTDIR)$(infodir)/$$ifile"; \ |
179 | $(INSTALL_DATA) $$d/$$ifile $(DESTDIR)$(infodir)/$$ifile; \ | |
63ac3005 EZ |
180 | else : ; fi; \ |
181 | done; \ | |
182 | done | |
c166cdc7 | 183 | $(POST_INSTALL) |
d3229ae3 | 184 | @if $(SHELL) -c 'install-info --version | sed 1q | fgrep -s -v -i debian' >/dev/null 2>&1; then \ |
63ac3005 | 185 | list='$(INFO_DEPS)'; \ |
d3229ae3 | 186 | for file in $$list; do \ |
5843504f EZ |
187 | echo " install-info --info-dir=$(DESTDIR)$(infodir) $(DESTDIR)$(infodir)/$$file";\ |
188 | install-info --info-dir=$(DESTDIR)$(infodir) $(DESTDIR)$(infodir)/$$file || :;\ | |
d3229ae3 EZ |
189 | done; \ |
190 | else : ; fi | |
c906108c | 191 | |
c166cdc7 EZ |
192 | uninstall-info: |
193 | $(PRE_UNINSTALL) | |
194 | @if $(SHELL) -c 'install-info --version | sed 1q | fgrep -s -v -i debian' >/dev/null 2>&1; then \ | |
195 | ii=yes; \ | |
196 | else ii=; fi; \ | |
197 | list='$(INFO_DEPS)'; \ | |
198 | for file in $$list; do \ | |
199 | test -z "$$ii" \ | |
200 | || install-info --info-dir=$(DESTDIR)$(infodir) --remove $$file; \ | |
201 | done | |
202 | $(NORMAL_UNINSTALL) | |
203 | list='$(INFO_DEPS)'; \ | |
204 | for file in $$list; do \ | |
205 | (cd $(DESTDIR)$(infodir) && rm -f $$file $$file-[0-9] $$file-[0-9][0-9]); \ | |
206 | done | |
207 | ||
085dd6e6 JM |
208 | install-html: html |
209 | for i in *.html ; do \ | |
c938e9b0 | 210 | $(INSTALL_DATA) $$i $(DESTDIR)$(htmldir)/$$i ; \ |
085dd6e6 JM |
211 | done |
212 | ||
9453113a DJ |
213 | pdf__strip_dir = `echo $$p | sed -e 's|^.*/||'`; |
214 | ||
215 | install-pdf: $(PDFFILES) | |
216 | @$(NORMAL_INSTALL) | |
217 | test -z "$(pdfdir)" || $(mkinstalldirs) "$(DESTDIR)$(pdfdir)" | |
218 | @list='$(PDFFILES)'; for p in $$list; do \ | |
219 | if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \ | |
220 | f=$(pdf__strip_dir) \ | |
221 | echo " $(INSTALL_DATA) '$$d$$p' '$(DESTDIR)$(pdfdir)/$$f'"; \ | |
222 | $(INSTALL_DATA) "$$d$$p" "$(DESTDIR)$(pdfdir)/$$f"; \ | |
223 | done | |
224 | ||
449f3b6c | 225 | STAGESTUFF = *.info* gdb-all.texi GDBvn.texi *.ps *.dvi *.pdf |
c906108c SS |
226 | |
227 | # Copy the object files from a particular stage into a subdirectory. | |
228 | stage1: force | |
229 | -mkdir stage1 | |
230 | -mv $(STAGESTUFF) stage1 | |
231 | ||
232 | stage2: force | |
233 | -mkdir stage2 | |
234 | -mv $(STAGESTUFF) stage2 | |
235 | ||
236 | stage3: force | |
237 | -mkdir stage3 | |
238 | -mv $(STAGESTUFF) stage3 | |
239 | ||
240 | against=stage2 | |
241 | ||
242 | comparison: force | |
243 | for i in $(STAGESTUFF) ; do cmp $$i $(against)/$$i ; done | |
244 | ||
245 | de-stage1: force | |
246 | -(cd stage1 ; mv -f * ..) | |
247 | -rmdir stage1 | |
248 | ||
249 | de-stage2: force | |
250 | -(cd stage2 ; mv -f * ..) | |
251 | -rmdir stage2 | |
252 | ||
253 | de-stage3: force | |
254 | -(cd stage3 ; mv -f * ..) | |
255 | -rmdir stage3 | |
256 | ||
c906108c SS |
257 | # GDB QUICK REFERENCE (dvi output) |
258 | refcard.dvi : refcard.tex $(REFEDITS) | |
dfa249fb AC |
259 | echo > tmp.sed |
260 | for f in x $(REFEDITS) ; do \ | |
261 | test x$$f = xx && continue ; \ | |
262 | cat $(srcdir)/$$f >>tmp.sed ; \ | |
263 | done | |
264 | sed -f tmp.sed $(srcdir)/refcard.tex >sedref.tex | |
c906108c SS |
265 | $(SET_TEXINPUTS) $(TEX) sedref.tex |
266 | mv sedref.dvi refcard.dvi | |
267 | rm -f sedref.log sedref.tex tmp.sed | |
268 | ||
269 | refcard.ps : refcard.dvi | |
270 | $(DVIPS) -t landscape -o $@ $? | |
271 | ||
9453113a DJ |
272 | refcard.pdf : refcard.tex $(REFEDITS) |
273 | echo > tmp.sed | |
274 | for f in x $(REFEDITS) ; do \ | |
275 | test x$$f = xx && continue ; \ | |
276 | cat $(srcdir)/$$f >>tmp.sed ; \ | |
277 | done | |
278 | sed -f tmp.sed $(srcdir)/refcard.tex >sedref.tex | |
279 | $(SET_TEXINPUTS) $(PDFTEX) sedref.tex | |
280 | mv sedref.pdf refcard.pdf | |
281 | rm -f sedref.log sedref.tex tmp.sed | |
282 | ||
05a54c4f AC |
283 | # File to record current GDB version number (copied from main dir version.in) |
284 | GDBvn.texi : ${gdbdir}/version.in | |
9ba8d803 | 285 | echo "@set GDBVN `sed q $(srcdir)/../version.in`" > ./GDBvn.new |
c16158bc JM |
286 | if [ -n "$(PKGVERSION)" ]; then \ |
287 | echo "@set VERSION_PACKAGE $(PKGVERSION)" >> ./GDBvn.new; \ | |
288 | fi | |
289 | echo "@set BUGURL $(BUGURL_TEXI)" >> ./GDBvn.new | |
290 | if [ "$(BUGURL_TEXI)" = "@uref{http://www.gnu.org/software/gdb/bugs/}" ]; then \ | |
291 | echo "@set BUGURL_DEFAULT" >> ./GDBvn.new; \ | |
292 | fi | |
c906108c SS |
293 | mv GDBvn.new GDBvn.texi |
294 | ||
295 | # Updated atomically | |
296 | .PRECIOUS: GDBvn.texi | |
297 | ||
298 | # Choose configuration for GDB manual (normally `all'; normally not tied into | |
299 | # `configure' script because most users prefer generic version of manual, | |
300 | # not one for their binary config---which may not be specifically | |
301 | # defined anyways). | |
302 | gdb-cfg.texi: ${srcdir}/${DOC_CONFIG}-cfg.texi | |
44e2be90 | 303 | (test "$(LN_S)" = "ln -s" && \ |
39ec5655 | 304 | ln -s ${srcdir}/${DOC_CONFIG}-cfg.texi gdb-cfg.texi) || \ |
c906108c SS |
305 | ln ${srcdir}/${DOC_CONFIG}-cfg.texi gdb-cfg.texi || \ |
306 | cp ${srcdir}/${DOC_CONFIG}-cfg.texi gdb-cfg.texi | |
307 | ||
308 | # GDB MANUAL: texinfo source, using @set/@clear/@value/@ifset/@ifclear | |
309 | # If your texinfo or makeinfo don't support these, get a new texinfo release | |
310 | # | |
311 | # The nonsense with GDBvn.texi gets this to run with both Sun and GNU make. | |
312 | # Note that we can *generate* GDBvn.texi, but since we distribute one in the | |
313 | # source directory for the benefit of people who *don't* use this makefile, | |
314 | # VPATH will often tell make not to bother building it, because the one | |
315 | # in the srcdir is up to date. (if not, then make should build one here). | |
316 | ||
46d8b1c3 AC |
317 | # Clean these up before each run. Avoids a catch 22 with not being |
318 | # able to re-generate these files (to fix a corruption) because these | |
319 | # files contain a corruption. | |
b0787093 AC |
320 | GDB_TEX_TMPS = gdb.aux gdb.cp* gdb.fn* gdb.ky* gdb.log gdb.pg* gdb.toc \ |
321 | gdb.tp* gdb.vr* | |
322 | ||
c906108c | 323 | # GDB MANUAL: TeX dvi file |
b0787093 | 324 | gdb.dvi: ${GDB_DOC_FILES} |
c906108c | 325 | if [ ! -f ./GDBvn.texi ]; then \ |
44e2be90 | 326 | (test "$(LN_S)" = "ln -s" && ln -s $(srcdir)/GDBvn.texi .) || \ |
c906108c SS |
327 | ln $(srcdir)/GDBvn.texi . || \ |
328 | cp $(srcdir)/GDBvn.texi . ; else true; fi | |
b0787093 | 329 | rm -f $(GDB_TEX_TMPS) |
be298bcc | 330 | $(SET_TEXINPUTS) $(TEXI2DVI) $(srcdir)/gdb.texinfo |
c906108c SS |
331 | |
332 | gdb.ps: gdb.dvi | |
333 | $(DVIPS) -o $@ $? | |
334 | ||
b0787093 | 335 | gdb.pdf: ${GDB_DOC_FILES} |
449f3b6c | 336 | if [ ! -f ./GDBvn.texi ]; then \ |
44e2be90 | 337 | (test "$(LN_S)" = "ln -s" && ln -s $(srcdir)/GDBvn.texi .) || \ |
449f3b6c AC |
338 | ln $(srcdir)/GDBvn.texi . || \ |
339 | cp $(srcdir)/GDBvn.texi . ; else true; fi | |
b0787093 | 340 | rm -f $(GDB_TEX_TMPS) |
be298bcc | 341 | $(SET_TEXINPUTS) $(TEXI2DVI) --pdf $(srcdir)/gdb.texinfo |
449f3b6c | 342 | |
c906108c | 343 | # GDB MANUAL: info file |
b0787093 | 344 | gdb.info: ${GDB_DOC_FILES} |
a7b40f07 AC |
345 | $(MAKEINFO) -I ${READLINE_DIR} -I ${GDBMI_DIR} -I $(srcdir) \ |
346 | -o gdb.info $(srcdir)/gdb.texinfo | |
c906108c SS |
347 | |
348 | # GDB MANUAL: roff translations | |
349 | # Try to use a recent texi2roff. v2 was put on prep in jan91. | |
350 | # If you want an index, see texi2roff doc for postprocessing | |
351 | # and add -i to texi2roff invocations below. | |
352 | # Workarounds for texi2roff-2 (probably fixed in later texi2roff's, delete | |
353 | # corresponding -e lines when later texi2roff's are current) | |
354 | # + @ifinfo's deleted explicitly due to texi2roff-2 bug w nested constructs. | |
355 | # + @c's deleted explicitly because texi2roff sees texinfo commands in them | |
356 | # + @ (that's at-BLANK) not recognized by texi2roff, turned into blank | |
357 | # + @alphaenumerate is ridiculously new, turned into @enumerate | |
358 | ||
359 | # texi2roff doesn't have a notion of include dirs, so we have to fake | |
360 | # it out for gdb manual's include files---but only if not configured | |
361 | # in main sourcedir. | |
b0787093 | 362 | links2roff: $(GDB_DOC_SOURCE_INCLUDES) |
c906108c | 363 | if [ ! -f gdb.texinfo ]; then \ |
44e2be90 | 364 | (test "$(LN_S)" = "ln -s" && ln -s $(GDB_DOC_SOURCE_INCLUDES) .) || \ |
b0787093 AC |
365 | ln $(GDB_DOC_SOURCE_INCLUDES) . || \ |
366 | cp $(GDB_DOC_SOURCE_INCLUDES) . ; \ | |
c906108c SS |
367 | fi |
368 | touch links2roff | |
369 | ||
c906108c | 370 | # gdb manual suitable for [gtn]roff -me |
b0787093 | 371 | gdb.me: $(GDB_DOC_FILES) links2roff |
c906108c SS |
372 | sed -e '/\\input texinfo/d' \ |
373 | -e '/@c TEXI2ROFF-KILL/,/@c END TEXI2ROFF-KILL/d' \ | |
374 | -e '/^@ifinfo/,/^@end ifinfo/d' \ | |
375 | -e '/^@c /d' \ | |
376 | -e 's/{.*,,/{/' \ | |
377 | -e 's/@ / /g' \ | |
378 | -e 's/^@alphaenumerate/@enumerate/g' \ | |
379 | -e 's/^@end alphaenumerate/@end enumerate/g' \ | |
380 | $(srcdir)/gdb.texinfo | \ | |
381 | $(TEXI2ROFF) -me | \ | |
382 | sed -e 's/---/\\(em/g' \ | |
383 | >gdb.me | |
384 | ||
385 | # gdb manual suitable for [gtn]roff -ms | |
b0787093 | 386 | gdb.ms: $(GDB_DOC_FILES) links2roff |
c906108c SS |
387 | sed -e '/\\input texinfo/d' \ |
388 | -e '/@c TEXI2ROFF-KILL/,/@c END TEXI2ROFF-KILL/d' \ | |
389 | -e '/^@ifinfo/,/^@end ifinfo/d' \ | |
390 | -e '/^@c /d' \ | |
391 | -e 's/{.*,,/{/' \ | |
392 | -e 's/@ / /g' \ | |
393 | -e 's/^@alphaenumerate/@enumerate/g' \ | |
394 | -e 's/^@end alphaenumerate/@end enumerate/g' \ | |
395 | $(srcdir)/gdb.texinfo | \ | |
396 | $(TEXI2ROFF) -ms | \ | |
397 | sed -e 's/---/\\(em/g' \ | |
398 | >gdb.ms | |
399 | ||
400 | # gdb manual suitable for [tn]roff -mm | |
401 | # '@noindent's removed due to texi2roff-2 mm bug; if yours is newer, | |
402 | # try leaving them in | |
b0787093 | 403 | gdb.mm: $(GDB_DOC_FILES) links2roff |
c906108c SS |
404 | sed -e '/\\input texinfo/d' \ |
405 | -e '/@c TEXI2ROFF-KILL/,/@c END TEXI2ROFF-KILL/d' \ | |
406 | -e '/^@ifinfo/,/^@end ifinfo/d' \ | |
407 | -e '/^@c /d' \ | |
408 | -e 's/{.*,,/{/' \ | |
409 | -e '/@noindent/d' \ | |
410 | -e 's/@ / /g' \ | |
411 | -e 's/^@alphaenumerate/@enumerate/g' \ | |
412 | -e 's/^@end alphaenumerate/@end enumerate/g' \ | |
413 | $(srcdir)/gdb.texinfo | \ | |
414 | $(TEXI2ROFF) -mm | \ | |
415 | sed -e 's/---/\\(em/g' \ | |
416 | >gdb.mm | |
417 | ||
085dd6e6 JM |
418 | # GDB MANUAL: HTML file |
419 | ||
b0787093 | 420 | gdb_toc.html: ${GDB_DOC_FILES} |
7162c0ca | 421 | $(MAKEHTML) $(MAKEHTMLFLAGS) -I ${READLINE_DIR} -I ${GDBMI_DIR} -I $(srcdir) $(srcdir)/gdb.texinfo |
085dd6e6 | 422 | |
46d8b1c3 AC |
423 | # Clean these up before each run. Avoids a catch 22 with not being |
424 | # able to re-generate these files (to fix a corruption) because these | |
425 | # files contain a corruption. | |
b0787093 AC |
426 | GDBINT_TEX_TMPS = gdbint.aux gdbint.cp* gdbint.fn* gdbint.ky* \ |
427 | gdbint.log gdbint.pg* gdbint.toc gdbint.tp* gdbint.vr* | |
428 | ||
c906108c | 429 | # GDB INTERNALS MANUAL: TeX dvi file |
b0787093 AC |
430 | gdbint.dvi: $(GDBINT_DOC_FILES) |
431 | rm -f $(GDBINT_TEX_TMPS) | |
be298bcc | 432 | $(SET_TEXINPUTS) $(TEXI2DVI) $(srcdir)/gdbint.texinfo |
c906108c SS |
433 | |
434 | gdbint.ps : gdbint.dvi | |
435 | $(DVIPS) -o $@ $? | |
436 | ||
b0787093 AC |
437 | gdbint.pdf: $(GDBINT_DOC_FILES) |
438 | rm -f $(GDBINT_TEX_TMPS) | |
be298bcc | 439 | $(SET_TEXINPUTS) $(TEXI2DVI) --pdf $(srcdir)/gdbint.texinfo |
449f3b6c | 440 | |
c906108c SS |
441 | # GDB INTERNALS MANUAL: info file |
442 | ||
b0787093 | 443 | gdbint.info: $(GDBINT_DOC_FILES) |
aab4e0ec | 444 | $(MAKEINFO) -I $(srcdir) -o gdbint.info $(srcdir)/gdbint.texinfo |
c906108c | 445 | |
085dd6e6 JM |
446 | # GDB INTERNALS MANUAL: HTML file |
447 | ||
b0787093 | 448 | gdbint_toc.html: $(GDBINT_DOC_FILES) |
085dd6e6 JM |
449 | $(MAKEHTML) $(MAKEHTMLFLAGS) $(srcdir)/gdbint.texinfo |
450 | ||
b0787093 | 451 | stabs.info: $(STABS_DOC_FILES) |
e5249f67 | 452 | $(MAKEINFO) -I $(srcdir) -o stabs.info $(srcdir)/stabs.texinfo |
c906108c | 453 | |
085dd6e6 JM |
454 | # STABS DOCUMENTATION: HTML file |
455 | ||
b0787093 | 456 | stabs_toc.html: $(STABS_DOC_FILES) |
085dd6e6 JM |
457 | $(MAKEHTML) $(MAKEHTMLFLAGS) $(srcdir)/stabs.texinfo |
458 | ||
46d8b1c3 AC |
459 | # Clean these up before each run. Avoids a catch 22 with not being |
460 | # able to re-generate these files (to fix a corruption) because these | |
461 | # files contain a corruption. | |
b0787093 AC |
462 | STABS_TEX_TMPS = stabs.aux stabs.cp* stabs.fn* stabs.ky* \ |
463 | stabs.log stabs.pg* stabs.toc stabs.tp* stabs.vr* | |
464 | ||
c906108c | 465 | # STABS DOCUMENTATION: TeX dvi file |
b0787093 AC |
466 | stabs.dvi : $(STABS_DOC_FILES) |
467 | rm -f $(STABS_TEX_TMPS) | |
be298bcc | 468 | $(SET_TEXINPUTS) $(TEXI2DVI) $(srcdir)/stabs.texinfo |
c906108c SS |
469 | |
470 | stabs.ps: stabs.dvi | |
471 | $(DVIPS) -o $@ $? | |
472 | ||
b0787093 AC |
473 | stabs.pdf: $(STABS_DOC_FILES) |
474 | rm -f $(STABS_TEX_TMPS) | |
be298bcc | 475 | $(SET_TEXINPUTS) $(TEXI2DVI) --pdf $(srcdir)/stabs.texinfo |
449f3b6c | 476 | |
e6f672d2 AC |
477 | # Clean these up before each run. Avoids a catch 22 with not being |
478 | # able to re-generate these files (to fix a corruption) because these | |
479 | # files contain a corruption. | |
480 | ANNOTATE_TEX_TMPS = annotate.aux annotate.cp* annotate.fn* annotate.ky* \ | |
481 | annotate.log annotate.pg* annotate.toc annotate.tp* annotate.vr* | |
482 | ||
483 | # ANNOTATE DOCUMENTATION: TeX dvi file | |
484 | annotate.dvi : $(ANNOTATE_DOC_FILES) | |
485 | rm -f $(ANNOTATE_TEX_TMPS) | |
486 | $(SET_TEXINPUTS) $(TEXI2DVI) $(srcdir)/annotate.texinfo | |
487 | ||
488 | annotate.ps: annotate.dvi | |
489 | $(DVIPS) -o $@ $? | |
490 | ||
491 | annotate.pdf: $(ANNOTATE_DOC_FILES) | |
492 | rm -f $(ANNOTATE_TEX_TMPS) | |
493 | $(SET_TEXINPUTS) $(TEXI2DVI) --pdf $(srcdir)/annotate.texinfo | |
494 | ||
495 | annotate.info: $(ANNOTATE_DOC_FILES) | |
496 | $(MAKEINFO) -I $(srcdir) -o annotate.info $(srcdir)/annotate.texinfo | |
497 | ||
498 | annotate_toc.html: $(ANNOTATE_DOC_FILES) | |
499 | $(MAKEHTML) $(MAKEHTMLFLAGS) $(srcdir)/annotate.texinfo | |
500 | ||
c906108c SS |
501 | force: |
502 | ||
a4ce5b0d | 503 | Makefile: Makefile.in $(host_makefile_frag) config.status |
c906108c | 504 | $(SHELL) ./config.status |
46d8b1c3 AC |
505 | |
506 | ||
507 | # The "least clean" level of cleaning. Get rid of files which are | |
508 | # automatically generated files that are just intermediate files, | |
509 | ||
510 | mostlyclean: | |
511 | rm -f gdb.mm gdb.ms gdb.me links2roff | |
512 | rm -f $(GDB_TEX_TMPS) | |
513 | rm -f $(GDBINT_TEX_TMPS) | |
514 | rm -f $(STABS_TEX_TMPS) | |
e6f672d2 | 515 | rm -f $(ANNOTATE_TEX_TMPS) |
46d8b1c3 AC |
516 | rm -f sedref.dvi sedref.tex tmp.sed |
517 | ||
518 | clean: mostlyclean | |
519 | rm -f gdb-cfg.texi | |
520 | ||
521 | distclean: clean | |
d7f4a264 | 522 | rm -f Makefile config.status config.log |
46d8b1c3 AC |
523 | |
524 | # GDBvn.texi, the dvi files, the info files, and the postscript files, | |
525 | # are all part of the distribution, so it should not be removed by | |
526 | # "clean" or "distclean". Use maintainer-clean to remove them. | |
527 | ||
528 | maintainer-clean realclean: distclean | |
529 | rm -f GDBvn.texi *.info* *.dvi *.ps *.html *.pdf | |
530 | ||
35db0260 | 531 | install: install-info |
c166cdc7 EZ |
532 | |
533 | uninstall: uninstall-info |