FIprojetAgile2022Groupe3B/projetAgile/Makefile

135 lines
4.9 KiB
Makefile
Raw Normal View History

JAVAC_OPT = -implicit:none \
-d build -classpath build -sourcepath src
PACKAGE = fr.iutfbleau.projetAgile
PACKAGE_PATH = fr/iutfbleau/projetAgile
JAR_OPTION = cvfe projetAgile.jar $(PACKAGE).main.Main -C build fr -C res
2022-10-20 11:32:49 +02:00
#BBUT PAR DEFAUT
run: puissance4
java -jar Puissance4.jar
2022-10-13 16:09:07 +02:00
#------- Dossiers ------
View = build/$(PACKAGE_PATH)/View/Pion.class \
build/$(PACKAGE_PATH)/View/Grille.class \
build/$(PACKAGE_PATH)/View/Puissance4Panel.class \
2022-10-19 22:12:11 +02:00
build/$(PACKAGE_PATH)/View/TestGrille.class \
build/$(PACKAGE_PATH)/View/BoutonsMenu.class \
build/$(PACKAGE_PATH)/View/Menu.class
Utils = build/$(PACKAGE_PATH)/Utils/Constants.class \
build/$(PACKAGE_PATH)/Utils/GameStatus.class
Events = build/$(PACKAGE_PATH)/Event/GridChangedListener.class \
build/$(PACKAGE_PATH)/Event/GridEvent.class \
build/$(PACKAGE_PATH)/Event/PlayerEvent.class
Model = build/$(PACKAGE_PATH)/Model/GrilleModel.class
2022-10-13 15:51:42 +02:00
Controller = build/$(PACKAGE_PATH)/Controller/GrilleMouseListener.class \
2022-10-20 09:52:13 +02:00
build/$(PACKAGE_PATH)/Controller/ModelEventListener.class \
2022-10-13 16:09:07 +02:00
#------- Events ------
build/$(PACKAGE_PATH)/Event/PlayerEvent.class : src/$(PACKAGE_PATH)/Event/PlayerEvent.java
javac $(JAVAC_OPT) $<
build/$(PACKAGE_PATH)/Event/GridEvent.class : src/$(PACKAGE_PATH)/Event/GridEvent.java
javac $(JAVAC_OPT) $<
2022-10-13 15:51:42 +02:00
build/$(PACKAGE_PATH)/Event/GridChangedListener.class : src/$(PACKAGE_PATH)/Event/GridChangedListener.java \
build/$(PACKAGE_PATH)/Event/GridEvent.class \
build/$(PACKAGE_PATH)/Event/PlayerEvent.class
javac $(JAVAC_OPT) $<
2022-10-13 15:51:42 +02:00
build/$(PACKAGE_PATH)/Event/AbstractGridInitiater.class : src/$(PACKAGE_PATH)/Event/AbstractGridInitiater.java \
$(Events)
javac $(JAVAC_OPT) $<
2022-10-13 15:51:42 +02:00
2022-10-13 16:09:07 +02:00
#------- Controleur ------
2022-10-20 11:32:49 +02:00
build/$(PACKAGE_PATH)/Controller/ResetGame.class : src/$(PACKAGE_PATH)/Controller/ResetGame.java
2022-10-18 13:52:42 +02:00
javac $(JAVAC_OPT) $<
2022-10-20 09:52:13 +02:00
build/$(PACKAGE_PATH)/Controller/GrilleMouseListener.class : src/$(PACKAGE_PATH)/Controller/GrilleMouseListener.java
javac $(JAVAC_OPT) $<
2022-10-13 13:40:53 +02:00
2022-10-17 18:28:55 +02:00
build/$(PACKAGE_PATH)/Controller/ModelEventListener.class : src/$(PACKAGE_PATH)/Controller/ModelEventListener.java \
build/$(PACKAGE_PATH)/Event/GridChangedListener.class \
build/$(PACKAGE_PATH)/View/Grille.class \
$(Event)
2022-10-17 18:28:55 +02:00
javac $(JAVAC_OPT) $<
2022-10-19 22:12:11 +02:00
build/$(PACKAGE_PATH)/Controller/ObservateurMenuSouris.class : src/$(PACKAGE_PATH)/Controller/ObservateurMenuSouris.java \
build/$(PACKAGE_PATH)/View/BoutonsMenu.class
javac $(JAVAC_OPT) $<
2022-10-20 09:52:13 +02:00
build/$(PACKAGE_PATH)/Puissance4Controller.class : src/$(PACKAGE_PATH)/Controller/Puissance4Controller.java \
build/$(PACKAGE_PATH)/Model/GrilleModel.class \
build/$(PACKAGE_PATH)/View/Grille.class \
build/$(PACKAGE_PATH)/Utils/GameStatus.class \
build/$(PACKAGE_PATH)/View/Puissance4Panel.class \
$(Controller)
javac $(JAVAC_OPT) $<
2022-10-13 16:09:07 +02:00
#------- Modele ------
2022-10-13 15:51:42 +02:00
build/$(PACKAGE_PATH)/Model/GrilleModel.class : src/$(PACKAGE_PATH)/Model/GrilleModel.java \
build/$(PACKAGE_PATH)/Event/AbstractGridInitiater.class \
$(Utils)
javac $(JAVAC_OPT) $<
2022-10-13 13:40:53 +02:00
2022-10-13 16:09:07 +02:00
#------- Utils ------
2022-10-13 13:40:53 +02:00
build/$(PACKAGE_PATH)/Utils/Constants.class : src/$(PACKAGE_PATH)/Utils/Constants.java
javac $(JAVAC_OPT) $<
build/$(PACKAGE_PATH)/Utils/GameStatus.class : src/$(PACKAGE_PATH)/Utils/GameStatus.java
javac $(JAVAC_OPT) $<
2022-10-13 16:09:07 +02:00
#------- Vue ------
2022-10-13 10:43:46 +02:00
build/$(PACKAGE_PATH)/View/Pion.class : src/$(PACKAGE_PATH)/View/Pion.java \
2022-10-13 13:40:53 +02:00
build/$(PACKAGE_PATH)/Utils/Constants.class
javac $(JAVAC_OPT) $<
2022-10-13 10:43:46 +02:00
build/$(PACKAGE_PATH)/View/Grille.class : src/$(PACKAGE_PATH)/View/Grille.java \
build/$(PACKAGE_PATH)/View/Pion.class \
build/$(PACKAGE_PATH)/Utils/Constants.class
javac $(JAVAC_OPT) $<
2022-10-13 13:40:53 +02:00
build/$(PACKAGE_PATH)/View/Puissance4Panel.class : src/$(PACKAGE_PATH)/View/Puissance4Panel.java \
2022-10-13 10:43:46 +02:00
build/$(PACKAGE_PATH)/View/Pion.class \
build/$(PACKAGE_PATH)/View/Grille.class \
2022-10-20 10:31:56 +02:00
build/$(PACKAGE_PATH)/Controller/ResetGame.class \
build/$(PACKAGE_PATH)/View/Menu.class
2022-10-19 22:12:11 +02:00
javac $(JAVAC_OPT) $<
2022-10-20 11:32:49 +02:00
jar cvfe Puissance4.jar $(PACKAGE_PATH).Main -C build fr -C res images
2022-10-19 22:12:11 +02:00
build/$(PACKAGE_PATH)/View/BoutonsMenu.class : src/$(PACKAGE_PATH)/View/BoutonsMenu.java
javac $(JAVAC_OPT) $<
2022-10-20 09:52:13 +02:00
build/$(PACKAGE_PATH)/View/Menu.class : src/$(PACKAGE_PATH)/View/Menu.java \
2022-10-20 10:31:56 +02:00
build/$(PACKAGE_PATH)/Controller/ObservateurMenuSouris.class \
build/$(PACKAGE_PATH)/View/BoutonsMenu.class
2022-10-19 22:12:11 +02:00
javac $(JAVAC_OPT) $<
2022-10-20 09:52:13 +02:00
2022-10-13 13:40:53 +02:00
2022-10-20 09:52:13 +02:00
build/$(PACKAGE_PATH)/Main.class : src/$(PACKAGE_PATH)/Main.java
javac $(JAVAC_OPT) $<
2022-10-13 13:40:53 +02:00
2022-10-20 09:52:13 +02:00
puissance4 : build/$(PACKAGE_PATH)/Main.class \
build/$(PACKAGE_PATH)/Puissance4Controller.class \
$(Model)
2022-10-20 11:32:49 +02:00
doc :
javadoc -d doc src/$(PACKAGE_PATH)/View/*.java src/$(PACKAGE_PATH)/Controller/*.java src/$(PACKAGE_PATH)/Utils/*.java src/$(PACKAGE_PATH)/Model/*.java src/$(PACKAGE_PATH)/Event/*.java
2022-10-17 13:42:19 +02:00
clear :
rm -rf build/*
2022-10-19 22:12:11 +02:00
2022-10-20 11:32:49 +02:00
# BUT FACTICES:
.PHONY: clear doc