How to setup custom breakpoints in the C program? : I'm working on a project, where I cannot disclose the details of the code. So, the application is all written in C and C++. Since, a particular file which wanted to debug has a lot of dependencies and exports, I need to debug the whole project. How do I set breakpoints in the code itself so that the debugging would stop at that particular point? I'm using Ubuntu 14.04 (since the project is compatible with this environment).

I've tried using

    #include <csignal>

    // Generate an interrupt
    std::raise(SIGINT);

But I keep getting error

    error: ‘raise’ is not a member of ‘std’

Even this also didn't work

    #include <signal.h>
    raise(SIGINT);

Plus the debugging wont stop at that point, so that I could foresee the function at that point. I only want to debug it from console, rather using any IDE.

