source: general/prog/gdb.xml@ 29d11601

10.0 10.1 11.0 9.1 ken/refactor-virt lazarus qt5new trunk upgradedb xry111/git-date xry111/git-date-for-trunk xry111/git-date-test
Last change on this file since 29d11601 was 29d11601, checked in by Bruce Dubbs <bdubbs@…>, 22 months ago

Update to gdb-9.1.
Update to libgpg-error-1.37.
Update to nss-3.50.
Update to firewalld-0.8.1.

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@22643 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 9.5 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY gdb-download-http "&gnu-http;/gdb/gdb-&gdb-version;.tar.xz">
8 <!ENTITY gdb-download-ftp "&gnu-ftp;/gdb/gdb-&gdb-version;.tar.xz">
9 <!ENTITY gdb-md5sum "f7e9f6236c425097d9e5f18a6ac40655">
10 <!ENTITY gdb-size "20 MB">
11 <!ENTITY gdb-buildsize "656 MB (add 738 MB for docs)">
12 <!ENTITY gdb-time "1.9 SBU (Using parallelism=4; add 18 SBU for tests, add 0.6 SBU for docs)">
13]>
14
15<!-- I skipped running the full tests for this 8.3.1 point version. Bruce -->
16
17<sect1 id="gdb" xreflabel="GDB-&gdb-version;">
18 <?dbhtml filename="gdb.html"?>
19
20 <sect1info>
21 <othername>$LastChangedBy$</othername>
22 <date>$Date$</date>
23 </sect1info>
24
25 <title>GDB-&gdb-version;</title>
26
27 <indexterm zone="gdb">
28 <primary sortas="a-GDB">GDB</primary>
29 </indexterm>
30
31 <sect2 role="package">
32 <title>Introduction to GDB</title>
33
34 <para>
35 <application>GDB</application>, the GNU Project debugger, allows you
36 to see what is going on <quote>inside</quote> another program while it
37 executes -- or what another program was doing at the moment it crashed.
38 Note that <application>GDB</application> is most effective when tracing
39 programs and libraries that were built with debugging symbols and not
40 stripped.
41 </para>
42
43 &lfs90_checked;
44
45 <bridgehead renderas="sect3">Package Information</bridgehead>
46 <itemizedlist spacing="compact">
47 <listitem>
48 <para>
49 Download (HTTP): <ulink url="&gdb-download-http;"/>
50 </para>
51 </listitem>
52 <listitem>
53 <para>
54 Download (FTP): <ulink url="&gdb-download-ftp;"/>
55 </para>
56 </listitem>
57 <listitem>
58 <para>
59 Download MD5 sum: &gdb-md5sum;
60 </para>
61 </listitem>
62 <listitem>
63 <para>
64 Download size: &gdb-size;
65 </para>
66 </listitem>
67 <listitem>
68 <para>
69 Estimated disk space required: &gdb-buildsize;
70 </para>
71 </listitem>
72 <listitem>
73 <para>
74 Estimated build time: &gdb-time;
75 </para>
76 </listitem>
77 </itemizedlist>
78
79 <bridgehead renderas="sect3">GDB Dependencies</bridgehead>
80
81 <bridgehead renderas="sect4">Recommended Runtime Dependency</bridgehead>
82 <para role="recommended">
83 <xref linkend="six"/> (Python 3 module, required at run-time to
84 use GDB scripts from various LFS/BLFS packages with Python 3
85 installed in LFS)
86 </para>
87
88 <bridgehead renderas="sect4">Optional</bridgehead>
89 <para role="optional">
90 <xref linkend="dejagnu"/> (required for tests),
91 <xref linkend="doxygen"/>,
92 <xref linkend="gcc"/> (ada and gfortran are used for tests),
93 <xref linkend="guile"/>,
94 <xref linkend="python2"/>,
95 <xref linkend="rust"/> (used for some tests),
96 <xref linkend="valgrind"/>, and
97 <ulink url="https://sourceware.org/systemtap/">SystemTap</ulink>
98 (run-time, used for tests)
99 </para>
100
101 <para condition="html" role="usernotes">User Notes:
102 <ulink url="&blfs-wiki;/gdb"/>
103 </para>
104 </sect2>
105
106 <sect2 role="installation">
107 <title>Installation of GDB</title>
108
109 <para>
110 Install <application>GDB</application> by running the following
111 commands:
112 </para>
113
114<screen><userinput>mkdir build &amp;&amp;
115cd build &amp;&amp;
116
117../configure --prefix=/usr \
118 --with-system-readline \
119 --with-python=/usr/bin/python3 &amp;&amp;
120make</userinput></screen>
121
122 <para>
123 Optionally, to build the API documentation using
124 <xref linkend="doxygen"/>, run:
125 </para>
126
127<screen remap="doc"><userinput>make -C gdb/doc doxy</userinput></screen>
128
129 <para>
130 To test the results, issue:
131 </para>
132
133<screen remap="test"><userinput>pushd gdb/testsuite &amp;&amp;
134make site.exp &amp;&amp;
135echo "set gdb_test_timeout 120" &gt;&gt; site.exp &amp;&amp;
136runtest
137popd</userinput></screen>
138
139 <para>
140 See <emphasis>gdb/testsuite/README</emphasis> and <ulink
141 url="https://sourceware.org/gdb/wiki/TestingGDB">TestingGDB</ulink>.
142 There are many problems with the test suite:
143 </para>
144
145 <itemizedlist>
146 <listitem>
147 <para>
148 Clean directories are needed if re-running the tests. For that
149 reason, make a copy of the compiled source code
150 directory before the tests in case you need to run the tests again.
151 </para>
152 </listitem>
153
154 <listitem>
155 <para>
156 Results depend on installed compilers.
157 </para>
158 </listitem>
159<!-- I did not see this
160 <listitem>
161 <para>
162 There are a large number of timeouts (there is a variable
163 that can be set to increase time for timeout, but
164 changing it will result in a different number of tests being
165 run).
166 </para>
167 </listitem>
168or this
169 <listitem>
170 <para>
171 There are failures associated with system readline 6.x.
172 </para>
173 </listitem>
174-->
175 <listitem>
176 <para>
177 A few tests assume that the header file
178 <filename>&lt;sys/sdt.h&gt;</filename>, part of <ulink
179 url="https://sourceware.org/systemtap/">SystemTap</ulink>, is
180 present.
181 </para>
182 </listitem>
183<!-- I don't know if this is true or not. I tested on a Haswell.
184 <listitem>
185 <para>
186 If the test suite is run on a Skylake-based Intel CPU or newer,
187 many tests will fail due to the removal of the deprecated/problematic
188 libmpx library in GCC.
189 </para>
190 </listitem>
191-->
192 <listitem>
193 <para>
194 A test run of the test suite had 228 unexpected failures
195 (out of over 70000 tests).
196 </para>
197 </listitem>
198
199 </itemizedlist>
200
201 <para>
202 Now, as the <systemitem class="username">root</systemitem> user:
203 </para>
204
205<screen role="root"><userinput>make -C gdb install</userinput></screen>
206
207 <para>
208 If you have built the API documentation, it is now in gdb/doc/doxy.
209 You can install it (as the <systemitem class="username">root</systemitem>
210 user):
211 </para>
212
213<screen role="root"
214 remap="doc"><userinput>install -d /usr/share/doc/gdb-&gdb-version; &amp;&amp;
215rm -rf gdb/doc/doxy/xml &amp;&amp;
216cp -Rv gdb/doc/doxy /usr/share/doc/gdb-&gdb-version;</userinput></screen>
217
218 </sect2>
219
220 <sect2 role="commands">
221 <title>Command Explanations</title>
222
223 <para>
224 <parameter>--with-system-readline</parameter>: This switch forces
225 <application>GDB</application> to use the copy of
226 <application>Readline</application> installed in LFS.
227 </para>
228
229 <para>
230 <parameter>--with-python=/usr/bin/python3</parameter>: This switch
231 forces <application>GDB</application> to use Python 3 installed
232 in LFS. Remove this switch if you have installed
233 <xref linkend="python2"/> and want to use it instead of Python 3.
234 </para>
235
236 </sect2>
237
238 <sect2 role="content">
239 <title>Contents</title>
240
241 <segmentedlist>
242 <segtitle>Installed Programs</segtitle>
243 <segtitle>Installed Library</segtitle>
244 <segtitle>Installed Directories</segtitle>
245
246 <seglistitem>
247 <seg>
248 gcore, gdb and gdbserver
249 </seg>
250 <seg>
251 libinproctrace.so
252 </seg>
253 <seg>
254 /usr/{include,share}/gdb and /usr/share/doc/gdb-&gdb-version;
255 </seg>
256 </seglistitem>
257 </segmentedlist>
258
259 <variablelist>
260 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
261 <?dbfo list-presentation="list"?>
262 <?dbhtml list-presentation="table"?>
263
264 <varlistentry id="gcore">
265 <term><command>gcore</command></term>
266 <listitem>
267 <para>
268 generates a core dump of a running program.
269 </para>
270 <indexterm zone="gdb gcore">
271 <primary sortas="b-gcore">gcore</primary>
272 </indexterm>
273 </listitem>
274 </varlistentry>
275
276 <varlistentry id="gdb-prog">
277 <term><command>gdb</command></term>
278 <listitem>
279 <para>
280 is the GNU Debugger.
281 </para>
282 <indexterm zone="gdb gdb-prog">
283 <primary sortas="b-gdb-prog">gdb-prog</primary>
284 </indexterm>
285 </listitem>
286 </varlistentry>
287
288 <varlistentry id="gdbserver">
289 <term><command>gdbserver</command></term>
290 <listitem>
291 <para>
292 is a remote server for the GNU debugger (it allows programs
293 to be debugged from a different machine).
294 </para>
295 <indexterm zone="gdb gdbserver">
296 <primary sortas="b-gdbserver">gdbserver</primary>
297 </indexterm>
298 </listitem>
299 </varlistentry>
300
301 <varlistentry id="libinproctrace">
302 <term><filename class="libraryfile">libinproctrace.so</filename></term>
303 <listitem>
304 <para>
305 contains functions for the in-process tracing agent. The agent
306 allows for installing fast tracepoints, listing static tracepoint
307 markers, probing static tracepoints markers, and starting trace
308 monitoring.
309 </para>
310 <indexterm zone="gdb libinproctrace">
311 <primary sortas="c-libinproctrace">libinproctrace.so</primary>
312 </indexterm>
313 </listitem>
314 </varlistentry>
315
316 </variablelist>
317
318 </sect2>
319
320</sect1>
Note: See TracBrowser for help on using the repository browser.