How to configure GCC as debuggable

Bernd Feindt
Thu Oct 14 11:36:00 GMT 2004


I'm occupying myself with G++ for a while now and found out that it would be
easier to understand the parser (and perhaps the backend) when I was able to
follow the control flow during compilation of simple code samples with a
debugger (gdb).

Unfortunately, I can't find any standard settings to build a GCC/G++
containing debugging information. I'm not very experienced with the build
process of GCC. All that I know is that I have to do a "./configure" in the
object dir and then run make. The source is being compiled over three stages
and finally the binaries can be installed in their destination dirs,
resulting in a new working GCC.

The documentation is silent about this point and "./configure --help"
doesn't offer any debugging settings, but I'm sure there must be some.
Especially it seems to me that it can't be necessary to go through all three
stages to get a debuggable binary (BTW what is "bootstrapping"? I never
understood this).

Does anybody know how to do this? Thank you in advance,

GMX ProMail mit bestem Virenschutz
+++ Empfehlung der Redaktion +++ Internet Professionell 10/04 +++

More information about the Gcc mailing list