John,
This is a follow-up on our discussion yesterday.
The problem is that in CodeBlocks gdb will not stop at a breakpoint in a header file.
I thought initially that the problem was in CodeBlocks but I now believe otherwise.
For example, the problem disappears when I revert to an earlier MinGS/Gcc version, say,
MinGW-5.1.4.exe; and it re-occurs when I do a fresh install using your bundled installer 1.803.3.
I am running Windows XP and your bundled installer, such that the gcc and ld versions are as follows:
C:\CB>gcc -v
Using built-in specs.
Target: mingw32
Configured with: ../gcc-4.3.2/configure --prefix=/mingw --build=mingw32 --enable-languages=c,ada,c++,fortran,objc,obj-c++ --with-b
ugurl=http://www.tdragon.net/recentgcc/bugs.php --disable-nls --disable-win32-registry --enable-libgomp --disable-werror --enable-
threads --disable-symvers --enable-cxx-flags='-fno-function-sections -fno-data-sections' --enable-fully-dynamic-string --enable-ve
rsion-specific-runtime-libs --enable-sjlj-exceptions --with-pkgversion='4.3.2-tdm-1 for MinGW'
Thread model: win32
gcc version 4.3.2 (4.3.2-tdm-1 for MinGW)
C:\CB>ld -v
GNU ld (GNU Binutils) 2.18.50.20080109
I have reduced the problem to a very simple example demonstrating that the compiler is
having a problem with backslashes in the source filename. (CodeBlocks uses backslahses
for filename paths - at least in Windows.) The attached file gives a step-by-step command line procedure for demonstrating the problem.
Thanks,
Bob
Anonymous
Text file illustrating problem
Thanks for the bug repot. Thanks to your work at pinpointing, I've found that the problem is caused by GCC erroneously tacking an extra slash on before the file name (in the sample case, generating "C:/CB//Function.h" instead of "C:/CB/Function.h" as before). I'll be following up on this hopefully in the near future.
John,
I noticed that you are planning a new bugfix release and are examining this bug for local fixability.
This problem has really been "bugging" me lately, and I hope you can come up with a fix. If not, could you recommend the appropriate forum, gcc or mingw, for submitting another bug report.
Thanks,
Bob
Yes, as of Friday I have successfully tested a local patch to fix this bug. :)
John,
Just a note to say that I installed your latest version and it appears to have solved the header debug problem. (I still have problems debugging headers with CodeBlocks using relative paths in the Search directories; but that appears to be a different issue and I can get the debugger to work using absolute paths.)
Good work, sir; and thank you very much!
Bob
Thanks in return for your efforts in reporting and pinpointing. (Also for the donation! Much appreciated!)