Phạm Khánh Đoan
New member
How do I run GDB?
Answer
How to Debug C Program using gdb in 6 Simple Steps
Answer
How to Debug C Program using gdb in 6 Simple Steps
- Compile the C program with debugging option -g. Compile your C program with -g option.
- Launch gdb. Launch the C debugger (gdb) as shown below.
- Set up a break point inside C program.
- Execute the C program in gdb debugger.
- Printing the variable values inside gdb debugger.
- Continue, stepping over and in – gdb commands.