2014-10-17 22:47:19 +00:00
|
|
|
require "formula"
|
2009-09-09 14:11:58 +00:00
|
|
|
|
2014-07-03 04:23:20 +00:00
|
|
|
# GnuTLS has previous, current, and next stable branches, we use current.
|
2014-10-17 22:47:19 +00:00
|
|
|
# From 3.4.0 GnuTLS will be permanently disabling SSLv3. Every brew uses will need a revision with that.
|
|
|
|
# http://nmav.gnutls.org/2014/10/what-about-poodle.html
|
2011-03-10 05:11:03 +00:00
|
|
|
class Gnutls < Formula
|
2014-10-17 22:47:19 +00:00
|
|
|
homepage "http://gnutls.org"
|
2014-11-12 05:24:51 +00:00
|
|
|
url "ftp://ftp.gnutls.org/gcrypt/gnutls/v3.3/gnutls-3.3.10.tar.xz"
|
|
|
|
mirror "http://mirrors.dotsrc.org/gcrypt/gnutls/v3.3/gnutls-3.3.10.tar.xz"
|
|
|
|
sha256 "e27553981d48d9211a7e5e94f6e78c575205202a181c2345a1c8466ebf1d2219"
|
2009-09-09 14:11:58 +00:00
|
|
|
|
2014-02-22 15:39:17 +00:00
|
|
|
bottle do
|
|
|
|
cellar :any
|
2014-11-12 05:38:30 +00:00
|
|
|
sha1 "5d22a5706f229e27b48c3279b8c6139f5e273a0c" => :yosemite
|
|
|
|
sha1 "b6636c0b6a7d85c263b911bf3d75019bde1fb7eb" => :mavericks
|
|
|
|
sha1 "348f799829b8e62ce0544a9caacdf2e2ebb1508e" => :mountain_lion
|
2014-02-22 15:39:17 +00:00
|
|
|
end
|
|
|
|
|
2014-10-17 22:47:19 +00:00
|
|
|
depends_on "pkg-config" => :build
|
|
|
|
depends_on "libtasn1"
|
|
|
|
depends_on "gmp"
|
|
|
|
depends_on "nettle"
|
|
|
|
depends_on "guile" => :optional
|
|
|
|
depends_on "p11-kit" => :optional
|
2014-11-12 05:24:51 +00:00
|
|
|
depends_on "unbound" => :optional
|
2009-09-09 14:11:58 +00:00
|
|
|
|
2012-03-18 20:33:24 +00:00
|
|
|
fails_with :llvm do
|
|
|
|
build 2326
|
|
|
|
cause "Undefined symbols when linking"
|
|
|
|
end
|
2010-12-29 04:53:48 +00:00
|
|
|
|
2011-03-21 21:24:22 +00:00
|
|
|
def install
|
2013-07-28 15:47:43 +00:00
|
|
|
args = %W[
|
|
|
|
--disable-dependency-tracking
|
|
|
|
--disable-static
|
|
|
|
--prefix=#{prefix}
|
2014-04-14 23:33:16 +00:00
|
|
|
--sysconfdir=#{etc}
|
2014-04-14 23:44:57 +00:00
|
|
|
--with-default-trust-store-file=#{etc}/openssl/cert.pem
|
2014-10-17 22:47:19 +00:00
|
|
|
--disable-heartbeat-support
|
2013-07-28 15:47:43 +00:00
|
|
|
]
|
|
|
|
|
2014-10-17 22:47:19 +00:00
|
|
|
if build.with? "guile"
|
|
|
|
args << "--enable-guile"
|
|
|
|
args << "--with-guile-site-dir=no"
|
2013-07-28 15:47:43 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
system "./configure", *args
|
2014-10-17 22:47:19 +00:00
|
|
|
system "make", "install"
|
2011-10-12 01:05:53 +00:00
|
|
|
|
2011-10-12 01:23:04 +00:00
|
|
|
# certtool shadows the OS X certtool utility
|
2014-10-17 22:47:19 +00:00
|
|
|
mv bin+"certtool", bin+"gnutls-certtool"
|
|
|
|
mv man1+"certtool.1", man1+"gnutls-certtool.1"
|
2009-09-09 14:11:58 +00:00
|
|
|
end
|
2014-04-14 23:44:57 +00:00
|
|
|
|
|
|
|
def post_install
|
|
|
|
Formula["openssl"].post_install
|
|
|
|
end
|
2014-08-26 06:54:50 +00:00
|
|
|
|
2014-11-12 05:24:51 +00:00
|
|
|
test do
|
|
|
|
system "#{bin}/gnutls-cli", "--version"
|
|
|
|
end
|
|
|
|
end
|