Created
April 17, 2013 14:44
-
-
Save serras/5404872 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'formula' | |
class Libmpc < Formula | |
homepage 'http://multiprecision.org' | |
url 'http://multiprecision.org/mpc/download/mpc-1.0.1.tar.gz' | |
sha1 '8c7e19ad0dd9b3b5cc652273403423d6cf0c5edf' | |
bottle do | |
cellar :any | |
sha1 'c8bbad14fa8314418e07aa7a5cd824452fa6ea1e' => :mountain_lion | |
sha1 '21363b47cdc6085b1c09aead7f63918c69a57bed' => :lion | |
sha1 '2b2fb525a4e87e7a954e70be13dfde1110329859' => :snow_leopard | |
end | |
depends_on 'gmp' | |
depends_on 'mpfr' | |
option '32-bit' | |
def install | |
args = [ | |
"--prefix=#{prefix}", | |
"--disable-dependency-tracking", | |
"--with-gmp=#{Formula.factory('gmp').opt_prefix}", | |
"--with-mpfr=#{Formula.factory('mpfr').opt_prefix}" | |
] | |
if build.build_32_bit? | |
ENV.m32 | |
ENV.append 'ABI', '32' | |
args << "--build=none-apple-darwin" | |
end | |
system "./configure", *args | |
system "make" | |
system "make check" | |
system "make install" | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment