NOM=ch6 CIBLE=$(NOM).pdf SOURCES=$(wildcard *.tex) DEPOT ?= . WorkDir = `basename $(PWD)` ARCHIVE=$(WorkDir)_BookGPU_`date +"%Y-%m-%d"`.tar.gz $(CIBLE): $(SOURCES) @printf "Compilation du chapitre..." @make -C ../.. @printf "terminée.\n" archive: @printf "Archivage local vers %s ... " "$(ARCHIVE)" @cd ..; tar zcf $(DEPOT)/$(ARCHIVE) $(WorkDir)/Makefile $(WorkDir)/*.tex $(WorkDir)/*.bib $(WorkDir)/figures; cd - > /dev/null @printf "terminé.\n" clean: @printf "Nettoyage du répertoire..." @rm -f *~ *.aux *.log *.toc *.bbl ../../*~ ../../*.aux ../../*.log ../../*.toc ../../*.ind ../../*.bbl @printf "terminé.\n"