RFC --enable-debugging

Brad Spencer spencer@infointeractive.com
Wed Nov 6 12:42:00 GMT 2002


On Sat, Nov 02, 2002 at 02:15:27PM +0100, Gabriel Dos Reis wrote:
> Let me rephrase my question
> 
>   1) Is there any automated way to have the compiler pick the debug
>      library when a program is linked with -g?

As an everyday library user, I compile and link everything with -g
even when I build final release builds with full optimization so that
the debugging symbols are in the binary in the event of a crash.  If
-g becomes overloaded to also mean "pick a non-optimized library
implementation", this could be a nasty surprise.

Perhaps I simply shouldn't be specifying -g on the _link_ line?  I
prefer the explicit -L method.  BTW, -g is currently not listed in the
gcc manual as an option that affects linking, AFAICT.

-- 
------------------------------------------------------------------
Brad Spencer - spencer@infointeractive.com - "It's quite nice..."
Systems Architect | InfoInterActive Corp. | A Canadian AOL Company



More information about the Libstdc++ mailing list