aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorDavid Höppner2009-09-19 19:59:58 +0200
committerMax Howell2009-09-29 23:33:22 +0100
commit9883c60dc6aa3416e06d746d9cfec2ce3263389b (patch)
treee9836b46a0112c724a892c807809309d883bdbc6 /Library
parent0fb7b742acbf58f2eee6220fb82747b61fe353f5 (diff)
downloadhomebrew-9883c60dc6aa3416e06d746d9cfec2ce3263389b.tar.bz2
Boehm-Demers-Weiser garbage collector formula
The Boehm-Demers-Weiser conservative garbage collector can be used as a garbage collecting replacement for C malloc or C++ new. It allows you to allocate memory basically as you normally would, without explicitly deallocating memory that is no longer useful. The collector automatically recycles memory when it determines that it can no longer be otherwise accessed. Adam Vandenberg: Update bdw-gc formula for 10.6
Diffstat (limited to 'Library')
-rw-r--r--Library/Formula/bdw-gc.rb21
1 files changed, 21 insertions, 0 deletions
diff --git a/Library/Formula/bdw-gc.rb b/Library/Formula/bdw-gc.rb
new file mode 100644
index 000000000..027e2ac4d
--- /dev/null
+++ b/Library/Formula/bdw-gc.rb
@@ -0,0 +1,21 @@
+require 'brewkit'
+
+class BdwGc <Formula
+ @url='http://www.hpl.hp.com/personal/Hans_Boehm/gc/gc_source/gc-7.1.tar.gz'
+ @homepage='http://www.hpl.hp.com/personal/Hans_Boehm/gc/'
+ @md5='2ff9924c7249ef7f736ecfe6f08f3f9b'
+
+ def install
+ if MACOS_VERSION == 10.6
+ # LLVM gives an unsupported inline asm error
+ ENV.gcc_4_2
+
+ # ucontext has been deprecated in 10.6
+ # use this flag to force the header to compile
+ ENV['CPPFLAGS'] = ENV['CPPFLAGS'] + " -D_XOPEN_SOURCE"
+ end
+
+ system "./configure", "--prefix=#{prefix}", "--disable-debug", "--disable-dependency-tracking"
+ system "make install"
+ end
+end