Makefile 914 B

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