Makefile
This commit is contained in:
47
makefile
Normal file
47
makefile
Normal file
@@ -0,0 +1,47 @@
|
|||||||
|
# CHAPITRE 1 : BUT FINAL
|
||||||
|
|
||||||
|
but : blocus
|
||||||
|
|
||||||
|
# CHAPITRE 2 : VARIABLES
|
||||||
|
|
||||||
|
OFILES = main.o \
|
||||||
|
grid.o \
|
||||||
|
player.o \
|
||||||
|
game.o \
|
||||||
|
ai.o \
|
||||||
|
menu.o
|
||||||
|
|
||||||
|
CC = gcc
|
||||||
|
|
||||||
|
CFLAGS = -Wall -ansi -pedantic -g -lgraph
|
||||||
|
|
||||||
|
# CHAPITRE 3 : DEPENDANCES (REGLES IMPLICITES)
|
||||||
|
|
||||||
|
main.o : main.h grid.h player.h game.h ai.h menu.h
|
||||||
|
|
||||||
|
grid.o : grid.h player.h struct.h
|
||||||
|
|
||||||
|
player.o : player.h grid.h struct.h
|
||||||
|
|
||||||
|
game.o : game.h grid.h player.h struct.h
|
||||||
|
|
||||||
|
ai.o : ai.h game.h grid.h player.h struct.h
|
||||||
|
|
||||||
|
menu.o : menu.h
|
||||||
|
|
||||||
|
# CHAPITRE 4 : DEPENDANCES AVEC COMMANDES
|
||||||
|
|
||||||
|
blocus : $(OFILES)
|
||||||
|
$(CC) $(CFLAGS) -o blocus $(OFILES)
|
||||||
|
|
||||||
|
# CHAPITRE 5 : NETTOYAGE DES FICHIERS GENERES
|
||||||
|
|
||||||
|
clean :
|
||||||
|
-rm -f $(OFILES) blocus
|
||||||
|
|
||||||
|
# CHAPITRE 6 : BUTS FACTICES
|
||||||
|
|
||||||
|
.PHONY : but clean
|
||||||
|
|
||||||
|
run :
|
||||||
|
./blocus
|
||||||
Reference in New Issue
Block a user