Unable to break target with Cygwin gdb

Sysprogs forums Forums VisualGDB Unable to break target with Cygwin gdb

Viewing 4 posts - 1 through 4 (of 4 total)
  • Author
    Posts
  • #8531
    ralf
    Participant

    Hi,

    I’m trying to debug an embedded system with a running gdb stub. On the host, I’m using a gdb compiled for this target under Cygwin. I’m able to create a connection to the stub. But when trying to interrupt execution, the gdb process terminates and I get the following message:
    “Warning: a process terminated shortly after VisualGDB sent a Ctrl-Break event. Please try switching to Ctrl-C events in VisualGDB project properties.”
    If I switch to the Ctrl-C method, I get the following message:
    “Warning: a process is not responding to the Ctrl-C event sent by VisualGDB. Please try swtiching to Ctrl-Break events in VisualGDB project properties.”

    Using this gdb executable with eclipse seems to work properly.

    Any help is appreciated,
    Ralf

    #8537
    support
    Keymaster

    Hi,

    This is a known issue. MinGW-based and Cygwin-based executables use different mechanisms of sending a Ctrl-C event. VisualGDB actually allows switching it via VisualGDB Project Properties, but the exact location of the setting depends on your project type. Are you using a regular embedded project? Could you attach a screenshot of your Debug Settings page?

    #8541
    ralf
    Participant

    Hi,

    I created a custom project, because my device isn’t supported by VisualGDB. I’m using a TI DSP running TI-RTOS with a GDB stub.

    I turned on the Ctrl-Break event option for Cygwin:
    https://www.hidrive.strato.com/wget/NbiHx9RX

    I also tried different options in the “GDB settings” page, but it didn’t make any difference.

    I just found a workaround for this problem:
    In the “Custom debug steps” page, there is an option to run a custom command for breaking in the running process. I entered the following command:C:\cygwin\bin\pkill.exe –signal SIGINT gdb

    I also had to switch back to the CTRL-C event method, else the gdb would be killed again.

    Ralf

    • This reply was modified 8 years, 4 months ago by ralf.
    #8547
    support
    Keymaster

    Hi,

    It is strange that the gdb does not react to Ctrl-C/Ctrl-Break properly. If there is any reason why the workaround you discovered does not work, you can try clicking “Setup advanced GDBServer settings” on the Debug Settings page and then selecting “Break All sends Ctrl-C to gdbserver”. If you discover further problems, feel free to contact us again.

Viewing 4 posts - 1 through 4 (of 4 total)
  • You must be logged in to reply to this topic.