Commit | Line | Data |
---|---|---|
5c26072a AC |
1 | README for gdb-6.3 release |
2 | Updated 8, November, 2004 by Andrew Cagney | |
c906108c SS |
3 | |
4 | This is GDB, the GNU source-level debugger. | |
c906108c | 5 | |
129188f6 | 6 | A summary of new features is in the file `gdb/NEWS'. |
c906108c | 7 | |
1bfdc549 AC |
8 | Check the GDB home page at http://www.gnu.org/software/gdb/ for up to |
9 | date release information, mailing list links and archives, etc. | |
129188f6 AC |
10 | |
11 | The file `gdb/PROBLEMS' contains information on problems identified | |
12 | late in the release cycle. GDB's bug tracking data base at | |
13 | http://www.gnu.org/software/gdb/bugs/ contains a more complete list of | |
14 | bugs. | |
6b325864 | 15 | |
c906108c SS |
16 | |
17 | Unpacking and Installation -- quick overview | |
18 | ========================== | |
19 | ||
aba7b4b6 | 20 | In this release, the GDB debugger sources, the generic GNU include |
c906108c SS |
21 | files, the BFD ("binary file description") library, the readline |
22 | library, and other libraries all have directories of their own | |
5c26072a | 23 | underneath the gdb-6.3 directory. The idea is that a variety of GNU |
c906108c SS |
24 | tools can share a common copy of these things. Be aware of variation |
25 | over time--for example don't try to build gdb with a copy of bfd from | |
34f47bc4 AC |
26 | a release other than the gdb release (such as a binutils release), |
27 | especially if the releases are more than a few weeks apart. | |
c906108c SS |
28 | Configuration scripts and makefiles exist to cruise up and down this |
29 | directory tree and automatically build all the pieces in the right | |
30 | order. | |
31 | ||
5c26072a AC |
32 | When you unpack the gdb-6.3.tar.gz file, you'll find a directory |
33 | called `gdb-6.3', which contains: | |
c906108c | 34 | |
73fb7068 RS |
35 | COPYING config-ml.in gettext.m4 ltconfig sim |
36 | COPYING.LIB config.guess include ltmain.sh src-release | |
37 | Makefile.def config.sub install-sh md5.sum symlink-tree | |
38 | Makefile.in configure libiberty missing texinfo | |
39 | Makefile.tpl configure.in libtool.m4 mkinstalldirs ylwrap | |
40 | README djunpack.bat ltcf-c.sh move-if-change | |
41 | bfd etc ltcf-cxx.sh opcodes | |
42 | config gdb ltcf-gcj.sh readline | |
c906108c | 43 | |
bec71058 | 44 | You can build GDB right in the source directory: |
c906108c | 45 | |
5c26072a | 46 | cd gdb-6.3 |
34f47bc4 AC |
47 | ./configure |
48 | make | |
49 | cp gdb/gdb /usr/local/bin/gdb (or wherever you want) | |
c906108c | 50 | |
bec71058 FN |
51 | However, we recommend that an empty directory be used instead. |
52 | This way you do not clutter your source tree with binary files | |
53 | and will be able to create different builds with different | |
54 | configuration options. | |
55 | ||
56 | You can build GDB in any empty build directory: | |
57 | ||
34f47bc4 AC |
58 | mkdir build |
59 | cd build | |
5c26072a | 60 | <full path to your sources>/gdb-6.3/configure |
34f47bc4 AC |
61 | make |
62 | cp gdb/gdb /usr/local/bin/gdb (or wherever you want) | |
bec71058 | 63 | |
c63ce875 | 64 | (Building GDB with DJGPP tools for MS-DOS/MS-Windows is slightly |
5c26072a | 65 | different; see the file gdb-6.3/gdb/config/djgpp/README for details.) |
c63ce875 | 66 | |
aba7b4b6 AC |
67 | This will configure and build all the libraries as well as GDB. If |
68 | `configure' can't determine your system type, specify one as its | |
69 | argument, e.g., `./configure sun4' or `./configure decstation'. | |
c906108c | 70 | |
5c26072a | 71 | Make sure that your 'configure' line ends in 'gdb-6.3/configure': |
eaec4d85 | 72 | |
5c26072a AC |
73 | /berman/migchain/source/gdb-6.3/configure # RIGHT |
74 | /berman/migchain/source/gdb-6.3/gdb/configure # WRONG | |
eaec4d85 MC |
75 | |
76 | The gdb package contains several subdirectories, such as 'gdb', | |
77 | 'bfd', and 'readline'. If your 'configure' line ends in | |
5c26072a | 78 | 'gdb-6.3/gdb/configure', then you are configuring only the gdb |
eaec4d85 MC |
79 | subdirectory, not the whole gdb package. This leads to build errors |
80 | such as: | |
81 | ||
82 | make: *** No rule to make target `../bfd/bfd.h', needed by `gdb.o'. Stop. | |
83 | ||
84 | If you get other compiler errors during this stage, see the `Reporting | |
aba7b4b6 | 85 | Bugs' section below; there are a few known problems. |
c906108c | 86 | |
34f47bc4 AC |
87 | GDB requires an ISO C (ANSI C) compiler. If you do not have an ISO |
88 | C compiler for your system, you may be able to download and install | |
89 | the GNU CC compiler. It is available via anonymous FTP from the | |
90 | directory `ftp://ftp.gnu.org/pub/gnu/gcc'. | |
c906108c | 91 | |
aba7b4b6 AC |
92 | GDB can be used as a cross-debugger, running on a machine of one |
93 | type while debugging a program running on a machine of another type. | |
94 | See below. | |
c906108c SS |
95 | |
96 | ||
97 | More Documentation | |
98 | ****************** | |
99 | ||
100 | All the documentation for GDB comes as part of the machine-readable | |
aba7b4b6 AC |
101 | distribution. The documentation is written in Texinfo format, which |
102 | is a documentation system that uses a single source file to produce | |
103 | both on-line information and a printed manual. You can use one of the | |
104 | Info formatting commands to create the on-line version of the | |
105 | documentation and TeX (or `texi2roff') to typeset the printed version. | |
106 | ||
107 | GDB includes an already formatted copy of the on-line Info version | |
108 | of this manual in the `gdb/doc' subdirectory. The main Info file is | |
5c26072a | 109 | `gdb-6.3/gdb/doc/gdb.info', and it refers to subordinate files |
aba7b4b6 AC |
110 | matching `gdb.info*' in the same directory. If necessary, you can |
111 | print out these files, or read them with any editor; but they are | |
112 | easier to read using the `info' subsystem in GNU Emacs or the | |
113 | standalone `info' program, available as part of the GNU Texinfo | |
114 | distribution. | |
c906108c SS |
115 | |
116 | If you want to format these Info files yourself, you need one of the | |
117 | Info formatting programs, such as `texinfo-format-buffer' or | |
118 | `makeinfo'. | |
119 | ||
120 | If you have `makeinfo' installed, and are in the top level GDB | |
5c26072a | 121 | source directory (`gdb-6.3', in the case of version 6.3), you can make |
c906108c SS |
122 | the Info file by typing: |
123 | ||
34f47bc4 AC |
124 | cd gdb/doc |
125 | make info | |
c906108c SS |
126 | |
127 | If you want to typeset and print copies of this manual, you need | |
128 | TeX, a program to print its DVI output files, and `texinfo.tex', the | |
129 | Texinfo definitions file. This file is included in the GDB | |
5c26072a | 130 | distribution, in the directory `gdb-6.3/texinfo'. |
c906108c SS |
131 | |
132 | TeX is a typesetting program; it does not print files directly, but | |
133 | produces output files called DVI files. To print a typeset document, | |
134 | you need a program to print DVI files. If your system has TeX | |
135 | installed, chances are it has such a program. The precise command to | |
136 | use depends on your system; `lpr -d' is common; another (for PostScript | |
137 | devices) is `dvips'. The DVI print command may require a file name | |
138 | without any extension or a `.dvi' extension. | |
139 | ||
140 | TeX also requires a macro definitions file called `texinfo.tex'. | |
141 | This file tells TeX how to typeset a document written in Texinfo | |
142 | format. On its own, TeX cannot read, much less typeset a Texinfo file. | |
143 | `texinfo.tex' is distributed with GDB and is located in the | |
5c26072a | 144 | `gdb-6.3/texinfo' directory. |
c906108c SS |
145 | |
146 | If you have TeX and a DVI printer program installed, you can typeset | |
147 | and print this manual. First switch to the the `gdb' subdirectory of | |
5c26072a | 148 | the main source directory (for example, to `gdb-6.3/gdb') and then type: |
c906108c | 149 | |
34f47bc4 | 150 | make doc/gdb.dvi |
966beb0f EZ |
151 | |
152 | If you prefer to have the manual in PDF format, type this from the | |
153 | `gdb/doc' subdirectory of the main source directory: | |
154 | ||
34f47bc4 | 155 | make gdb.pdf |
966beb0f EZ |
156 | |
157 | For this to work, you will need the PDFTeX package to be installed. | |
c906108c SS |
158 | |
159 | ||
160 | Installing GDB | |
161 | ************** | |
162 | ||
163 | GDB comes with a `configure' script that automates the process of | |
164 | preparing GDB for installation; you can then use `make' to build the | |
165 | `gdb' program. | |
166 | ||
167 | The GDB distribution includes all the source code you need for GDB in | |
168 | a single directory, whose name is usually composed by appending the | |
169 | version number to `gdb'. | |
170 | ||
5c26072a | 171 | For example, the GDB version 6.3 distribution is in the `gdb-6.3' |
c906108c SS |
172 | directory. That directory contains: |
173 | ||
5c26072a | 174 | `gdb-6.3/{COPYING,COPYING.LIB}' |
c906108c SS |
175 | Standard GNU license files. Please read them. |
176 | ||
5c26072a | 177 | `gdb-6.3/bfd' |
c906108c SS |
178 | source for the Binary File Descriptor library |
179 | ||
5c26072a | 180 | `gdb-6.3/config*' |
c906108c SS |
181 | script for configuring GDB, along with other support files |
182 | ||
5c26072a | 183 | `gdb-6.3/gdb' |
c906108c SS |
184 | the source specific to GDB itself |
185 | ||
5c26072a | 186 | `gdb-6.3/include' |
c906108c SS |
187 | GNU include files |
188 | ||
5c26072a | 189 | `gdb-6.3/libiberty' |
c906108c SS |
190 | source for the `-liberty' free software library |
191 | ||
5c26072a | 192 | `gdb-6.3/opcodes' |
c906108c SS |
193 | source for the library of opcode tables and disassemblers |
194 | ||
5c26072a | 195 | `gdb-6.3/readline' |
c906108c | 196 | source for the GNU command-line interface |
7a292a7a SS |
197 | NOTE: The readline library is compiled for use by GDB, but will |
198 | not be installed on your system when "make install" is issued. | |
c906108c | 199 | |
5c26072a | 200 | `gdb-6.3/sim' |
c906108c SS |
201 | source for some simulators (ARM, D10V, SPARC, M32R, MIPS, PPC, V850, etc) |
202 | ||
5c26072a | 203 | `gdb-6.3/texinfo' |
c906108c SS |
204 | The `texinfo.tex' file, which you need in order to make a printed |
205 | manual using TeX. | |
206 | ||
5c26072a | 207 | `gdb-6.3/etc' |
c906108c SS |
208 | Coding standards, useful files for editing GDB, and other |
209 | miscellanea. | |
210 | ||
c63ce875 EZ |
211 | Note: the following instructions are for building GDB on Unix or |
212 | Unix-like systems. Instructions for building with DJGPP for | |
213 | MS-DOS/MS-Windows are in the file gdb/config/djgpp/README. | |
c906108c SS |
214 | |
215 | The simplest way to configure and build GDB is to run `configure' | |
216 | from the `gdb-VERSION-NUMBER' source directory, which in this example | |
5c26072a | 217 | is the `gdb-6.3' directory. |
c906108c SS |
218 | |
219 | First switch to the `gdb-VERSION-NUMBER' source directory if you are | |
220 | not already in it; then run `configure'. | |
221 | ||
222 | For example: | |
223 | ||
5c26072a | 224 | cd gdb-6.3 |
34f47bc4 AC |
225 | ./configure |
226 | make | |
c906108c SS |
227 | |
228 | Running `configure' followed by `make' builds the `bfd', | |
229 | `readline', `mmalloc', and `libiberty' libraries, then `gdb' itself. | |
230 | The configured source files, and the binaries, are left in the | |
231 | corresponding source directories. | |
232 | ||
233 | `configure' is a Bourne-shell (`/bin/sh') script; if your system | |
234 | does not recognize this automatically when you run a different shell, | |
235 | you may need to run `sh' on it explicitly: | |
236 | ||
34f47bc4 | 237 | sh configure |
c906108c SS |
238 | |
239 | If you run `configure' from a directory that contains source | |
5c26072a AC |
240 | directories for multiple libraries or programs, such as the `gdb-6.3' |
241 | source directory for version 6.3, `configure' creates configuration | |
c906108c SS |
242 | files for every directory level underneath (unless you tell it not to, |
243 | with the `--norecursion' option). | |
244 | ||
245 | You can run the `configure' script from any of the subordinate | |
246 | directories in the GDB distribution, if you only want to configure that | |
247 | subdirectory; but be sure to specify a path to it. | |
248 | ||
5c26072a | 249 | For example, with version 6.3, type the following to configure only |
c906108c SS |
250 | the `bfd' subdirectory: |
251 | ||
5c26072a | 252 | cd gdb-6.3/bfd |
34f47bc4 | 253 | ../configure |
c906108c SS |
254 | |
255 | You can install `gdb' anywhere; it has no hardwired paths. However, | |
256 | you should make sure that the shell on your path (named by the `SHELL' | |
257 | environment variable) is publicly readable. Remember that GDB uses the | |
258 | shell to start your program--some systems refuse to let GDB debug child | |
259 | processes whose programs are not readable. | |
260 | ||
261 | ||
262 | Compiling GDB in another directory | |
263 | ================================== | |
264 | ||
265 | If you want to run GDB versions for several host or target machines, | |
266 | you need a different `gdb' compiled for each combination of host and | |
267 | target. `configure' is designed to make this easy by allowing you to | |
268 | generate each configuration in a separate subdirectory, rather than in | |
269 | the source directory. If your `make' program handles the `VPATH' | |
270 | feature correctly (GNU `make' and SunOS 'make' are two that should), | |
271 | running `make' in each of these directories builds the `gdb' program | |
272 | specified there. | |
273 | ||
274 | To build `gdb' in a separate directory, run `configure' with the | |
275 | `--srcdir' option to specify where to find the source. (You also need | |
276 | to specify a path to find `configure' itself from your working | |
277 | directory. If the path to `configure' would be the same as the | |
278 | argument to `--srcdir', you can leave out the `--srcdir' option; it | |
279 | will be assumed.) | |
280 | ||
5c26072a | 281 | For example, with version 6.3, you can build GDB in a separate |
c906108c SS |
282 | directory for a Sun 4 like this: |
283 | ||
5c26072a | 284 | cd gdb-6.3 |
c906108c SS |
285 | mkdir ../gdb-sun4 |
286 | cd ../gdb-sun4 | |
5c26072a | 287 | ../gdb-6.3/configure |
c906108c SS |
288 | make |
289 | ||
290 | When `configure' builds a configuration using a remote source | |
291 | directory, it creates a tree for the binaries with the same structure | |
292 | (and using the same names) as the tree under the source directory. In | |
293 | the example, you'd find the Sun 4 library `libiberty.a' in the | |
294 | directory `gdb-sun4/libiberty', and GDB itself in `gdb-sun4/gdb'. | |
295 | ||
296 | One popular reason to build several GDB configurations in separate | |
297 | directories is to configure GDB for cross-compiling (where GDB runs on | |
298 | one machine--the host--while debugging programs that run on another | |
299 | machine--the target). You specify a cross-debugging target by giving | |
300 | the `--target=TARGET' option to `configure'. | |
301 | ||
302 | When you run `make' to build a program or library, you must run it | |
303 | in a configured directory--whatever directory you were in when you | |
304 | called `configure' (or one of its subdirectories). | |
305 | ||
306 | The `Makefile' that `configure' generates in each source directory | |
307 | also runs recursively. If you type `make' in a source directory such | |
5c26072a AC |
308 | as `gdb-6.3' (or in a separate configured directory configured with |
309 | `--srcdir=PATH/gdb-6.3'), you will build all the required libraries, | |
c906108c SS |
310 | and then build GDB. |
311 | ||
312 | When you have multiple hosts or targets configured in separate | |
313 | directories, you can run `make' on them in parallel (for example, if | |
314 | they are NFS-mounted on each of the hosts); they will not interfere | |
315 | with each other. | |
316 | ||
317 | ||
318 | Specifying names for hosts and targets | |
319 | ====================================== | |
320 | ||
321 | The specifications used for hosts and targets in the `configure' | |
322 | script are based on a three-part naming scheme, but some short | |
323 | predefined aliases are also supported. The full naming scheme encodes | |
324 | three pieces of information in the following pattern: | |
325 | ||
326 | ARCHITECTURE-VENDOR-OS | |
327 | ||
328 | For example, you can use the alias `sun4' as a HOST argument or in a | |
329 | `--target=TARGET' option. The equivalent full name is | |
330 | `sparc-sun-sunos4'. | |
331 | ||
332 | The `configure' script accompanying GDB does not provide any query | |
333 | facility to list all supported host and target names or aliases. | |
334 | `configure' calls the Bourne shell script `config.sub' to map | |
335 | abbreviations to full names; you can read the script, if you wish, or | |
336 | you can use it to test your guesses on abbreviations--for example: | |
337 | ||
338 | % sh config.sub sun4 | |
339 | sparc-sun-sunos4.1.1 | |
340 | % sh config.sub sun3 | |
341 | m68k-sun-sunos4.1.1 | |
342 | % sh config.sub decstation | |
343 | mips-dec-ultrix4.2 | |
344 | % sh config.sub hp300bsd | |
345 | m68k-hp-bsd | |
346 | % sh config.sub i386v | |
347 | i386-pc-sysv | |
348 | % sh config.sub i786v | |
349 | Invalid configuration `i786v': machine `i786v' not recognized | |
350 | ||
351 | `config.sub' is also distributed in the GDB source directory | |
5c26072a | 352 | (`gdb-6.3', for version 6.3). |
c906108c SS |
353 | |
354 | ||
355 | `configure' options | |
356 | =================== | |
357 | ||
358 | Here is a summary of the `configure' options and arguments that are | |
359 | most often useful for building GDB. `configure' also has several other | |
360 | options not listed here. *note : (configure.info)What Configure Does, | |
361 | for a full explanation of `configure'. | |
362 | ||
363 | configure [--help] | |
364 | [--prefix=DIR] | |
365 | [--srcdir=PATH] | |
366 | [--norecursion] [--rm] | |
367 | [--enable-build-warnings] | |
368 | [--target=TARGET] | |
369 | [--host=HOST] | |
370 | [HOST] | |
371 | ||
372 | You may introduce options with a single `-' rather than `--' if you | |
373 | prefer; but you may abbreviate option names if you use `--'. | |
374 | ||
375 | `--help' | |
376 | Display a quick summary of how to invoke `configure'. | |
377 | ||
378 | `-prefix=DIR' | |
379 | Configure the source to install programs and files under directory | |
380 | `DIR'. | |
381 | ||
382 | `--srcdir=PATH' | |
383 | *Warning: using this option requires GNU `make', or another `make' | |
384 | that compatibly implements the `VPATH' feature.* | |
385 | Use this option to make configurations in directories separate | |
386 | from the GDB source directories. Among other things, you can use | |
387 | this to build (or maintain) several configurations simultaneously, | |
388 | in separate directories. `configure' writes configuration | |
389 | specific files in the current directory, but arranges for them to | |
390 | use the source in the directory PATH. `configure' will create | |
391 | directories under the working directory in parallel to the source | |
392 | directories below PATH. | |
393 | ||
394 | `--norecursion' | |
395 | Configure only the directory level where `configure' is executed; | |
396 | do not propagate configuration to subdirectories. | |
397 | ||
398 | `--rm' | |
399 | Remove the configuration that the other arguments specify. | |
400 | ||
401 | `--enable-build-warnings' | |
402 | When building the GDB sources, ask the compiler to warn about any | |
403 | code which looks even vaguely suspicious. You should only using | |
404 | this feature if you're compiling with GNU CC. It passes the | |
405 | following flags: | |
aba7b4b6 AC |
406 | -Wimplicit |
407 | -Wreturn-type | |
408 | -Wcomment | |
409 | -Wtrigraphs | |
410 | -Wformat | |
411 | -Wparentheses | |
c906108c | 412 | -Wpointer-arith |
c906108c SS |
413 | |
414 | `--target=TARGET' | |
415 | Configure GDB for cross-debugging programs running on the specified | |
416 | TARGET. Without this option, GDB is configured to debug programs | |
417 | that run on the same machine (HOST) as GDB itself. | |
418 | ||
419 | There is no convenient way to generate a list of all available | |
420 | targets. | |
421 | ||
422 | `--host=HOST' | |
423 | Configure GDB to run on the specified HOST. | |
424 | ||
425 | There is no convenient way to generate a list of all available | |
426 | hosts. | |
427 | ||
428 | `HOST ...' | |
429 | Same as `--host=HOST'. If you omit this, GDB will guess; it's | |
430 | quite accurate. | |
431 | ||
432 | `configure' accepts other options, for compatibility with configuring | |
433 | other GNU tools recursively; but these are the only options that affect | |
434 | GDB or its supporting libraries. | |
435 | ||
436 | ||
c906108c SS |
437 | Remote debugging |
438 | ================= | |
439 | ||
aba7b4b6 AC |
440 | The files m68k-stub.c, i386-stub.c, and sparc-stub.c are examples |
441 | of remote stubs to be used with remote.c. They are designed to run | |
442 | standalone on an m68k, i386, or SPARC cpu and communicate properly | |
443 | with the remote.c stub over a serial line. | |
c906108c | 444 | |
aba7b4b6 | 445 | The directory gdb/gdbserver/ contains `gdbserver', a program that |
c906108c | 446 | allows remote debugging for Unix applications. gdbserver is only |
aba7b4b6 AC |
447 | supported for some native configurations, including Sun 3, Sun 4, and |
448 | Linux. | |
c906108c | 449 | |
aba7b4b6 | 450 | There are a number of remote interfaces for talking to existing ROM |
c906108c SS |
451 | monitors and other hardware: |
452 | ||
85a453d5 | 453 | remote-e7000.c Renesas E7000 ICE |
c906108c | 454 | remote-est.c EST emulator |
85a453d5 | 455 | remote-hms.c Renesas Micro Systems H8/300 monitor |
c906108c | 456 | remote-mips.c MIPS remote debugging protocol |
c906108c SS |
457 | remote-sds.c PowerPC SDS monitor |
458 | remote-sim.c Generalized simulator protocol | |
459 | remote-st.c Tandem ST-2000 monitor | |
c906108c SS |
460 | remote-vx.c VxWorks realtime kernel |
461 | ||
aba7b4b6 AC |
462 | Remote-vx.c and the vx-share subdirectory contain a remote |
463 | interface for the VxWorks realtime kernel, which communicates over TCP | |
464 | using the Sun RPC library. This would be a useful starting point for | |
465 | other remote- via-ethernet back ends. | |
c906108c | 466 | |
c906108c | 467 | |
129188f6 AC |
468 | Reporting Bugs in GDB |
469 | ===================== | |
470 | ||
471 | There are several ways of reporting bugs in GDB. The prefered | |
472 | method is to use the World Wide Web: | |
473 | ||
474 | http://www.gnu.org/software/gdb/bugs/ | |
475 | ||
476 | As an alternative, the bug report can be submitted, via e-mail, to the | |
477 | address "bug-gdb@gnu.org". | |
c906108c | 478 | |
129188f6 | 479 | When submitting a bug, please include the GDB version number (e.g., |
5c26072a | 480 | gdb-6.3), and how you configured it (e.g., "sun4" or "mach386 host, |
129188f6 | 481 | i586-intel-synopsys target"). Since GDB now supports so many |
aba7b4b6 AC |
482 | different configurations, it is important that you be precise about |
483 | this. If at all possible, you should include the actual banner that | |
484 | GDB prints when it starts up, or failing that, the actual configure | |
485 | command that you used when configuring GDB. | |
c906108c | 486 | |
129188f6 AC |
487 | For more information on how/whether to report bugs, see the |
488 | Reporting Bugs chapter of the GDB manual (gdb/doc/gdb.texinfo). | |
c906108c | 489 | |
aba7b4b6 AC |
490 | |
491 | Graphical interface to GDB -- X Windows, MS Windows | |
492 | ========================== | |
c906108c | 493 | |
aba7b4b6 AC |
494 | Several graphical interfaces to GDB are available. You should |
495 | check: | |
c906108c | 496 | |
d99ba314 | 497 | http://www.gnu.org/software/gdb/links/ |
c906108c | 498 | |
aba7b4b6 | 499 | for an up-to-date list. |
c906108c | 500 | |
aba7b4b6 | 501 | Emacs users will very likely enjoy the Grand Unified Debugger mode; |
f032fb6e | 502 | try typing `M-x gdb RET'. |
c906108c SS |
503 | |
504 | ||
505 | Writing Code for GDB | |
506 | ===================== | |
507 | ||
aba7b4b6 | 508 | There is a lot of information about writing code for GDB in the |
c906108c SS |
509 | internals manual, distributed with GDB in gdb/doc/gdbint.texinfo. You |
510 | can read it by hand, print it by using TeX and texinfo, or process it | |
511 | into an `info' file for use with Emacs' info mode or the standalone | |
512 | `info' program. | |
513 | ||
aba7b4b6 | 514 | If you are pondering writing anything but a short patch, especially |
c906108c SS |
515 | take note of the information about copyrights in the node Submitting |
516 | Patches. It can take quite a while to get all the paperwork done, so | |
517 | we encourage you to start that process as soon as you decide you are | |
518 | planning to work on something, or at least well ahead of when you | |
519 | think you will be ready to submit the patches. | |
520 | ||
521 | ||
522 | GDB Testsuite | |
523 | ============= | |
524 | ||
aba7b4b6 AC |
525 | Included with the GDB distribution is a DejaGNU based testsuite |
526 | that can either be used to test your newly built GDB, or for | |
527 | regression testing a GDB with local modifications. | |
528 | ||
529 | Running the testsuite requires the prior installation of DejaGNU, | |
530 | which is generally available via ftp. The directory | |
47b95330 AC |
531 | ftp://sources.redhat.com/pub/dejagnu/ will contain a recent snapshot. |
532 | Once DejaGNU is installed, you can run the tests in one of the | |
533 | following ways: | |
c906108c | 534 | |
5c26072a | 535 | (1) cd gdb-6.3 |
aba7b4b6 AC |
536 | make check-gdb |
537 | ||
538 | or | |
c906108c | 539 | |
5c26072a | 540 | (2) cd gdb-6.3/gdb |
c906108c SS |
541 | make check |
542 | ||
543 | or | |
544 | ||
5c26072a | 545 | (3) cd gdb-6.3/gdb/testsuite |
c906108c SS |
546 | make site.exp (builds the site specific file) |
547 | runtest -tool gdb GDB=../gdb (or GDB=<somepath> as appropriate) | |
548 | ||
aba7b4b6 AC |
549 | The last method gives you slightly more control in case of problems |
550 | with building one or more test executables or if you are using the | |
551 | testsuite `standalone', without it being part of the GDB source tree. | |
c906108c SS |
552 | |
553 | See the DejaGNU documentation for further details. | |
554 | ||
555 | \f | |
556 | (this is for editing this file with GNU emacs) | |
557 | Local Variables: | |
558 | mode: text | |
559 | End: |