I. Description of the Environment
- Eclipse IDE for C + + developers version 4.4.0
- MinGW gcc/g++ version 4.8.1;gdb version 7.6.1
Second, the Operation procedure
1. New Project
2. Compiling the source program
3. Debug settings
Run-->debug Configurations-->debugger, setting debugger targets
4, Start debugging
Third, the description
When you debug a C program under Windows Eclipse, there is no way to use printf and scanf: the console has no output. The reason is that the data that invokes the output of the function is buffered in the output file but is not updated on the console. This bug has not been solved very well so far.
One way is to use the MinGW command-line mode debugging, the condition is difficult-no graphical interface, but can be normal debugging. For more information, refer to Debugging Tools using MinGW under Windows Gdb.exe debugging C programs