News:

As usual while waiting for the next release - don't forget to check the nightly builds in the forum.

Main Menu

debug with a bumblebee 3d card (optirun)

Started by unamigo, December 18, 2012, 01:21:54 PM

Previous topic - Next topic

unamigo

Is there a way to debug an OpenGL program in CodeBlocks with a bumblebee card. I found a way to run it from within Codeblocks by adding "optirun" to the terminal launch option in Environment -> General.
But what about being able to debug (break points, trace...) ?

oBFusCATed

Probably you'll have to run it from terminal and then use Debug -> Attach
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Jenna

#2
Did you try it ?

I just did and the opengl test program (or better my gnome-terminal) runs below optirun (at least ps shows it this way).
And it stops at a breakpoint as expected.

The only issue seems to be, that the console does not close after the inferior has finished.

unamigo

Thanks a lot for the tip. Entering the PID every time was a bit of a pain. So I think I found a better way. 
I type : optirun bash from a console. For now on, every program run from that console will use optirun.
So I launch codeblocks from that console, and then I can debug a prog as usual, but this time running on the Nvidia card.