User forums > Help

Breakpoints don't work

(1/3) > >>

C:B_newbie:
Hi guys,

I am trying to use the debugger for the first time, I am new to CB and C++ in general.

When I set a Breakpoint, even at the beginning of my program, it simply gets ignored during runtime.

What I tried:
-global compiler settings --> mark "produce debugging symbols",  unmark "strip all symbols from binary"
-build options: --> same.  however, when clicking on 'release' in the tree there, it is marked conversely
-cleared the path to project from all free spaces / non ASCII symbols
-clean+rebuild

I have version 16.01.

I would appreciate the help :)
Regards!

Commaster:
Are you using "Run"? Don't use Run, use the Debug menu -> Start/Continue.

C:B_newbie:
Yes I know, I am using the red button, not the green one  :-\

BlueHazzard:
Activate the full debugger log and post the log from the debugger tab here.
To activate full debugger logging: Settings -> Debugger -> Enable full debugger logging

C:B_newbie:
Assuming the 'log' is then displayed in the lower part of the GUI where the compiler also gives warnings and so on:

Active debugger config: GDB/CDB debugger:Default
Building to ensure sources are up-to-date
Selecting target:
Debug
Adding source dir: C:\Users\2D_Fluid_I\
Adding source dir: C:\Users\2D_Fluid_I\
Adding file: C:\Users\2D_Fluid_I\bin\Debug\2D_Fluid_I.exe
Changing directory to: C:/Users/2D_Fluid_I/.
Set variable: PATH=.;C:\MinGW\bin;C:\MinGW;C:\ProgramData\Oracle\Java\javapath;C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Windows\System32;C:\Windows;C:\Windows\System32\wbem;C:\Windows\System32\WindowsPowerShell\v1.0;C:\Program Files\ThinkPad\Bluetooth Software;C:\Program Files\Common Files\Lenovo;C:\Program Files\Common Files\Ulead Systems\Mpeg;C:\Program Files\Windows Live\Shared;C:\Program Files\Lenovo\Client Security Solution;C:\Program Files\Intel\WiFi\bin;C:\Program Files\Common Files\Intel\WirelessCommon;C:\Program Files\OpenVPN\bin;C:\Users\René\AppData\Local\Programs\MiKTeX 2.9\miktex\bin;C:\MinGW\msys\bin;C:\MinGW\lib;C:\MinGW\SFML\lib

[debug]Command-line: C:\MinGW\bin\gdb.exe -nx -fullname -quiet  -args C:/Users/2D_Fluid_I/bin/Debug/2D_Fluid_I.exe
[debug]Working dir : C:\Users\2D_Fluid_I

Starting debugger: C:\MinGW\bin\gdb.exe -nx -fullname -quiet  -args C:/Users/2D_Fluid_I/bin/Debug/2D_Fluid_I.exe
done

[debug]> set prompt >>>>>>cb_gdb:

Registered new type: wxString
Registered new type: STL String
Registered new type: STL Vector
Setting breakpoints

[debug]Reading symbols from C:/Users/2D_Fluid_I/bin/Debug/2D_Fluid_I.exe...done.
[debug](gdb) >>>>>>cb_gdb:
[debug]> show version
[debug]GNU gdb (GDB) 7.10.1
[debug]Copyright (C) 2015 Free Software Foundation, Inc.
[debug]License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
[debug]This is free software: you are free to change and redistribute it.
[debug]There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
[debug]and "show warranty" for details.
[debug]This GDB was configured as "i686-w64-mingw32".
[debug]Type "show configuration" for configuration details.
[debug]For bug reporting instructions, please see:
[debug]<http://www.gnu.org/software/gdb/bugs/>.
[debug]Find the GDB manual and other documentation resources online at:
[debug]<http://www.gnu.org/software/gdb/documentation/>.
[debug]For help, type "help".
[debug]Type "apropos word" to search for commands related to "word".
[debug]>>>>>>cb_gdb:
[debug]> set confirm off

Debugger name and version: GNU gdb (GDB) 7.10.1

[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 C:\Program Files\CodeBlocks\share\codeblocks/scripts/stl-views-1.0.3.gdb
[debug]>>>>>>cb_gdb:
[debug]> set follow-fork-mode child
[debug]>>>>>>cb_gdb:
[debug]> directory C:/Users/2D_Fluid_I/
[debug]Source directories searched: C:/Users/2D_Fluid_I;$cdir;$cwd
[debug]>>>>>>cb_gdb:
[debug]> break "C:/Users/2D_Fluid_I/main.cpp:147"
[debug]No source file named C:/Users/2D_Fluid_I/main.cpp.
[debug]Breakpoint 2 ("C:/Users/2D_Fluid_I/main.cpp:147") pending.
[debug]>>>>>>cb_gdb:
[debug]> run
[debug]Starting program: C:\Users\2D_Fluid_I\bin\Debug\2D_Fluid_I.exe

Child process PID: 10052

[debug][New Thread 10052.0x23e4]
[debug][Inferior 1 (process 10052) exited with code 03]
[debug]>>>>>>cb_gdb:

[Inferior 1 (process 10052) exited with code 03]

[debug]> quit

Debugger finished with status 0

Navigation

[0] Message Index

[#] Next page

Go to full version