homebrew-core/Formula/mongo-c.rb
Tyler Brock b546c2894e mongo-c: add extra steps and deps for HEAD
Closes Homebrew/homebrew#37032.

Signed-off-by: Tim D. Smith <git@tim-smith.us>
2015-02-21 11:34:16 -08:00

43 lines
1.1 KiB
Ruby

require "formula"
class MongoC < Formula
homepage "http://docs.mongodb.org/ecosystem/drivers/c/"
url "https://github.com/mongodb/mongo-c-driver/releases/download/1.1.0/mongo-c-driver-1.1.0.tar.gz"
sha1 "9277fb0afcf595838da0d5e4715df1526d53e020"
bottle do
cellar :any
sha1 "a1902585054a645fece9ef6e91a53258f3df0356" => :yosemite
sha1 "53858df7d3bb85e63d070754e2aa8f0e9576266f" => :mavericks
sha1 "b547c663729e6ec4944462c8d305643dd83d452f" => :mountain_lion
end
head do
url "https://github.com/mongodb/mongo-c-driver.git"
depends_on "autoconf" => :build
depends_on "automake" => :build
depends_on "libtool" => :build
end
depends_on "pkg-config" => :build
depends_on "libbson"
depends_on "openssl" => :recommended
def install
# --enable-sasl=no: https://jira.mongodb.org/browse/CDRIVER-447
args = ["--prefix=#{prefix}", "--enable-sasl=no"]
if build.head?
system "./autogen.sh"
end
if build.with?('openssl')
args << "--enable-ssl=yes"
else
args << "--enable-ssl=no"
end
system "./configure", *args
system "make", "install"
end
end