blob: ef58f8316f008c84aeb20945192e459c2087ee49 [file] [log] [blame] [raw]
JDK7_HOME := /opt/jdk1.7.0_80
JDK7_JAVAC = $(JDK7_HOME)/bin/javac
JDK7_JAVAC_FLAGS = -source 1.6 -target 1.6
JAR = $(JDK7_HOME)/bin/jar
BUKKIT_CLASS_PATH = /opt/minecraft/cauldron-1.7.10-1.1206.01.175-server.jar
BUKKIT_PLUGIN_CLASSES := \
classes/rivoreo/minecraft/worldmgr/BukkitWorldProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldTimeProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldSeedProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldTypeProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldAutoSaveProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldThunderingProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldSpawnPointProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldMaxHeightProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldForceFreezeBlockProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldForceSnowProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldForceWetProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldDayTimeProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldBorderCenterProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitWorldBorderSizeProperty.class \
classes/rivoreo/minecraft/worldmgr/BukkitPlugin.class \
classes/rivoreo/minecraft/worldmgr/CustomWorldProvider.class \
classes/rivoreo/minecraft/worldmgr/CustomWorldProviderDayTime.class
default: classes worldmgr-bukkit.jar
worldmgr-bukkit.jar: classes/COPYING $(BUKKIT_PLUGIN_CLASSES) classes/plugin.yml
cd classes && $(JAR) -c $(patsubst classes/%,%,$(subst $$,\$$,$^)) > ../$@
clean:
rm -f worldmgr-bukkit.jar classes/COPYING $(subst $$,\$$,$(BUKKIT_PLUGIN_CLASSES)) classes/plugin.yml classes/net/minecraft/world/WorldProvider.class classes/net/minecraft/world/biome/BiomeGenBase.class classes/net/minecraft/world/chunk/Chunk.class
classes:
mkdir $@
classes/rivoreo/minecraft/worldmgr/CustomWorldProvider.class: classes/net/minecraft/world/WorldProvider.class classes/net/minecraft/world/biome/BiomeGenBase.class classes/net/minecraft/world/chunk/Chunk.class
classes/net/minecraft/world/WorldProvider.class: classes/net/minecraft/world/biome/BiomeGenBase.class classes/net/minecraft/world/chunk/Chunk.class
classes/rivoreo/minecraft/worldmgr/Bukkit%.class: rivoreo/minecraft/worldmgr/Bukkit%.java
$(JDK7_JAVAC) $(JDK7_JAVAC_FLAGS) -classpath $(BUKKIT_CLASS_PATH):classes: -d classes $<
classes/%.class: %.java
$(JDK7_JAVAC) $(JDK7_JAVAC_FLAGS) -classpath classes -d classes $<
classes/%.class: stubs/%.java
$(JDK7_JAVAC) $(JDK7_JAVAC_FLAGS) -classpath classes -d classes $<
classes/%$$*.class: %.java
classes/%.yml: %.yml
cp -p $< $@
classes/COPYING: COPYING
cp -p $< $@