Why can't I debug in eclipse C++?

eclipse-CDT won't debug my c++ programs

  • I've installed eclipse from ubuntu repositories and I installed CDT from "install new software." But every time I try to debug a simple program, an error occurs that says 'launching q.cpp debug' encountered a problem "Program file does not exist" Also there is nothing in Run > Debug As. What should I do? When I type commands, the eclipse command corrector (I don't know what it is called) doesn't show me any any commands to help me to choose the correct one.

  • Answer:

    If you are using g++ as your compiler, you should compile your program with the -g -O0 flags, to facilitate debugging.

MustafaJF at Ask Ubuntu Visit the source

Was this solution helpful to you?

Related Q & A:

Just Added Q & A:

Find solution

For every problem there is a solution! Proved by Solucija.

  • Got an issue and looking for advice?

  • Ask Solucija to search every corner of the Web for help.

  • Get workable solutions and helpful tips in a moment.

Just ask Solucija about an issue you face and immediately get a list of ready solutions, answers and tips from other Internet users. We always provide the most suitable and complete answer to your question at the top, along with a few good alternatives below.