From d38568db141d1f2ebfe377cf39a80541afe86434 Mon Sep 17 00:00:00 2001 From: Chad Remesch Date: Thu, 1 Sep 2011 22:56:59 -0400 Subject: pngnq: fix compilation on Lion Signed-off-by: Adam Vandenberg --- Library/Formula/pngnq.rb | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) (limited to 'Library/Formula') diff --git a/Library/Formula/pngnq.rb b/Library/Formula/pngnq.rb index e1fb8b7e4..e1640a9b5 100644 --- a/Library/Formula/pngnq.rb +++ b/Library/Formula/pngnq.rb @@ -7,6 +7,14 @@ class Pngnq < Formula depends_on 'pkg-config' => :build + # Fixes compilation on OSX Lion + # png.h on Lion does not, in fact, include zlib.h + # See: http://sourceforge.net/tracker/?func=detail&aid=3353513&group_id=213072&atid=1024252 + # See: http://sourceforge.net/tracker/?func=detail&aid=3402960&group_id=213072&atid=1024252 + def patches + DATA + end + def install ENV.x11 # for libpng system "./configure", "--disable-dependency-tracking", @@ -14,3 +22,18 @@ class Pngnq < Formula system "make install" end end + + +__END__ +diff --git a/src/rwpng.c b/src/rwpng.c +index aaa21fc..5324afe 100644 +--- a/src/rwpng.c ++++ b/src/rwpng.c +@@ -31,6 +31,7 @@ + + #include + #include ++#include + + #include "png.h" /* libpng header; includes zlib.h */ + #include "rwpng.h" /* typedefs, common macros, public prototypes */ -- cgit v1.2.3