User forums > Help

GDB Skips break points

(1/2) > >>

Geoffles:
Hi there,

I seem to be having some problems while trying to debug. Although i can set break points in my different source files, GDB doesnt seem to stop on them except for my main source file. I can step through the program, but commands such as run to cursor just finish running the program and don't stop.

Is this normal GDB behaviour? Is it something I am doing or is this a code::blocks problem?

I'm using CB 8.02 with MinGW 3.4.5, and its GDB 5.2.1

Any help would be greatly appreciated, thanks :)

Pecan:
http://wiki.codeblocks.org/index.php?title=Debugging_with_Code::Blocks
Debugging with Code::Blocks - CodeBlocks

Maybe the workaround for breakpoints in ctors/dtors will help.

Pecan:
That GDB version should be at least 6.3.

You could just use the one suggested by the CodeBlocks install.

Geoffles:
Thanks for your reply, I have updated my GDB to 6.8 now, and I have read the link you posted and I tried a little experiment.

I don't know quite what is going on, but when I first tried the debugging after updating GDB it didn't make any difference, then I tried doing a clean build, and it still didn't work. Then I tried making dummy class which then worked, even from the constructor. I then removed it and suddenly it was stopping at my break points Oo

Other thing I tried changing was explicit inclusion of all the header files my main source file, and i cant seem to replicate it not stopping at the break points any more, which is a good thing, unless it happens again :P

Thanks for your help!

Pecan:
Another suggestion:

Make sure that all your debugged source files are part of (included in) a CodeBlocks project so that CodeBlocks can effectively handle handing off the source files and their location to GDB.

Navigation

[0] Message Index

[#] Next page

Go to full version