openjpeg 1.5.0

Upgrades openjpeg to version 1.5.0.
Changes the lcms dep to lcms2, which it prefers.
Organizes the cmake command with the sourcedir last.
Builds on Lion and Snow Leopard with all five compilers.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
This commit is contained in:
Nibbles 2bits 2012-02-13 19:40:31 -08:00 committed by Adam Vandenberg
parent 89785eeb74
commit a532628566

View file

@ -2,39 +2,17 @@ require 'formula'
class Openjpeg < Formula
homepage 'http://www.openjpeg.org/'
url 'http://openjpeg.googlecode.com/files/openjpeg_v1_4_sources_r697.tgz'
version '1.4'
md5 '7870bb84e810dec63fcf3b712ebb93db'
url 'http://openjpeg.googlecode.com/files/openjpeg-1.5.0.tar.gz'
sha1 'dce705ae45f137e4698a8cf39d1fbf22bc434fa8'
head 'http://openjpeg.googlecode.com/svn/trunk/'
depends_on 'cmake' => :build
depends_on 'little-cms' => :optional
depends_on 'little-cms2'
depends_on 'libtiff'
def patches
# libpng 1.5 no longer #includes zlib.h, so add it to the relevant file
# see http://code.google.com/p/openjpeg/issues/detail?id=83
DATA unless ARGV.build_head?
end
def install
system "cmake . #{std_cmake_parameters}"
system "cmake #{std_cmake_parameters} ."
system "make install"
end
end
__END__
diff --git a/codec/convert.c b/codec/convert.c
index 25e715b..2d96971 100644
--- a/codec/convert.c
+++ b/codec/convert.c
@@ -48,6 +48,7 @@
#include "../libs/png/png.h"
#else
#include <png.h>
+#include <zlib.h>
#endif /* _WIN32 */
#endif /* HAVE_LIBPNG */