2009-10-15 08:07:12 +00:00
|
|
|
require 'formula'
|
Dependency resolution
Specify dependencies in your formula's deps function. You can return an Array,
String or Hash, eg:
def deps
{ :optional => 'libogg', :required => %w[flac sdl], :recommended => 'cmake' }
end
Note currently the Hash is flattened and qualifications are ignored. If you
only return an Array or String, the qualification is assumed to be :required.
Other packaging systems have problems when it comes to packages requiring a
specific version of a package, or some patches that may not work well with
other software. With Homebrew we have some options:
1. If the formula is vanilla but an older version we can cherry-pick the old
version and install it in the Cellar in parallel, but just not symlink it
into /usr/local while forcing the formula that depends on it to link to
that one and not any other versions of it.
2. If the dependency requires patches then we shouldn't install this for use
by any other tools, (I guess this needs to be decided on a per-situation
basis). It can be installed into the parent formula's prefix, and not
symlinked into /usr/local. In this case the dependency's Formula
derivation should be saved in the parent formula's file (check git or
flac for an example of this).
Both the above can be done currently with hacks, so I'll flesh out a proper
way sometime this week.
2009-09-07 00:06:08 +00:00
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class Libtiff < Formula
|
2010-03-17 16:54:37 +00:00
|
|
|
homepage 'http://www.remotesensing.org/libtiff/'
|
2013-09-23 14:33:32 +00:00
|
|
|
url 'ftp://ftp.remotesensing.org/pub/libtiff/tiff-4.0.3.tar.gz'
|
|
|
|
mirror 'http://download.osgeo.org/libtiff/tiff-4.0.3.tar.gz'
|
2012-10-23 14:11:30 +00:00
|
|
|
sha256 'ea1aebe282319537fb2d4d7805f478dd4e0e05c33d0928baba76a7c963684872'
|
Dependency resolution
Specify dependencies in your formula's deps function. You can return an Array,
String or Hash, eg:
def deps
{ :optional => 'libogg', :required => %w[flac sdl], :recommended => 'cmake' }
end
Note currently the Hash is flattened and qualifications are ignored. If you
only return an Array or String, the qualification is assumed to be :required.
Other packaging systems have problems when it comes to packages requiring a
specific version of a package, or some patches that may not work well with
other software. With Homebrew we have some options:
1. If the formula is vanilla but an older version we can cherry-pick the old
version and install it in the Cellar in parallel, but just not symlink it
into /usr/local while forcing the formula that depends on it to link to
that one and not any other versions of it.
2. If the dependency requires patches then we shouldn't install this for use
by any other tools, (I guess this needs to be decided on a per-situation
basis). It can be installed into the parent formula's prefix, and not
symlinked into /usr/local. In this case the dependency's Formula
derivation should be saved in the parent formula's file (check git or
flac for an example of this).
Both the above can be done currently with hacks, so I'll flesh out a proper
way sometime this week.
2009-09-07 00:06:08 +00:00
|
|
|
|
2014-02-22 12:05:54 +00:00
|
|
|
bottle do
|
|
|
|
cellar :any
|
|
|
|
sha1 "8e2a7f7509689733c0762e01410e247b7ccb98af" => :mavericks
|
|
|
|
sha1 "611e3478187bbcdb5f35970914ee4fe269aeb585" => :mountain_lion
|
|
|
|
sha1 "889158ea146de39f42a489b18af4321004cd54d8" => :lion
|
|
|
|
end
|
|
|
|
|
2012-08-10 05:16:18 +00:00
|
|
|
option :universal
|
2013-11-14 18:42:52 +00:00
|
|
|
option :cxx11
|
2012-06-07 01:35:12 +00:00
|
|
|
|
2013-09-23 14:39:07 +00:00
|
|
|
depends_on 'jpeg'
|
|
|
|
|
Dependency resolution
Specify dependencies in your formula's deps function. You can return an Array,
String or Hash, eg:
def deps
{ :optional => 'libogg', :required => %w[flac sdl], :recommended => 'cmake' }
end
Note currently the Hash is flattened and qualifications are ignored. If you
only return an Array or String, the qualification is assumed to be :required.
Other packaging systems have problems when it comes to packages requiring a
specific version of a package, or some patches that may not work well with
other software. With Homebrew we have some options:
1. If the formula is vanilla but an older version we can cherry-pick the old
version and install it in the Cellar in parallel, but just not symlink it
into /usr/local while forcing the formula that depends on it to link to
that one and not any other versions of it.
2. If the dependency requires patches then we shouldn't install this for use
by any other tools, (I guess this needs to be decided on a per-situation
basis). It can be installed into the parent formula's prefix, and not
symlinked into /usr/local. In this case the dependency's Formula
derivation should be saved in the parent formula's file (check git or
flac for an example of this).
Both the above can be done currently with hacks, so I'll flesh out a proper
way sometime this week.
2009-09-07 00:06:08 +00:00
|
|
|
def install
|
2012-08-10 05:16:18 +00:00
|
|
|
ENV.universal_binary if build.universal?
|
2013-11-14 18:42:52 +00:00
|
|
|
ENV.cxx11 if build.cxx11?
|
2014-02-27 03:12:40 +00:00
|
|
|
jpeg = Formula["jpeg"].opt_prefix
|
2012-02-04 06:14:29 +00:00
|
|
|
system "./configure", "--disable-dependency-tracking",
|
2013-02-01 22:35:26 +00:00
|
|
|
"--prefix=#{prefix}",
|
2012-08-23 16:36:31 +00:00
|
|
|
"--without-x",
|
2013-09-23 14:39:07 +00:00
|
|
|
"--disable-lzma",
|
|
|
|
"--with-jpeg-include-dir=#{jpeg}/include",
|
|
|
|
"--with-jpeg-lib-dir=#{jpeg}/lib"
|
Dependency resolution
Specify dependencies in your formula's deps function. You can return an Array,
String or Hash, eg:
def deps
{ :optional => 'libogg', :required => %w[flac sdl], :recommended => 'cmake' }
end
Note currently the Hash is flattened and qualifications are ignored. If you
only return an Array or String, the qualification is assumed to be :required.
Other packaging systems have problems when it comes to packages requiring a
specific version of a package, or some patches that may not work well with
other software. With Homebrew we have some options:
1. If the formula is vanilla but an older version we can cherry-pick the old
version and install it in the Cellar in parallel, but just not symlink it
into /usr/local while forcing the formula that depends on it to link to
that one and not any other versions of it.
2. If the dependency requires patches then we shouldn't install this for use
by any other tools, (I guess this needs to be decided on a per-situation
basis). It can be installed into the parent formula's prefix, and not
symlinked into /usr/local. In this case the dependency's Formula
derivation should be saved in the parent formula's file (check git or
flac for an example of this).
Both the above can be done currently with hacks, so I'll flesh out a proper
way sometime this week.
2009-09-07 00:06:08 +00:00
|
|
|
system "make install"
|
|
|
|
end
|
|
|
|
end
|