# variable standard pour la compilation CC=gcc # compilateur CFLAGS=-Wall -g -std=c99 # options de compilation LDFLAGS= # options de link LDLIBS=-lm # bibliothèques CPPFLAGS= # options de preprocessing # cible principale (par défaut) all: toto # règle spécifique pour générer l'exécutable toto: toto.o tutu.o tata.o $(CC) $(LDFLAGS) $^ -o $@ $(LDLIBS) # dépendances explicites toto.o: toto.c tata.h tutu.h tata.o: tata.c tata.h tutu.o: tutu.c tutu.h .PHONY: clean clean: rm -f *.o *~ toto