Author Topic: Debugging CB by itself  (Read 5242 times)

Offline lexis

  • Multiple posting newcomer
  • *
  • Posts: 36
Debugging CB by itself
« on: July 14, 2008, 11:11:45 pm »
I just have tried to start debugging CB. It seems started but it arises the next messege immediately:
"Cannot find resources...
Code::Blocks was configured to be installed in 'bla-bla'...."

What I need to setup to start my built version without a conflict with an installed version?

I try to debug one of latest SVN revisions under Win XP, mingw, gdb 5.2.1.

Offline Jenna

  • Administrator
  • Lives here!
  • *****
  • Posts: 7255
Re: Debugging CB by itself
« Reply #1 on: July 14, 2008, 11:25:27 pm »
Compile the svn-sources you have downloaded by right-clicking on "CodeBlocks.cbp" in the first "src" subdir and chosing "build".
Do the same with "ContribPlugins.workspace" if you also want to debug one of the plugins, or if you want to use one of them during debugging.

The run "update.bat" from the same directory.

Double-click "codeblocks.exe" from the "<C::B_source-root>\src\output" and open the C::B project file you used for compiling.
If it asks to change file-associations for c++-files you should not change actual associations.

That's it.

If you want to debug one of the contrib-plugins, open the "ContribPlugisn.workspace" and additionally open the "Codeblocks.cbp"-file.
To debug a plugin you have to activate the "Code::Blocks"-project and start debugger. If it asks which target to run, chose "src".

You can (of course) place breakpoints into the plugins-sources.

Offline lexis

  • Multiple posting newcomer
  • *
  • Posts: 36
Re: Debugging CB by itself
« Reply #2 on: July 14, 2008, 11:42:19 pm »
Thanks a lot, it works :)

It will be handly to add these instructions to a wiki for a newbies like me...

Offline TDragon

  • Lives here!
  • ****
  • Posts: 943
    • TDM-GCC
Re: Debugging CB by itself
« Reply #3 on: July 15, 2008, 05:15:25 am »
... gdb 5.2.1.
Make sure you upgrade to GDB 6.3 or later, or you'll run into problems down the road.
https://jmeubank.github.io/tdm-gcc/ - TDM-GCC compiler suite for Windows (GCC 9.2.0 2020-03-08, 32/64-bit, no extra DLLs)

Offline lexis

  • Multiple posting newcomer
  • *
  • Posts: 36
Re: Debugging CB by itself
« Reply #4 on: July 15, 2008, 10:03:24 pm »
Make sure you upgrade to GDB 6.3 or later, or you'll run into problems down the road.
Thanks for the advance.