ALL_DECKS = sbp_mathe_grund1 sbp_mathe_grund2 sbp_mathe_aufb1 sbp_mathe_aufb2 sbp_mathe_aufb3 \ sbp_physik sbp_etechnik etbak_mathe1 etbak_mathe2 etbak_et1 ALL_DOCS = lesezeichen poster_emfelder all: \ $(addprefix output/,$(addsuffix .pdf,$(ALL_DOCS))) \ $(addprefix output/,$(addsuffix .pdf,$(ALL_DECKS))) \ $(addprefix output/,$(addsuffix _a4.pdf,$(ALL_DECKS))) \ $(addprefix output/,$(addsuffix _anki.zip,$(ALL_DECKS))) # 'pdflatex -output-directory output/' has a problem with tikz+gnuplot output/%.pdf: %.tex mkdir -p output cd output && ln -fs ../*.tex ../*.cls . cd output && pdflatex -shell-escape $< output/%_anki.zip: output/%.pdf cd output && bash ../pdf_to_anki.sh $(notdir $(basename $<)) output/%_a4.pdf: output/%.pdf cd output && ( pdfnup --no-landscape --frame true --nup 2x4 --outfile $(notdir $@) $(notdir $<) || \ pdfnup --frame true --nup 2x4 --outfile $(notdir $@) $(notdir $<); ) push: rsync -v -e ssh output/*.pdf output/*_anki.zip index.html clifford@clifford.at:htdocs/clifford/zettelkasten/ clean: cd output && rm -rf *.dvi *.aux *.log *.gnuplot *.table *_anki.txt *_anki.media mrproper: rm -rf output