2009-12-17 19:55:27 +00:00
|
|
|
require 'formula'
|
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class Curl < Formula
|
2009-12-17 19:55:27 +00:00
|
|
|
homepage 'http://curl.haxx.se/'
|
2012-12-01 04:32:14 +00:00
|
|
|
url 'http://curl.haxx.se/download/curl-7.28.1.tar.gz'
|
|
|
|
sha256 '78dce7cfff51ec5725442b92c00550b4e0ca2f45ad242223850a312cd9160509'
|
2009-12-17 19:55:27 +00:00
|
|
|
|
2011-03-16 05:01:31 +00:00
|
|
|
keg_only :provided_by_osx,
|
|
|
|
"The libcurl provided by Leopard is too old for CouchDB to use."
|
2010-11-09 21:20:56 +00:00
|
|
|
|
2012-08-28 00:31:15 +00:00
|
|
|
option 'with-ssh', 'Build with scp and sftp support'
|
|
|
|
option 'with-libmetalink', 'Build with Metalink support'
|
|
|
|
|
2012-04-04 06:28:44 +00:00
|
|
|
depends_on 'pkg-config' => :build
|
2012-08-12 18:09:41 +00:00
|
|
|
depends_on 'libssh2' if build.include? 'with-ssh'
|
2012-08-28 00:31:15 +00:00
|
|
|
depends_on 'libmetalink' if build.include? 'with-libmetalink'
|
2012-04-04 06:28:44 +00:00
|
|
|
|
2009-12-17 19:55:27 +00:00
|
|
|
def install
|
2012-04-04 06:28:44 +00:00
|
|
|
args = %W[
|
2012-08-28 00:31:15 +00:00
|
|
|
--disable-debug
|
|
|
|
--disable-dependency-tracking
|
|
|
|
--prefix=#{prefix}
|
|
|
|
]
|
2012-04-04 06:28:44 +00:00
|
|
|
|
2012-08-12 18:09:41 +00:00
|
|
|
args << "--with-libssh2" if build.include? 'with-ssh'
|
2012-08-28 00:31:15 +00:00
|
|
|
args << "--with-libmetalink" if build.include? 'with-libmetalink'
|
2012-04-04 06:28:44 +00:00
|
|
|
|
|
|
|
system "./configure", *args
|
2009-12-17 19:55:27 +00:00
|
|
|
system "make install"
|
|
|
|
end
|
|
|
|
end
|