homebrew-core/Formula/cyassl.rb

88 lines
2.3 KiB
Ruby
Raw Normal View History

class Cyassl < Formula
2014-06-21 20:22:21 +00:00
homepage "http://yassl.com/yaSSL/Products-cyassl.html"
url "https://github.com/cyassl/cyassl/archive/v3.3.0.tar.gz"
sha256 "585ca95b23a44da2d0e042bd0aef95ce770cd541028b76dc45f29ab62ad3ad4a"
2014-06-21 20:22:21 +00:00
head "https://github.com/cyassl/cyassl.git"
2014-09-14 14:20:36 +00:00
bottle do
cellar :any
2014-12-17 00:04:01 +00:00
sha1 "47a068ee29646ef26b3f7e2a62268f62ed73dbec" => :yosemite
sha1 "57f47edc303e4f7f07d893a0724c67e068ca4883" => :mavericks
sha1 "c5de09829f89696a73a8f3818bbf413eae99e5ac" => :mountain_lion
2014-09-14 14:20:36 +00:00
end
option "without-check", "Skip compile-time tests."
2014-06-21 20:22:21 +00:00
depends_on "autoconf" => :build
depends_on "automake" => :build
depends_on "libtool" => :build
def install
args = %W[
--disable-silent-rules
--disable-dependency-tracking
--infodir=#{info}
--mandir=#{man}
--prefix=#{prefix}
--sysconfdir=#{etc}
--disable-bump
--disable-fortress
--disable-sniffer
--disable-webserver
--enable-aesccm
--enable-aesgcm
--enable-blake2
--enable-camellia
--enable-certgen
--enable-certreq
--enable-chacha
--enable-crl
--enable-crl-monitor
--enable-dtls
--enable-ecc
--enable-eccencrypt
--enable-filesystem
--enable-hc128
--enable-hkdf
--enable-inline
--enable-keygen
--enable-ocsp
--enable-opensslextra
--enable-poly1305
--enable-psk
--enable-rabbit
--enable-ripemd
--enable-savesession
--enable-savecert
--enable-sessioncerts
--enable-sha512
--enable-sni
--enable-supportedcurves
]
if MacOS.prefer_64_bit?
2014-06-21 20:22:21 +00:00
args << "--enable-fastmath" << "--enable-fasthugemath"
else
2014-06-21 20:22:21 +00:00
args << "--disable-fastmath" << "--disable-fasthugemath"
end
args << "--enable-aesni" if Hardware::CPU.aes? && !build.bottle?
# 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?
system "./autogen.sh"
system "./configure", *args
system "make"
system "make", "check" if build.with? "check"
system "make", "install"
end
test do
system bin/"cyassl-config", "--cflags", "--libs", "--prefix"
end
end