thesis stub
[bitonic-mengthesis.git] / Makefile
index 1514e88cf2741abbd5f9c77161b022105733f89e..ad3f550125f36e7e0baefe060566d280df3cd9ed 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,8 +1,22 @@
-SOURCES = $(wildcard *.tex)
-OBJECTS = $(patsubst %.tex, %.pdf, $(SOURCES))
+SOURCEST = $(wildcard *.tex)
+OBJECTST = $(patsubst %.tex, %.pdf, $(SOURCEST))
+SOURCESA = $(wildcard *.lagda)
+OBJECTSA = $(patsubst %.lagda, %.pdf, $(SOURCESA))
+OBJECTS = $(OBJECTST) $(OBJECTSA)
 
 all: $(OBJECTS)
 
+thesis.pdf: thesis.tex thesis.bib agda.sty
+       pdflatex -halt-on-error $< -o $@
+       bibtex thesis
+       pdflatex -halt-on-error $< -o $@
+       pdflatex -halt-on-error $< -o $@
+
+agda.sty: thesis.tex
+
+thesis.tex: thesis.lagda
+       agda --latex --latex-dir . -i . -i ~/src/agda-lib/src/ thesis.lagda
+
 InterimReport.pdf: InterimReport.tex InterimReport.bib InterimReport.agda
        xelatex -halt-on-error $< -o $@
        bibtex InterimReport
@@ -15,6 +29,8 @@ idris-proposal.pdf: idris-proposal.tex
 
 clean: cleanup
        rm -f $(OBJECTS)
+       rm -f thesis.tex agda.sty
 
 cleanup:
-       rm -f *.log *.aux *.nav *.snm *.toc *.vrb *.out *.bbl *.blg
+       rm -f *.log *.aux *.nav *.snm *.toc *.vrb *.out *.bbl *.blg *.agdai
+