Debugger help

Christopher Faylor cygwin@sourceware.cygnus.com
Fri Dec 31 13:28:00 GMT 1999


On Fri, Dec 24, 1999 at 08:59:48PM +0100, Joost Kraaijeveld wrote:
>No. That just runs to main, after displaying a message about a SIGSEGV
>with completely useless stacktrace (I can compare the stacktrace to
>trace statements inserted in the code). So what I want is to start from
>the very first line of code an step untill the offending line. Maby it
>has something to do with that fact that I am talking about 3 dll's and
>an executable. Because when I put all the source in one directory and
>create one big executable all works as expected.

No, it doesn't just "run to main".  If it did, I would never be able to
debug the cygwin DLL.  I assume that you are trying to debug a
cygwin-based program since you're sending mail to the cygwin newsgroup.

gdb will stop when the program gets a SIGSEGV.  That's what it is designed
to do and that's what it does.

If you are using a version of gdb that is newer than B20.1 you may be
experiencing the fact that gdb can now handle multiple threads.  So,
typing "thread 1" will switch you to your main thread.

One breakpoint that you can set prior to main is dll_crt0_1.  This is
in the cygwin DLL so you will first have to load its symbols with a:

add-sym cygwin1.dll 0x61001000

cgf

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com



More information about the Cygwin mailing list