Makefile 886 B

123456789101112131415161718192021222324252627282930313233343536
  1. SOURCE = torus-three-paths
  2. DELAY = 80
  3. DENSITY = 300
  4. WIDTH = 512
  5. make:
  6. make clean
  7. pdflatex $(SOURCE).tex -output-format=pdf
  8. asy $(SOURCE)-*.asy
  9. asy $(SOURCE)-*.asy
  10. pdflatex $(SOURCE).tex -output-format=pdf
  11. make clean
  12. clean:
  13. rm -rf $(TARGET) *.class *.html *.log *.aux *.data *.gnuplot *.out *.prc *.pre $(SOURCE)-1_0.pdf $(SOURCE)1+0_0.pdf $(SOURCE)-1.tex
  14. gif:
  15. pdfcrop $(SOURCE).pdf
  16. convert -verbose -delay $(DELAY) -loop 0 -density $(DENSITY) $(SOURCE)-crop.pdf $(SOURCE).gif
  17. make clean
  18. png:
  19. make
  20. make svg
  21. inkscape $(SOURCE).svg -w $(WIDTH) --export-png=$(SOURCE).png
  22. transparentGif:
  23. convert $(SOURCE).pdf -transparent white result.gif
  24. make clean
  25. svg:
  26. #inkscape $(SOURCE).pdf --export-plain-svg=$(SOURCE).svg
  27. pdf2svg $(SOURCE).pdf $(SOURCE).svg
  28. # Necessary, as pdf2svg does not always create valid svgs:
  29. inkscape $(SOURCE).svg --export-plain-svg=$(SOURCE).svg