swift 05/07/14 09:42:27 Modified: xml/htdocs/doc/en/draft debugging-howto.xml Log: Coding Style
Revision Changes Path 1.3 +27 -26 xml/htdocs/doc/en/draft/debugging-howto.xml file : http://www.gentoo.org/cgi-bin/viewcvs.cgi/xml/htdocs/doc/en/draft/debugging-howto.xml?rev=1.3&content-type=text/x-cvsweb-markup&cvsroot=gentoo plain: http://www.gentoo.org/cgi-bin/viewcvs.cgi/xml/htdocs/doc/en/draft/debugging-howto.xml?rev=1.3&content-type=text/plain&cvsroot=gentoo diff : http://www.gentoo.org/cgi-bin/viewcvs.cgi/xml/htdocs/doc/en/draft/debugging-howto.xml.diff?r1=1.2&r2=1.3&cvsroot=gentoo Index: debugging-howto.xml =================================================================== RCS file: /var/cvsroot/gentoo/xml/htdocs/doc/en/draft/debugging-howto.xml,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- debugging-howto.xml 13 Jul 2005 18:58:31 -0000 1.2 +++ debugging-howto.xml 14 Jul 2005 09:42:27 -0000 1.3 @@ -1,6 +1,6 @@ <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE guide SYSTEM "/dtd/guide.dtd"> -<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/draft/debugging-howto.xml,v 1.2 2005/07/13 18:58:31 fox2mike Exp $ --> +<!-- $Header: /var/cvsroot/gentoo/xml/htdocs/doc/en/draft/debugging-howto.xml,v 1.3 2005/07/14 09:42:27 swift Exp $ --> <guide link="/doc/en/debugging-howto.xml"> <title>Gentoo Linux Debugging Guide</title> @@ -138,8 +138,8 @@ </pre> <p> -Lastly, you can also add debug to the package's USE flags. This can be done with the -<path>package.use</path> file. +Lastly, you can also add debug to the package's USE flags. This can be done +with the <path>package.use</path> file. </p> <pre caption="Using package.use to add debug USE flag"> @@ -245,8 +245,8 @@ run_it(), and somewhere in run_it() lies the strcpy() at fault. Things such as this help developers narrow down problems. There are a few exceptions to the output. First off is forgetting to enable debug symbols with -<c>FEATURES="nostrip"</c>. With debug symbols stripped, the output looks something -like this: +<c>FEATURES="nostrip"</c>. With debug symbols stripped, the output looks +something like this: </p> <pre caption="Program backtrace With debug symbols stripped"> @@ -311,13 +311,14 @@ </pre> <p> -As you can see, -ggdb3 adds about <e>13178</e> more bytes to the file size over the one -with debugging symbols. However, as shown above, this increase in file size can -be worth it if presenting debug information to developers. The backtrace can be -saved to a file by copying and pasting from the terminal (if it's a non-x based -terminal, you can use gpm. To keep this doc simple, I recommend you read up on -the documentation for gpm to see how to copy and paste with it). Now that we're -done with <c>gdb</c>, we can quit. +As you can see, -ggdb3 adds about <e>13178</e> more bytes to the file size +over the one with debugging symbols. However, as shown above, this increase +in file size can be worth it if presenting debug information to developers. +The backtrace can be saved to a file by copying and pasting from the +terminal (if it's a non-x based terminal, you can use gpm. To keep this +doc simple, I recommend you read up on the documentation for gpm to see +how to copy and paste with it). Now that we're done with <c>gdb</c>, we +can quit. </p> <pre caption="Quitting GDB"> @@ -327,11 +328,11 @@ </pre> <p> -This ends the walk-through of <c>gdb</c>. Using <c>gdb</c>, we hope that you will -be able to use it to create better bug reports. However, there are other types -of errors that can cause a program to fail during run time. One of the other -ways is through improper file access. We can find those using a nifty little -tool called <c>strace</c>. +This ends the walk-through of <c>gdb</c>. Using <c>gdb</c>, we hope that you +will be able to use it to create better bug reports. However, there are other +types of errors that can cause a program to fail during run time. One of the +other ways is through improper file access. We can find those using a nifty +little tool called <c>strace</c>. </p> </body> @@ -350,9 +351,9 @@ tool called <c>strace</c> was created to help deal with this. <c>strace</c> traces system calls (hence the name) which include calls that use the memory and files. For our example, we're going to take a program foobar2. This is an -updated version of foobar. However, during the change over to foobar2, you notice -all your configurations are missing! In foobar version 1, you had it setup to -say "foo", but now it's using the default "bar". +updated version of foobar. However, during the change over to foobar2, you +notice all your configurations are missing! In foobar version 1, you had it +setup to say "foo", but now it's using the default "bar". </p> <pre caption="Foobar2 With an invalid configuration"> @@ -406,9 +407,9 @@ <body> <p> -<c>strace</c> is a great way at seeing what the kernel is doing to with the filesystem. -Another program exists to help users see what the kernel is doing, and help with -kernel debugging. This program is called <c>dmesg</c> +<c>strace</c> is a great way at seeing what the kernel is doing to with the +filesystem. Another program exists to help users see what the kernel is doing, +and help with kernel debugging. This program is called <c>dmesg</c>. </p> </body> @@ -569,9 +570,9 @@ </pre> <p> -The program is compiling smoothly when it suddenly stops and presents an error message. This -particular error can be split into 3 different sections, The compile messages, the build -error, and the emerge error message as shown below. +The program is compiling smoothly when it suddenly stops and presents an error +message. This particular error can be split into 3 different sections, The +compile messages, the build error, and the emerge error message as shown below. </p> <pre caption="Parts of the error"> -- [email protected] mailing list
