Permalink
Browse files

New Formula: pngrewrite

Pngrewrite is command-line utility that reduces the unnecessarily large palettes that too many programs write into PNG files. It also optimizes transparency settings, and reduces the bits-per-pixel if possible. Handy for post-processing images before putting them on a web site.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
  • Loading branch information...
1 parent f1e3645 commit 1def79dc29c0622b9a331f6d7d6573defafdc388 @jou jou committed with adamv Jan 14, 2010
Showing with 16 additions and 0 deletions.
  1. +16 −0 Library/Formula/pngrewrite.rb
@@ -0,0 +1,16 @@
+require 'formula'
+
+class Pngrewrite <Formula
+ url 'http://entropymine.com/jason/pngrewrite/pngrewrite-1.3.0.zip'
+ homepage 'http://entropymine.com/jason/pngrewrite/'
+ md5 '37216932d12bf9b47dca1f45724080d6'
+
+ def install
+ ENV.libpng
+
+ system "#{ENV.cc} #{ENV['CFLAGS']} #{ENV['CPPFLAGS']} " +
+ "-o pngrewrite pngrewrite.c " +
+ "#{ENV['LDFLAGS']} -lpng"
+ bin.install 'pngrewrite'
+ end
+end

0 comments on commit 1def79d

Please sign in to comment.