# Makefile dissertacao.tex
# Create by Adolfo Guimarães - February, 16 2013
#
#	make all: run pdflatex and bibtex without error messages
#	make spell: apply aspell to all *.tex files
#	make spellfile FILE=[file]: apply speel in a single file
#	make pdf: run pdflatex
#	make bib: run bibtex
#	make witherror: run pdflatex with error messages
#	clean: remove bak and log files

all:
	pdflatex -interaction=batchmode -file-line-error template.tex
	bibtex template.aux
	pdflatex -interaction=batchmode -file-line-error template.tex
	pdflatex -interaction=batchmode -file-line-error template.tex

pdf:
	pdflatex -interaction=batchmode -file-line-error template.tex

witherror:
	pdflatex -halt-on-error template.tex

bib:
	bibtex template.aux

spell:
	aspell -c -l en template.tex --encoding=iso-8859-1

spellfile:
	aspell -c -l en $(FILE) --encoding=iso-8859-1

clean:
	rm -f *.log
	rm -f *.bak
	rm -f *.aux
	rm -f *.out
	rm -f *.bbl