home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!elroy.jpl.nasa.gov!nntp-server.caltech.edu!cithe502.cithep.caltech.edu!walter
- From: walter@cithe501.cithep.caltech.edu (Chris Walter)
- Newsgroups: comp.unix.aix
- Subject: Problem debugging g++ compiled code with gdb.
- Date: 23 Dec 1992 06:55:58 GMT
- Organization: California Institute of Technology, Pasadena
- Lines: 51
- Distribution: world
- Message-ID: <1h92huINNsio@gap.caltech.edu>
- NNTP-Posting-Host: cithe502.cithep.caltech.edu
- Originator: walter@cithe502.cithep.caltech.edu
-
- Hi Folks,
-
- First off I am running AIX3.2 on an RS6000.
-
- I recently started programming in C++ so I got and installed
- g++/libg++.(gcc 2.3.2/libg++ 2.3). Everything seems to be working
- fine. Of course I soon wanted to debug my programs.... So I went and
- got gdb 4.7. Everything in the make went fine and there were no complaints
- during the procedure.
-
- gdb seems to work OK on small C programs compiled with gcc but I am
- having problems debugging C++ code compiled(-g of course) with g++.
-
- Here is an example of what happens when I try to load a executable:
- ------------------------------------------------------------------------
- cithe502:wfd > gdb
- GDB is free software and you are welcome to distribute copies of it
- under certain conditions; type "show copying" to see the conditions.
- There is absolutely no warranty for GDB; type "show warranty" for details.
- GDB 4.7, Copyright 1992 Free Software Foundation, Inc.
- (gdb) file monte
- Reading symbols from monte...GDB Error: `.bf' not found.
- GDB Error: `.bf' not found.
- done.
- (gdb)
- ------------------------------------------------------------------------
-
- And here is the same thing for what I thought was a simpler program:
-
- ------------------------------------------------------------------------
- cithe502:flux > gdb
- GDB is free software and you are welcome to distribute copies of it
- under certain conditions; type "show copying" to see the conditions.
- There is absolutely no warranty for GDB; type "show warranty" for details.
- GDB 4.7, Copyright 1992 Free Software Foundation, Inc.
- (gdb) file flux
- Reading symbols from flux...GDB Error: `.bf' not found.
- GDB Error: `.bf' not found.
-
- Catastrophe in realloc: invalid storage ptr
- IOT trap (core dumped)
- cithe502:flux >
- ------------------------------------------------------------------------
-
- In addition, the first program, which it allows me to load, starts in the
- middle of the routine if I tell it to "break main". It sets the
- breakpoint something like halfway down the routine.
-
- Any suggestions happily accepted!
-
- -Chris Walter
-