forked from lotia/homebrew-versions
-
Notifications
You must be signed in to change notification settings - Fork 0
/
berkeley-db4.rb
32 lines (26 loc) · 864 Bytes
/
berkeley-db4.rb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
require 'formula'
class BerkeleyDb4 < Formula
homepage 'http://www.oracle.com/technology/products/berkeley-db/index.html'
url 'http://download.oracle.com/berkeley-db/db-4.8.30.tar.gz'
md5 'f80022099c5742cd179343556179aa8c'
def options
[['--without-java', 'Compile without Java support.']]
end
def install
# BerkeleyDB dislikes parallel builds
ENV.deparallelize
args = ["--disable-debug",
"--prefix=#{prefix}",
"--mandir=#{man}",
"--enable-cxx"]
args << "--enable-java" unless ARGV.include? "--without-java"
# BerkeleyDB requires you to build everything from the build_unix subdirectory
cd 'build_unix' do
system "../dist/configure", *args
system "make install"
# use the standard docs location
doc.parent.mkpath
mv prefix+'docs', doc
end
end
end