How do I add a .jar file to the compilation of .java files
Posted
by
Christopher Schroeder
on Stack Overflow
See other posts from Stack Overflow
or by Christopher Schroeder
Published on 2012-06-11T23:06:15Z
Indexed on
2012/06/12
4:40 UTC
Read the original article
Hit count: 282
My makefile is below
Also, I would appreciate it if you told me how to move my .class files to ../bin/
JFLAGS = -cp
JAR = "RSBot*.jar"
JC = javac
.SUFFIXES: .java .class
.java.class:
$(JC) $(JFLAGS) $(JAR) $*.java
CLASSES = \
src/Banker.java \
src/Eater.java \
src/Fighter.java \
src/grotgui.java \
src/InventTab.java \
src/Looter.java \
src/Potter.java \
src/W8babyGrotworm.java \
src/Walker.java
default: classes
classes: $(CLASSES:.java=.class)
clean:
$(RM) *.class
© Stack Overflow or respective owner