2014-06-21 20:22:21 +00:00
|
|
|
require "formula"
|
2012-12-07 20:10:16 +00:00
|
|
|
|
|
|
|
class Cyassl < Formula
|
2014-06-21 20:22:21 +00:00
|
|
|
homepage "http://yassl.com/yaSSL/Products-cyassl.html"
|
2014-07-21 02:23:53 +00:00
|
|
|
url "https://github.com/cyassl/cyassl/archive/v3.1.0.tar.gz"
|
|
|
|
sha256 "8ece90d145255e6be5934829d86497d2425e2220d9a622d3aa08e5d965fa8d9a"
|
2012-12-07 20:10:16 +00:00
|
|
|
|
2014-06-21 20:22:21 +00:00
|
|
|
head "https://github.com/cyassl/cyassl.git"
|
2012-12-07 20:10:16 +00:00
|
|
|
|
2014-06-21 20:22:21 +00:00
|
|
|
depends_on "autoconf" => :build
|
|
|
|
depends_on "automake" => :build
|
|
|
|
depends_on "libtool" => :build
|
2012-12-07 20:10:16 +00:00
|
|
|
|
|
|
|
def install
|
2013-02-08 17:19:57 +00:00
|
|
|
args = %W[--infodir=#{info}
|
|
|
|
--mandir=#{man}
|
|
|
|
--prefix=#{prefix}
|
2013-06-21 14:51:04 +00:00
|
|
|
--disable-bump
|
|
|
|
--disable-fortress
|
|
|
|
--disable-ntru
|
|
|
|
--disable-sniffer
|
|
|
|
--disable-webserver
|
2013-02-08 17:19:57 +00:00
|
|
|
--enable-aesccm
|
2012-12-07 20:10:16 +00:00
|
|
|
--enable-aesgcm
|
2013-06-21 14:51:04 +00:00
|
|
|
--enable-blake2
|
2013-02-08 17:19:57 +00:00
|
|
|
--enable-camellia
|
2012-12-07 20:10:16 +00:00
|
|
|
--enable-certgen
|
|
|
|
--enable-crl
|
|
|
|
--enable-crl-monitor
|
2013-02-08 17:19:57 +00:00
|
|
|
--enable-dtls
|
2013-06-21 14:51:04 +00:00
|
|
|
--enable-ecc
|
|
|
|
--enable-filesystem
|
2012-12-07 20:10:16 +00:00
|
|
|
--enable-hc128
|
2013-06-21 14:51:04 +00:00
|
|
|
--enable-inline
|
2012-12-07 20:10:16 +00:00
|
|
|
--enable-keygen
|
2013-06-21 14:51:04 +00:00
|
|
|
--enable-md4
|
2012-12-07 20:10:16 +00:00
|
|
|
--enable-ocsp
|
2013-05-01 03:58:28 +00:00
|
|
|
--enable-opensslextra
|
2013-02-08 17:19:57 +00:00
|
|
|
--enable-psk
|
|
|
|
--enable-rabbit
|
2012-12-07 20:10:16 +00:00
|
|
|
--enable-ripemd
|
|
|
|
--enable-sha512
|
2013-06-21 14:51:04 +00:00
|
|
|
--enable-sni
|
2012-12-07 20:10:16 +00:00
|
|
|
]
|
|
|
|
|
|
|
|
if MacOS.prefer_64_bit?
|
2014-06-21 20:22:21 +00:00
|
|
|
args << "--enable-fastmath" << "--enable-fasthugemath"
|
2012-12-07 20:10:16 +00:00
|
|
|
else
|
2014-06-21 20:22:21 +00:00
|
|
|
args << "--disable-fastmath" << "--disable-fasthugemath"
|
2012-12-07 20:10:16 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
# Extra flag is stated as a needed for the Mac platform.
|
|
|
|
# http://yassl.com/yaSSL/Docs-cyassl-manual-2-building-cyassl.html
|
|
|
|
# Also, only applies if fastmath is enabled.
|
2014-06-21 20:22:21 +00:00
|
|
|
ENV.append_to_cflags "-mdynamic-no-pic" if MacOS.prefer_64_bit?
|
2012-12-07 20:10:16 +00:00
|
|
|
|
2013-11-07 19:50:08 +00:00
|
|
|
system "./autogen.sh"
|
2012-12-07 20:10:16 +00:00
|
|
|
system "./configure", *args
|
|
|
|
system "make"
|
|
|
|
system "make install"
|
|
|
|
end
|
|
|
|
end
|