aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula/gmp.rb
diff options
context:
space:
mode:
authorAdam Vandenberg2009-09-26 12:11:08 -0700
committerMax Howell2009-09-29 23:33:22 +0100
commit872ed0e8d345c836670382dbd625e293a117d641 (patch)
tree1defc3f0f14ec57054c90238575ad37769946469 /Library/Formula/gmp.rb
parent9883c60dc6aa3416e06d746d9cfec2ce3263389b (diff)
downloadhomebrew-872ed0e8d345c836670382dbd625e293a117d641.tar.bz2
Formula for GMP
GMP is a free library for arbitrary precision arithmetic, operating on signed integers, rational numbers, and floating point numbers. There is no practical limit to the precision except the ones implied by the available memory in the machine GMP runs on. GMP has a rich set of functions, and the functions have a regular interface.
Diffstat (limited to 'Library/Formula/gmp.rb')
-rw-r--r--Library/Formula/gmp.rb20
1 files changed, 20 insertions, 0 deletions
diff --git a/Library/Formula/gmp.rb b/Library/Formula/gmp.rb
new file mode 100644
index 000000000..6603e3b09
--- /dev/null
+++ b/Library/Formula/gmp.rb
@@ -0,0 +1,20 @@
+require 'brewkit'
+
+class Gmp <Formula
+ url 'ftp://ftp.gnu.org/gnu/gmp/gmp-4.3.1.tar.bz2'
+ homepage 'http://gmplib.org/'
+ sha1 'acbd1edc61230b1457e9742136994110e4f381b2'
+
+ def install
+ if MACOS_VERSION == 10.6
+ # On OS X 10.6, some tests fail under LLVM
+ ENV.gcc_4_2
+ end
+
+ system "./configure", "--prefix=#{prefix}", "--disable-debug", "--disable-dependency-tracking"
+ system "make install"
+
+ # Verify that the library compiled correctly.
+ system "make check"
+ end
+end