Cannot set breakpoints in CDT and eclipse - eclipse-cdt

I'm using Eclipse (galileo) and the current version of CDT on Linux. And I cannot set breakpoints! It runs fun, debugs fine and stops in main...but double clicking in the left margin as I've done years ago with CDT now does not work! grrrrr...

I had the aptana plugin installed to test debugging javascript. I removed it and this symptom went away. I think there is some evil interactions with CDT and Aptana
wcn

Related

Unable to run SDL program in Eclipse but able to do so in Windows Explorer

I have installed and set up SDL and managed to get a tutorial example to build (the tutorial code is from http://zamma.co.uk/setup-sdl2-eclipse-windows/) as a C++ Project in Eclipse.
The problem is that when I try to run the application from Eclipse, the window doesn't appear, or perhaps it gets closed soon after appearing. Eclipse doesn't appear to show any errors.
When I open the folder containing the executable in Windows Explorer and double-click on the application, it works; a window appears with "Hello World" as the title and closes after two seconds.
How can I get the window to appear when I run from Eclipse? Any breakpoints I set are ignored by the debugger.
IDE: Eclipse Luna 4.4.1 OS: Windows 7 64-bit
The program now runs in Eclipse, so the solution may have been to refresh Eclipse and double check Build settings and Run configurations, as well as checking for any OS modifications that may affect the software running on it (thanks to all who replied for the help).

Breakpoints do not work on CDT 8.4.0 for Eclipse Luna for Linux

I had good times debugging Java applications on Eclipse, but recently that I'm working on a C/C++ on Ubuntu 12.04 using Eclipse CDT, it ignores the breakpoints when debugging! I've tried two versions of Eclipse CDT, CDT 8.4.0 for Eclipse Luna, but doesn't work either. Can somebody help with that?
NOTE: I know there are some other similar questions, but I was thinking it is better to ask this question which specifically addresses CDT 8.4.0 for Eclipse Luna.
The eclipse-cdt is shipped only with the required tools for building c/c++ applications. It does not ship with gdb. You need to install that separately
How do I use GDB in Eclipse for C/C++ Debugging?
From link above these are the steps to follow.
1. Go to Help > Install New Software.
2. Add the CDT repository http://download.eclipse.org/tools/cdt/releases/8.4 to the list of repositories.
3. Select the CDT Repository. Now you need to install the CDT plugin along with GDB support from the list of available plugins (Select the CDT Main Features as well as CDT GNU Toolchain Debug support).
I updated the CDT repository path to correspond to your release (Luna).
It also happens for me in ReadHat 64
Seems like if the CDT breakpoints are not suitable for the current debug session, in the breakpoint window, when enabling "Show breakpoints Supported by selected target" all my breakpoints disapears from the list.
In my case, my ELF have debug info and all the breakpoints that I place are in the main ELF.
My debug settings worked fine with the former Eclipse version.
I rolled back to eclipse Juno, and my debug session with same elfs worked out of the box.
Experiencing the same problem here.. I am working around it by manually setting breakpoints after starting debug session. Console -> gdb, then type "break xxxx".
If you're using MinGW gdb, check that C:\MinGW\bin is in your path (set in System Properties). Made all the difference for me.
I once had Skip All Breakpoints accidentally checked, and was wondering what was going on.
I have the same problem with my eclipse Photon, I figured it out by unchecking the
"stop on startup at: main" in Debug Configuration-->Debugger.
I know this in Rikard Söderström's response to you.

Can I use Eclipse CDT to debug a prebuilt C++ executable?

On Linux, I have some C++ programs built with my own makefiles, and I'm looking for some GUI debuggers to debug them at source level.
Previously I use KDbg(2.5.2) on openSUSE(12.3). It works but with some very annoying limitation, e.g., I cannot set a breakpoint when the debugged program is not trapped by Kdbg -- I mean, in order to set a new breakpoint, I have to set it before the program is launched or the program pauses on hitting an already set breakpoint.
Now I try to use Eclipse CDT. I got eclipse-cpp-juno-SR2-linux-gtk.tar.gz but find that I don't know how to load my executable so to start debugging.
I googled with words like 『eclipse debug pre-built C binary』, but few seems to care about this feature.
Can Eclipse CDT really do that? If Eclipse CDT can't, is there any better alternatives to KDbg? Please help.
According to hint from this answer, https://stackoverflow.com/a/248119/151453 , I finally figure out how to do it.
The key point is: In the Eclipse CDT project, create/edit a Launch Configuration so to tell the debugger what executable to load.
Now I have to admit, Eclipse CDT does quite well in C++ code debugging far better than KDbg.
Some screen shot below, on openSUSE 12.3 .
Now we can Run -> Debug (F11)
Debugger automatically pauses the program at main()'s first statement.
The Stand-alone Debugger is an Eclipse application which packages the Eclipse plug-ins from the CDT (C/C++ Development Tools) project into an application that can be started from a command-line script:
bash /path/scripts/cdtdebug.sh -e executable [args]

Eclipse keeps crashing?

I already am awaiting a reply from the Eclipse staff as they are having some bug issue with my account on their website, in the meantime, maybe someone here can shed some light onto this issue.
Basically, I am just starting with C++ and I installed the CDT and MinGW. I followed my professors instructions and got it successfully installed (tested the installation via the command line with a premade file). Anyways I tried to save/compile within Eclipse and it crashed on me, and ever since then it wont even start up now. It loads the interface for Eclipse but within 1-5 seconds it will crash with the same error.
Not sure what is going on, any help appreciated, attached is the image of the error.
Using Eclipse Juno
Try running eclipse with the -clean option: i.e. c:\eclipse\eclipse.exe -clean
Issue is that the Eclipse plugin CDT has an issue with JDK 1.6, I uninstalled 1.6 and downloaded 1.7 and it worked like a charm.

Eclipse CDT Autocomplete not working

I remember from some time ago that Eclipse had auto-complete when you type, and now I can only get it when pressing Ctrl + Space. I already checked and don't have any unresolved dependencies, I can see all the auto-complete choices when pressing Ctrl + Space, but that's not something I like to do every-time... Can someone point me in the direction to get auto-complete back? (Using CDT C++)
At some point recently (not sure but since March 2013?) my Eclipse CDT stopped auto completion. I figured out that at Editor->Content Assist->Advanced checking Parsing-based Proposals lets auto completion work on my machine.
Ubuntu 12.10, Eclipse 4.2.2, CDT 8.1.2
This snapshot shows Task-Focused, which I don't see on my another Eclipse instance. In that case I just checked Parsing-based Proposals and completion still works.
This question is so valid even in 2018 with eclipse photon.
1) Go to Window > Prefrences > C/C++ > Editor > Content Assist > Advanced.
2) Check "Parsing-based proposal(Task-focused)".
3) Bind a key now by pressing "Ctrl + Space".
I had a problem with Eclipse Juno (OSX Java "1.6.0_33") where the autocomplete (and save key binding) wasn't working properly. Googling I found this: Eclipse JUNO doesn't start
Updating my Mercurial Plugin to the latest (1.9.1) fixed both these issues for me.
Very weird.