makefile compilation problem
Posted
by mistique
on Stack Overflow
See other posts from Stack Overflow
or by mistique
Published on 2010-05-09T18:36:16Z
Indexed on
2010/05/09
18:38 UTC
Read the original article
Hit count: 310
He
I have a problem with a makefile. I have three classes. They do pretty simple stuff. One does an addition on a subtraction, and the last one will instantiate the two and simply print the resulted addition and subtraction.
Now when I create my makefile, I compile my Plus.java and my Minus.java but don't know how to compile the main class because it depends on the previous two. I want to compile and run it from the makefile if it's possible.
I get the above results when I try to run make:
javac -g Plus.class Minus.class javac: invalid flag: Plus.class Usage: javac use -help for a list of possible options make: * [Operation.class] Error 2
I don't know how to procede, please forgive me if my question is to simple but I am new working with these stuff. I've searched many sites but with no answer.
© Stack Overflow or respective owner