Qt Creator 2.6.0 on Linux with Run In Terminal: debugging does not work.



  • Hello,

    I have freshly installed Ubuntu 12.04 and Qt Creator 2.6.0. When I do not use Run In Terminal, debugger runs just fine. If I run under gdb from shell, it also runs just fine.

    If I run with Run In Terminal and any of the terminals xterm -e, konsole --nofork -e, or /usr/bin/gnome-terminal -x
    I get:

    The inferior stopped because it received a signal from the Operating System.
    Signal name :
    SIGSTOP
    Signal meaning :
    Stopped (signal)

    I know that ability to run non-xterm has been added just recently.

    Does someone know the fix?

    Thank you.

    EDIT:
    If I run an application without debugger then xterm, konsole, and gnome-terminal run fine.


  • Moderators

    I am not sure this is related, but you could try to disable ptrace protection. Instructions can be found here: https://wiki.ubuntu.com/SecurityTeam/Roadmap/KernelHardening#ptrace_Protection

    We are jumping through some loops when running in a terminal and because of this the debugged application might not actually be a child of the debugger and thus this sensible security measure might get triggered accidentally. I would expect a error message about the debugger not being allowed to attach in this case, though, so this is most likely off the mark.



  • I always disable ptrace before debugging o.w. I get "ptrace: Operation not permitted." before anything.

    Please post if you think of something else for me to try.



  • Does anybody else develop under Linux?

    Let me say that this error means that using Qt Creator I cannot possibly enter values into my application while debugging!

    XTerm used to run fine under debugger. It's ugly buy it worked, now it does not work. Is this a problem with 2.6 version or it's a problem with Ubuntu 12.04?


  • Moderators

    Can you paste the debugger log somewhere? It contains the complete log of the communication between creator and the debugger, so it is a great help to find issues with the debugger setup.

    Right click in an empty place next to the debugger status message in the bar with all the icons and enable the debugger log there.



  • Code:
    @#include<iostream>
    using namespace std;

    int main()
    {
    char ch[5] = {0};
    cin >> ch;
    cout << ch << endl;
    return 0;
    }
    @
    Link to debug log:
    https://docs.google.com/open?id=0B2MvoiwlQdtoNWpSd1ZqeHRBWE0

    Link to assembler:
    https://docs.google.com/open?id=0B2MvoiwlQdtoVllLZGRIUFdQbnc

    Thank you.

    [Edit: Added @ tags for code formatting -- mlong]



  • Could someone help on this?

    Anyone else is running Qt Creator 2.6 under Linux?


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.