aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula
diff options
context:
space:
mode:
authorDaniel Holtmann-Rice2011-08-11 11:24:19 -0400
committerAdam Vandenberg2011-08-13 10:39:34 -0700
commit00ea9f46f0605f39d2eecce71d7f70f376526924 (patch)
tree5125d2881243177f9c9a49bd2dd29959b74a2c4b /Library/Formula
parent40b889c53d4407dcef5012331edad1dd8d508a36 (diff)
downloadhomebrew-00ea9f46f0605f39d2eecce71d7f70f376526924.tar.bz2
libplot: make use of libpng 1.5 compatible
Lion now includes libpng 1.5, which causes a "dereferencing pointer to incomplete type" error when png_ptr->jmpbuf is accessed directly. Adding an inreplace to change occurences of 'png_ptr->jmpbuf' to 'png_jmpbuf (png_ptr)' in the file libplot/z_write.c fixes the build on Lion, and should have no effect on Snow Leopard since the png_jmpbuf function has been present for several versions. Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library/Formula')
-rw-r--r--Library/Formula/plotutils.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/Library/Formula/plotutils.rb b/Library/Formula/plotutils.rb
index d1c11c4df..57b7b2127 100644
--- a/Library/Formula/plotutils.rb
+++ b/Library/Formula/plotutils.rb
@@ -7,6 +7,10 @@ class Plotutils < Formula
def install
ENV.x11 # enable libpng support
+
+ # Fix usage of libpng to be 1.5 compatible
+ inreplace 'libplot/z_write.c', 'png_ptr->jmpbuf', 'png_jmpbuf (png_ptr)'
+
system "./configure", "--disable-debug", "--disable-dependency-tracking",
"--prefix=#{prefix}",
"--enable-libplotter"