User forums > Using Code::Blocks
CB 13.12 debugging fails
eightbits2015:
PC: Ubuntu 15.04 , Processor Intel Core i5-4460 @ 3.20GHZ x 4, Graphics Haswell Desktop,
OS type 64 Bit Disk 113.8
Problem with CodeBlocks (13.12) debug mode:
When using Debug, a simple Hello World C++ code I only get the message:
“warning: GDB: Failed to set controlling terminal: Operation not permitted” displayed in the
terminal window. The code will execute as expected when using the run mode. Also, setting the
gcc version 4.9.2 (Ubuntu 4.9.2-10ubuntu13)
gdb version: GNU gdb (Ubuntu 7.9-1ubuntu1) 7.9
The following is the Debugger log content:
Building to ensure sources are up-to-date
Selecting target:
Debug
Adding source dir: /home/jlo/Programming/c++/SecondTry/
Adding source dir: /home/jlo/Programming/c++/SecondTry/
Adding file: /home/jlo/Programming/c++/SecondTry/bin/Debug/SecondTry
Changing directory to: /home/jlo/Programming/c++/SecondTry/.
Set variable: LD_LIBRARY_PATH=.:
Starting debugger: /usr/bin/gdb -nx -fullname -quiet -args /home/jlo/Programming/c++/SecondTry/bin/Debug/SecondTry
done
Registered new type: wxString
Registered new type: STL String
Registered new type: STL Vector
Setting breakpoints
Debugger name and version: GNU gdb (Ubuntu 7.9-1ubuntu1) 7.9
At /home/jlo/Programming/c++/SecondTry/main.cpp:7
Debugger finished with status 0
I have uninstalled and re-installed CodeBlocks but no change in using the debug mode :-(
oBFusCATed:
Have you set a breakpoint?
Have you read this http://wiki.codeblocks.org/index.php/Debugging_with_Code::Blocks ?
p.s. the warning should be ignored
eightbits2015:
I did set a break point, but it doesn't stop at the break point. I will read the information in the link you provided.
But, I still can't understand “warning: GDB: Failed to set controlling terminal: Operation not permitted” as that seems to be connected with
accessing the Terminal ? I modified the Hello World code to add a couple of lines that use a int and then increment the variable and then using that
line with the variable as the break point. The same issue.
oBFusCATed:
Just ignore it. It doesn't prevent debugging in most cases, especially the simple hello world kind applications.
eightbits2015:
It is hard to ignore, it doesn't stop at the breakpoints. That means it isn't performing a useful function. i am hoping that there is a solution sometime
in the future. I did take a look at Eclispe , but it looks more complex than CodeBlocks and I really want to use it to get up to speed on C++.
You mentioned the simple Hello World examples, is that an issue with the break points not halting?
Navigation
[0] Message Index
[#] Next page
Go to full version