aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorJack Nagel2012-11-03 21:06:54 -0500
committerJack Nagel2012-11-03 21:06:54 -0500
commita8d39c9bb03d80f3125bb2d0cbd6187f0e4125d3 (patch)
tree0df94c3a7b0a90e02f9a1583251660bc43deb1b2 /Library
parent6e29cdc24e7b4a4c6234e3b05be05e854fe8a46e (diff)
downloadhomebrew-a8d39c9bb03d80f3125bb2d0cbd6187f0e4125d3.tar.bz2
Unbreak mongodb formula
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library')
-rw-r--r--Library/Formula/mongodb.rb45
1 files changed, 25 insertions, 20 deletions
diff --git a/Library/Formula/mongodb.rb b/Library/Formula/mongodb.rb
index a100ada94..ce1287970 100644
--- a/Library/Formula/mongodb.rb
+++ b/Library/Formula/mongodb.rb
@@ -1,30 +1,35 @@
require 'formula'
-class Mongodb < Formula
- homepage 'http://www.mongodb.org/'
-
- if Hardware.is_64_bit?
- url 'http://fastdl.mongodb.org/osx/mongodb-osx-x86_64-2.2.1.tgz'
- sha1 '6fc3054cdc7f7e64b12742f7e8f9df256a3253d9'
- version '2.2.1-x86_64'
+class SixtyFourBitRequired < Requirement
+ def satisfied?
+ MacOS.prefer_64_bit?
+ end
- devel do
- url 'http://fastdl.mongodb.org/osx/mongodb-osx-x86_64-2.3.0.tgz'
- sha1 '816ca175bd31e2ec1eb8b61793b1d1e4a247a5da'
- version '2.3.0-x86_64'
- end
- else
- onoe <<-EOS-undent
- === Error! Unable to proceed with installation. ===
- Pre-built binaries for 32-bit OS X systems are no longer available.
+ def fatal?; true end
- It's not recommended, but if you do need to run MongoDB on a 32-bit
- version of OS X you can do so by compiling the server from source.
+ def message; <<-EOS.undent
+ 32-bit MongoDB binaries are no longer available.
- For more info about building MongoDB from source code, please visit:
- http://www.mongodb.org/display/DOCS/Building+for+OS+X
+ If you need to run a 32-bit version of MongoDB, you can
+ compile the server from source:
+ http://www.mongodb.org/display/DOCS/Building+for+OS+X
EOS
end
+end
+
+class Mongodb < Formula
+ homepage 'http://www.mongodb.org/'
+ url 'http://fastdl.mongodb.org/osx/mongodb-osx-x86_64-2.2.1.tgz'
+ sha1 '6fc3054cdc7f7e64b12742f7e8f9df256a3253d9'
+ version '2.2.1-x86_64'
+
+ devel do
+ url 'http://fastdl.mongodb.org/osx/mongodb-osx-x86_64-2.3.0.tgz'
+ sha1 '816ca175bd31e2ec1eb8b61793b1d1e4a247a5da'
+ version '2.3.0-x86_64'
+ end
+
+ depends_on SixtyFourBitRequired.new
def install
# Copy the prebuilt binaries to prefix