user1609974 user1609974 - 1 year ago 231
C++ Question

debugging c++ in codelite

i am setting a break point beside the int x , and setting the ide to the debug mode,but nothing appear in the debugging window when i start debugging ???

should i do something more ?

#include <iostream>

int main()
using std::cin;
using std::cout;
using std::endl;

int x;
cout<<"X = "<<x<<endl<<"enter new x \n X = ";

cout<<endl<<"New X = "<<x<<endl;


Answer Source

There can be several reasons for codelite not stopping:

1) Did you build your project with debugging information enabled? Make sure you select the 'Debug' configuration, this makes sure that -g is passed to gcc / g++

2) Try enabling the debugger log from: settings -> debugger settings -> GNU gdb debugger -> Misc -> enable debugger full log this will produce more information on the interaction between between codelite and gdb - it will also tell you why gdb failed to stop, the log is printed into the 'Debugger' pane, under the 'Output' tab

Remember: codelite is just an interface to gdb, so if codelite did not break, it means that gdb did not instruct it to break...


Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download