Code::Blocks Forums

User forums => Using Code::Blocks => Topic started by: StarsunYzL on February 15, 2012, 09:31:57 am

Title: [Solved]How to set different debugger for each build target?
Post by: StarsunYzL on February 15, 2012, 09:31:57 am
Hi, everyone.

It seems that debugging a 32bit program with 64bit GDB doesn't work on Windows 7, so I create two debugger settings: one for 32bit, the other for 64bit, and I want to set different debugger for each build target(e.g. 32bit target use 32bit GDB, 64bit target use 64bit GDB), but I can't find any settings for this, I know how to change active debugger manually, but how to do this auto when I switch build targets.

I use CodeBlocks DEBUGGER BRANCH rev7790.

Sorry for my bad english. Thanks! :-*
Title: Re: How to set different debugger for each build target?
Post by: oBFusCATed on February 15, 2012, 10:33:00 am
Steps:
1. Create compiler1
2. Create compiler2
3. Create debugger config1 (Settings -> Debugger->GDB Debugger->Create config)
4. Create debugger config2
5. Change the default debug config in the toolchain executable tab for compiler1 to config1
6. Change the default debug config in the toolchain executable tab for compiler2 to config2
7. Debug->Active debugger's -> Target's default
8. Use compiler1 for target1
9. Use compiler2 for target2
10. Report any problems :)
Title: Re: How to set different debugger for each build target?
Post by: StarsunYzL on February 15, 2012, 11:26:41 am
Thank you so much!! It works perfectly!