On Fri, Mar 27, 2009 at 1:43 AM, Nirf <
quicknir@...> wrote:
> I'm trying to get started with GDB but am having great trouble.
On what platform? Using which version of GDB?
Note that on Linux, or any other platform that uses DWARF
debug format, you shouldn't need to specify 'directory ...'
at all if you build and debug on the same machine: compiler
already supplies all the info GDB needs to find sources
regardless of where in file system they are located.
> However when I type in a command like "list sourcecodename:5" it does not
> find the source code regardless of which file name I insert for
> sourcecodename.
Did you build your program with debugging info (the '-g' GCC option) ?
Cheers,
--
Paul Pluzhnikov