Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Eclipse CDT: Skip make/build before Debug/Run

I am debugging a large Makefile-based C project which takes 15 seconds to run "make" even if no changes to the sources are done. That means that whenever I relaunch the program, I need to wait for 15 seconds before I can even start debugging.

The project was imported through "Import as existing project with Makefile" and I am using gdb for debugger.

I want that when I relaunch, it runs the executable which was build last. How to disable this extra step of building (i.e. running "make") before each launch/debug?

(In the rare case of actually changing the source, I am willing to do a manual build / make)

like image 870
eold Avatar asked Mar 14 '12 16:03

eold


People also ask

What are the shortcut keys for debugging in eclipse?

Select Debug As → Java Application or use the shortcut Alt + Shift + D, J instead. Either actions mentioned above creates a new Debug Launch Configuration and uses it to start the Java application.


3 Answers

Project - Disable Autobuild option does not always means autobuild is off. For example "Makegood" test automation plugin will trigger autobuild when Preferences - Run/Debug - launching - (General opt) Build before launch is ON. So turn it off if manual build needed.

like image 60
Rix Beck Avatar answered Oct 07 '22 10:10

Rix Beck


On the main tab of the debug configuration there is a radio button "Disable auto build"

like image 33
SuperJames Avatar answered Oct 07 '22 11:10

SuperJames


In current Eclipse builds like Oxygen.3 the option to disable automatic builds has been moved to Preferences -> Run/Debug -> Launching, and here "Build (if required) before launching" under the General Options. There doesn't seem to be a differentiation anymore between doing this for debug only, appears to apply to both regular and debug runs.

like image 5
krschn Avatar answered Oct 07 '22 11:10

krschn