After debugging for some hours, I am unable to debug my project I'm making anymore for the following reasons. (It compiles smoothly without errors nor warnings from the compiler.)
Problem #1:
Error creating process d:\My Documents\Downloads\CandyCrush\CandyCrush\bin\debug\CandyCrush.exe, (error 5).
Solutions:
- I followed the suggestions here and here, so I think it fixed one thing. ('spaces' in environment path)
- Reboot the computer to ensure that the path is made available to all processes properly as suggested here. (Although its somewhat not really related to my problem)
- Change the directory of my IDE along with the compiler.
- Change the directory of the project I'm working on.
- Delete and reinstall MinGW.
- Delete and reinstall Code::Blocks.
And it changes the problem.
(take note that I always try to debug and run after each solutions)
Problem #2:
Starting debugger: D:\cb\CodeBlocks\MingGW\bin\gdb.exe -nx -fullname -quiet -args D:/CandyCrush/CandyCrush/bin/Debug/CandyCrush.exe failed
Solution:
- Configure manually the path of debugger from the IDE (it says it can't find the file but it is there(?)) so it does fixed it.
Aaaand the first problem return again, so I think I really mess up things here.
What could be the fix?
PS. I'm using GNU gdb (GDB) 7.5
Edit
Full (Debug) log
Debugger name and version: GNU gdb (GDB) 7.5
[debug]>>>>>>cb_gdb: [debug]> set width 0 [debug]>>>>>>cb_gdb:
[debug]> set height 0 [debug]>>>>>>cb_gdb: [debug]> set breakpoint
pending on [debug]>>>>>>cb_gdb: [debug]> set print asm-demangle on
[debug]>>>>>>cb_gdb: [debug]> set unwindonsignal on
[debug]>>>>>>cb_gdb: [debug]> set print elements 0
[debug]>>>>>>cb_gdb: [debug]> set new-console on [debug]>>>>>>cb_gdb:
[debug]> set disassembly-flavor att [debug]>>>>>>cb_gdb: [debug]>
catch throw [debug]Catchpoint 1 (throw) [debug]>>>>>>cb_gdb: [debug]>
source D:\cb\CodeBlocks\share\codeblocks/scripts/stl-views-1.0.3.gdb
[debug]>>>>>>cb_gdb: [debug]> directory D:/CandyCrush/CandyCrush/
[debug]Source directories searched:
D:/CandyCrush/CandyCrush;$cdir;$cwd [debug]>>>>>>cb_gdb: [debug]> run
[debug]Error creating process
D:\CandyCrush\CandyCrush\bin\Debug\CandyCrush.exe, (error 5).
[debug]Starting program:
D:\CandyCrush\CandyCrush\bin\Debug\CandyCrush.exe
[debug]>>>>>>cb_gdb:
Error creating process
D:\CandyCrush\CandyCrush\bin\Debug\CandyCrush.exe, (error 5).
[debug]> quit
Debugger finished with status 0