+
+#########
+### Rules
+
+$(outdir)/%-flat-gray.png: %-flat-gray.png
+ convert -depth 8 -geometry 50x50% $< $@
+
+$(outdir)/%-flat-bw.png: %-flat-bw.png
+ convert -depth 8 -geometry 50x50% $< $@
+
+$(outdir)/%.png: %.png
+ ln -f $< $@
+
+$(outdir)/%.jpg: %.jpg
+ ln -f $< $@
+
+$(outdir)/%.png: %.eps
+ gs -dTextAlphaBits=4 -dGraphicsAlphaBits=4 -q -sOutputFile=$@ -sDEVICE=png16m -dEPSCrop -dNOPAUSE -f $< -c quit
+
+$(outdir)/%.pdf: %.eps
+ gs -dAutoRotatePages=/None -sDEVICE=pdfwrite -dNOPAUSE -dBATCH -sOutputFile=$@ -dEPSCrop -c .setpdfwrite -f $<
+