#!/usr/bin/make

all: $(patsubst %.tex,%.svg,$(wildcard *.tex)) $(patsubst %.tex,%.png,$(wildcard *.tex)) 

%.png: %.pdf
	convert -density 300 -transparent white $< $@

%.svg: %.pdf
	/usr/bin/inkscape $< --export-plain-svg=$@

%.pdf: %.tex 
	latexmk -f -pdf $<

clean: 
	latexmk -C *.tex
	rm -f *.tmp
	rm -f vc
	rm *.svg

viewpdf: all
	evince *.pdf

vc:
	vc-git

pdf: all

.PHONY: clean all
