View Single Post
Posts: 726 | Thanked: 345 times | Joined on Apr 2010 @ Sweden
#10
Originally Posted by madmaze View Post
well as it turns out.. its something that is wrong with the examples.. they wont compile.. but i just tried making a new project, in the search of figuring out how the whole thing works, and well.. the new projects works lol

So im all set now..

Thanks for the help.
Even though you've solved the problem, in some sense, perhaps some more detail will help someone else in a similar situation.

make is complaining since a target depends on a cpp-file (which is the way it should be) as below:

main.o : main.cpp

but make can't find the main.cpp file in the current working directory (or the other alternative directories it searches) and then goes looking for a rule that has "main.cpp" as the target. Since there is no such rule, make gives up with the error message you saw.

So, in the general case, the first thing to check is from where make is started and which dependencies there are. If a source file is missing, it's most likely it's a case of mistaken location.
 

The Following User Says Thank You to Joorin For This Useful Post: