From 0203d1dfd9188a09e6dc579c164836812cd38c61 Mon Sep 17 00:00:00 2001 From: Jan Philipp Timme Date: Fri, 24 Oct 2014 14:16:00 +0200 Subject: [PATCH] Erstellen einer Makefile zum Bauen des Games in ein .jar. --- .gitignore | 2 ++ Makefile | 15 +++++++++++++++ 2 files changed, 17 insertions(+) create mode 100644 Makefile diff --git a/.gitignore b/.gitignore index 066ad30..0ac91c0 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,5 @@ .settings .classpath bin +compiled +game.jar diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..707ba97 --- /dev/null +++ b/Makefile @@ -0,0 +1,15 @@ +.PHONY: clean run + +game.jar: clean + mkdir -p compiled + find src/ -type f -name '*.java' -print0 | xargs -0 javac -cp src/ -d compiled/ + cp -r res/* compiled/ + echo 'Main-Class: de.teamteamteam.spacescooter.Main' >compiled/manifest.txt + jar cvfe game.jar 'de.teamteamteam.spacescooter.Main' -C compiled de -C compiled images + +run: game.jar + java -jar game.jar + +clean: + rm -rf compiled + rm -f game.jar