[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Debugging 3.21 code under a 2.95.2 build
From: |
Cal Erickson |
Subject: |
Re: Debugging 3.21 code under a 2.95.2 build |
Date: |
Wed, 22 Oct 2003 14:34:17 -0700 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i586; en-US; rv:0.9.4.1) Gecko/20020314 Netscape6/6.2.2 |
Gary,
You could use LD_LIBRARY_PATH=<path to stdc+ lib> in your environment.
Then gdb will find the proper library. DDD has nothing to do with
finding the correct library. You could also try set solib-path in the
gdb window.
Cal Erickson
Gary Knight wrote:
Hello;
In perusing the DDD manual, last edited it seems in 2001, I found
nothing helpful for users who can't get an executable compiled
'recently' to run under DDD (or gdb) that was built as long ago as, say
2001. We have a Unix network (Sun Sparks 2.9 or so) where DDD has been a
workhorse for 'vanilla' C code and C++ executables that were link-loaded
under gcc version 2.95.2. However, newer codes compiled under gcc 3.21,
with a different stdc++ library, do not run in DDD (or gdb). They open
fine, with no warning, but at the run command, the inferior debugger
dies because it can't find the new stdc++ library.
It would be helpful to indicate what to do, short of a recompile of
gdb, to 'fool' DDD to locate the newer library. It is not smart enough
to notice an environment string (in bash) specifying the path, although
that path was recognized by the gcc compiler-loader! One solution would
be to add a command string intended for dbg in the init file, fingering
the library or path. Anothrt brutish solution is to copy the 3.21
library into the same old folder where the 2.95.2 libraries exist (or
whatever version was used to compile gdb in the first place). Or have I
missed something that should have been obvious?
Future versions of DDD ought to notify the user at file-open time that
an executable will want libraries that seem unknown or unavailable to
the debugger, and even offer suggestions (or dialogue) to specify the
library paths, for saving as options to the init file. A concept index
entry for "dynamic library" or "library references" would be good.
Cheers, Gary
--
===========================================================================
Cal Erickson MontaVista Software Inc.
Linux Consultant 1237 E. Arques Ave.
Phone (408) 328-0304 Sunnyvale CA 94085
Fax (408) 328-9204 web http://www.mvista.com
===========================================================================