blob: 22f64fa55b19a37d3dc3afc2aca47e79684a0e75 [file] [log] [blame] [raw]
JDK7_HOME := /opt/jdk1.7.0_80
JDK7_JAVAC = $(JDK7_HOME)/bin/javac
#JDK8_HOME := /opt/jdk1.8.0_65
#JDK8_JAVAC = $(JDK8_HOME)/bin/javac
JAR = $(JDK7_HOME)/bin/jar
#SPONGE_CLASS_PATH = /opt/minecraft/sponge/spongeapi-7.1.0-shaded.jar
BUKKIT_CLASS_PATH = /opt/minecraft/forge-cauldron-1.7.10-1.1206.01.170-server.jar
BUKKIT_PLUGIN_CLASSES := \
classes/org/rivoreo/minecraft/tsauth/BukkitPlugin.class
default: classes tsauth-bukkit.jar
tsauth-bukkit.jar: $(BUKKIT_PLUGIN_CLASSES) classes/plugin.yml
cd classes && $(JAR) -c $(patsubst classes/%,%,$(subst $$,\$$,$^)) > ../$@
clean:
rm -f tsauth-bukkit.jar $(BUKKIT_PLUGIN_CLASSES) classes/plugin.yml
classes:
mkdir $@
classes/org/rivoreo/minecraft/tsauth/Bukkit%.class: org/rivoreo/minecraft/tsauth/Bukkit%.java
$(JDK7_JAVAC) -classpath $(BUKKIT_CLASS_PATH):$(CLASSPATH) -d classes $<
classes/%.class: %.java
$(JDK7_JAVAC) -d classes $<
classes/%$$*.class: %.java
classes/%.yml: %.yml
cp -p $< $@