8

I'm trying to debug a program in Code::Blocks. I followed this guide and this short video as far as I could, but the debugger doesn't stop at breakpoints...

I saw a similar question which remained unsolved (I wasn't sure if I should bump it or open a new one with more details), I do have the "Produce debugging symbols [-g]" flag checked. Optimizations and "Strip all symbols [-s]" are also all disabled. I even tried the flag -ggdb as suggested there, no success either.

I'm using TDM-GCC 4.5.2 (I just upgraded, previously I had the same issue with 4.5.1), and the debugger is GNU gdb (GDB) 7.2 (previously same issue with GDB 7.1). I'm on Windows 7 x64, using Code::Blocks SVN 7040 (that's the latest nightly build, as as far as I know they recommend them over the not often updated stable builds) (I had the same issue in SVN 6931).

Finally, I also noticed that the debugger complains about the lack of debugging symbols, here's the output in the debugger window:

Build succeeded
Selecting target: 
Debug
Adding source dir: G:\[...]\IPCMB3\
Adding source dir: G:\[...]\IPCMB3\
Adding file: bin\Debug\IPCMB3.exe
Starting debugger: 
done
Registered new type: wxString
Registered new type: STL String
Registered new type: STL Vector
Setting breakpoints
Reading symbols from G:\[...]\IPCMB3/bin/Debug/IPCMB3.exe...(no debugging symbols found)...done.
Debugger name and version: GNU gdb (GDB) 7.2
Child process PID: 6044
Program exited normally.
Debugger finished with status 0

Thanks

5
  • Could you copy here the entire command line for the build process? It might help more Commented Mar 28, 2011 at 14:02
  • Hi, I just searched around for 10 minutes to avoid asking such a basic question, but didn't manage to find out: where do you find the build command line in Code::Blocks? Commented Mar 28, 2011 at 14:51
  • The build commandline is in the little window on the bottom. If the debugger complains about no symbols, there are two possibilities. Either you do not have "Produce debugging symbols" enabled, or you do have "Strip all symbols from program" enabled. You find both by right-clicking on your project and choosing "Build settings...". Make sure that symbols are produced, and not stripped. Be sure to always do a full rebuild when changing those settings. Commented Mar 28, 2011 at 20:46
  • Hm, I already looks there but couldn't find it. Are we both talking about the "Logs & others" window? (that's the window I have at the bottom). If yes, when I compile, the only tabs that get populated are "Build logs" and "Build messages". Neither of them contain the build command line. For instance here's the build log: img830.imageshack.us/img830/6076/compiledebug.png Commented Mar 29, 2011 at 7:39
  • go under settings->compiler debugger->Global compiler settings. Under build options or other settings you will find 'compiler logging'. Set that to 'Full Commandline' and rebuild. Then edit your post here and post the build log you get. Commented Apr 24, 2011 at 20:45

1 Answer 1

10

i dont know if u solved it already but i had the same problem and just solved it!! i have searched a lot all over and eventually the problem was....

non ASCII chars on the project path !!

i had some hebrew letters on the folder path where my files are located !! i changed it to regular english letters and the debugger worked!!

Edit: just to make it clear - all i did eventually is to change the folder name in the file system from hebrew to english

Sign up to request clarification or add additional context in comments.

3 Comments

how did u actually change it?
i just changed the folder name in my file system
yup - C::B has that issue: wiki.codeblocks.org/…... i lost 5 hours today trying to configure cdb with c::b

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.