Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Eclipse CDT: no rule to make target all

My Eclipse CDT keeps complaining "make: *** no rule to make target all" when I am trying to compile the piece of code below:

#include <iostream> using namespace std;  int main() {   cout << "Hello World!!!" << endl; // prints Hello World!!!   return 0; } 

Anyone knows how to solve this? I have read the post with the similar title: make: *** No rule to make target `all'. Stop. Eclipse error But none of those answers help...

Thanks a lot!

like image 954
Mark Z. Avatar asked Sep 24 '12 23:09

Mark Z.


People also ask

What is meant by No rule to make target?

No rule to make target generally means simply that you have a compiler version that does not match the original compiler used in the project. You only need to go to the project properties and change the compiler to use the one you installed.

What is CDT for Eclipse?

The C/C++ Development Toolkit (CDT) is a set of Eclipse plug-ins that provide C and C++ extensions to the Eclipse workbench. For more information about Eclipse, see Workbench User Guide > Concepts > Workbench. The CDT provides a C/C++ IDE that simplifies many of the same tools that you can use from the command line.


1 Answers

You need to change your project settings so that Eclipse-CDT manages your Makefiles for you.

  1. Select Project->Properties from the menu bar.
  2. Click C/C++ Build on the left in the dialog that comes up.
  3. Under the Builder Settings tab on the right, select "Generate Makefiles automatically" under the Makefile generation section.
  4. Hit OK and build again.
like image 104
ScoPi Avatar answered Sep 22 '22 18:09

ScoPi