⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 readme

📁 早期freebsd实现
💻
📖 第 1 页 / 共 2 页
字号:
		README for gdb-4.7 release    Stu Grossman & John Gilmore 	23 October 1992This is GDB, the GNU source-level debugger, presently running under un*x.A summary of new features is in the file `NEWS'.Unpacking and Installation -- quick overview==========================In this release, the GDB debugger sources, the generic GNU includefiles, the BFD ("binary file description") library, the readline library,and other libraries all have directories of their own underneaththe gdb-4.7 directory.  The idea is that a variety of GNU tools canshare a common copy of these things.  Configuration scripts andmakefiles exist to cruise up and down this directory tree andautomatically build all the pieces in the right order.When you unpack the gdb-4.7.tar.Z file, you'll get a directory called`gdb-4.7', which contains:  COPYING.LIB      config/          configure.texi   mmalloc/  Makefile.in      config.sub*      gdb/             move-if-change*  README           configure*       glob/            opcodes/  bfd/             configure.in     include/         readline/  cfg-paper.texi   configure.man    libiberty/       texinfo/To build GDB, you can just do:	cd gdb-4.7	./configure HOSTTYPE		(e.g. sun4, decstation)	make	cp gdb/gdb /usr/local/bin/gdb	(or wherever you want)This will configure and build all the libraries as well as GDB.If you get compiler warnings during this stage, see the `Reporting Bugs'section below; there are a few known problems.GDB can be used as a cross-debugger, running on a machine of one typewhile debugging a program running on a machine of another type.  See below.More Documentation******************   The GDB 4 release includes an already-formatted reference card, readyfor printing with PostScript or GhostScript, in the `gdb' subdirectoryof the main source directory--in `gdb-4.7/gdb/refcard.ps' of theversion 4.7 release. If you can use PostScript or GhostScript with yourprinter, you can print the reference card immediately with `refcard.ps'.   The release also includes the source for the reference card.  Youcan format it, using TeX, by typing:     make refcard.dvi   The GDB reference card is designed to print in landscape mode on US"letter" size paper; that is, on a sheet 11 inches wide by 8.5 incheshigh.  You will need to specify this form of printing as an option toyour DVI output program.   All the documentation for GDB comes as part of the machine-readabledistribution.  The documentation is written in Texinfo format, which isa documentation system that uses a single source file to produce bothon-line information and a printed manual.  You can use one of the Infoformatting commands to create the on-line version of the documentationand TeX (or `texi2roff') to typeset the printed version.   GDB includes an already formatted copy of the on-line Info version ofthis manual in the `gdb' subdirectory.  The main Info file is`gdb-VERSION-NUMBER/gdb/gdb.info', and it refers to subordinate filesmatching `gdb.info*' in the same directory.  If necessary, you canprint out these files, or read them with any editor; but they areeasier to read using the `info' subsystem in GNU Emacs or thestandalone `info' program, available as part of the GNU Texinfodistribution.   If you want to format these Info files yourself, you need one of theInfo formatting programs, such as `texinfo-format-buffer' or `makeinfo'.   If you have `makeinfo' installed, and are in the top level GDBsource directory (`gdb-4.7', in the case of version 4.7), you can makethe Info file by typing:     cd gdb     make gdb.info   If you want to typeset and print copies of this manual, you needTeX, a printing program such as `lpr', and `texinfo.tex', the Texinfodefinitions file.   TeX is typesetting program; it does not print files directly, butproduces output files called DVI files.  To print a typeset document,you need a program to print DVI files.  If your system has TeXinstalled, chances are it has such a program.  The precise command touse depends on your system; `lpr -d' is common; another is `dvips'. The DVI print command may require a file name without any extension ora `.dvi' extension.   TeX also requires a macro definitions file called `texinfo.tex'. This file tells TeX how to typeset a document written in Texinfoformat.  On its own, TeX cannot read, much less typeset a Texinfo file. `texinfo.tex' is distributed with GDB and is located in the`gdb-VERSION-NUMBER/texinfo' directory.   If you have TeX and a DVI printer program installed, you can typesetand print this manual.  First switch to the the `gdb' subdirectory ofthe main source directory (for example, to `gdb-4.7/gdb') and then type:     make gdb.dviInstalling GDB***************   GDB comes with a `configure' script that automates the process ofpreparing GDB for installation; you can then use `make' to build theprogram.   The GDB distribution includes all the source code you need for GDB ina single directory, whose name is usually composed by appending theversion number to `gdb'.   For example, the GDB version 4.7 distribution is in the `gdb-4.7'directory.  That directory contains:`gdb-4.7/configure (and supporting files)'     script for configuring GDB and all its supporting libraries.`gdb-4.7/gdb'     the source specific to GDB itself`gdb-4.7/bfd'     source for the Binary File Descriptor library`gdb-4.7/include'     GNU include files`gdb-4.7/libiberty'     source for the `-liberty' free software library`gdb-4.7/opcodes'     source for the library of opcode tables and disassemblers`gdb-4.7/readline'     source for the GNU command-line interface`gdb-4.7/glob'     source for the GNU filename pattern-matching subroutine`gdb-4.7/mmalloc'     source for the GNU memory-mapped malloc package   The simplest way to configure and build GDB is to run `configure'from the `gdb-VERSION-NUMBER' source directory, which in this exampleis the `gdb-4.7' directory.   First switch to the `gdb-VERSION-NUMBER' source directory if you arenot already in it; then run `configure'.  Pass the identifier for theplatform on which GDB will run as an argument.   For example:     cd gdb-4.7     ./configure HOST     makewhere HOST is an identifier such as `sun4' or `decstation', thatidentifies the platform where GDB will run.   Running `configure HOST' followed by `make' builds the `bfd',`readline', `mmalloc', and `libiberty' libraries, then `gdb' itself. The configured source files, and the binaries, are left in thecorresponding source directories.   `configure' is a Bourne-shell (`/bin/sh') script; if your systemdoes not recognize this automatically when you run a different shell,you may need to run `sh' on it explicitly:     sh configure HOST   If you run `configure' from a directory that contains sourcedirectories for multiple libraries or programs, such as the `gdb-4.7'source directory for version 4.7, `configure' creates configurationfiles for every directory level underneath (unless you tell it not to,with the `--norecursion' option).   You can run the `configure' script from any of the subordinatedirectories in the GDB distribution, if you only want to configure thatsubdirectory; but be sure to specify a path to it.   For example, with version 4.7, type the following to configure onlythe `bfd' subdirectory:     cd gdb-4.7/bfd     ../configure HOST   You can install `gdb' anywhere; it has no hardwired paths. However,you should make sure that the shell on your path (named by the `SHELL'environment variable) is publicly readable.  Remember that GDB uses theshell to start your program--some systems refuse to let GDB debug childprocesses whose programs are not readable.Compiling GDB in Another Directory===================================   If you want to run GDB versions for several host or target machines,you'll need a different `gdb' compiled for each combination of host andtarget.  `configure' is designed to make this easy by allowing you togenerate each configuration in a separate subdirectory, rather than inthe source directory.  If your `make' program handles the `VPATH'feature (GNU `make' does), running `make' in each of these directoriesthen builds the `gdb' program specified there.   To build `gdb' in a separate directory, run `configure' with the`--srcdir' option to specify where to find the source. (You'll alsoneed to specify a path to find `configure' itself from your workingdirectory.  If the path to `configure' would be the same as theargument to `--srcdir', you can leave out the `--srcdir' option; itwill be assumed.)   For example, with version 4.7, you can build GDB in a separatedirectory for a Sun 4 like this:     cd gdb-4.7     mkdir ../gdb-sun4     cd ../gdb-sun4     ../gdb-4.7/configure sun4     make   When `configure' builds a configuration using a remote sourcedirectory, it creates a tree for the binaries with the same structure(and using the same names) as the tree under the source directory.  Inthe example, you'd find the Sun 4 library `libiberty.a' in thedirectory `gdb-sun4/libiberty', and GDB itself in `gdb-sun4/gdb'.   One popular reason to build several GDB configurations in separatedirectories is to configure GDB for cross-compiling (where GDB runs onone machine--the host--while debugging programs that run on anothermachine--the target).  You specify a cross-debugging target by givingthe `--target=TARGET' option to `configure'.   When you run `make' to build a program or library, you must run itin a configured directory--whatever directory you were in when youcalled `configure' (or one of its subdirectories).   The `Makefile' generated by `configure' for each source directoryalso runs recursively.  If you type `make' in a source directory suchas `gdb-4.7' (or in a separate configured directory configured with`--srcdir=PATH/gdb-4.7'), you will build all the required libraries,then build GDB.   When you have multiple hosts or targets configured in separatedirectories, you can run `make' on them in parallel (for example, ifthey are NFS-mounted on each of the hosts); they will not interferewith each other.Specifying Names for Hosts and Targets=======================================   The specifications used for hosts and targets in the `configure'script are based on a three-part naming scheme, but some shortpredefined aliases are also supported.  The full naming scheme encodesthree pieces of information in the following pattern:     ARCHITECTURE-VENDOR-OS   For example, you can use the alias `sun4' as a HOST argument or in a`--target=TARGET' option, but the equivalent full name is`sparc-sun-sunos4'.   The `configure' script accompanying GDB does not provide any queryfacility to list all supported host and target names or aliases. `configure' calls the Bourne shell script `config.sub' to mapabbreviations to full names; you can read the script, if you wish, oryou can use it to test your guesses on abbreviations--for example:     % sh config.sub sun4     sparc-sun-sunos411     % sh config.sub sun3     m68k-sun-sunos411     % sh config.sub decstation     mips-dec-ultrix42     % sh config.sub hp300bsd     m68k-hp-bsd     % sh config.sub i386v     i386-unknown-sysv     % sh config.sub i786v

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -