diff options
| author | Jack Nagel | 2012-02-15 00:33:51 -0600 |
|---|---|---|
| committer | Jack Nagel | 2012-02-15 17:40:20 -0600 |
| commit | 6b5dc590f05190cc2803984911036707a1078688 (patch) | |
| tree | 377bf8f69030133510c54aa0117a703046c82202 /Library/Formula/monotone.rb | |
| parent | f97f5a0a9b426a832a4a45fe2b8a6e5996063655 (diff) | |
| download | homebrew-6b5dc590f05190cc2803984911036707a1078688.tar.bz2 | |
Monotone: use an in-keg botan 1.8
Monotone does not build against botan 1.10.x, so we need to build an
ad-hoc botan 1.8 in the Monotone keg.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library/Formula/monotone.rb')
| -rw-r--r-- | Library/Formula/monotone.rb | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/Library/Formula/monotone.rb b/Library/Formula/monotone.rb index 7dece6913..faa428881 100644 --- a/Library/Formula/monotone.rb +++ b/Library/Formula/monotone.rb @@ -1,5 +1,11 @@ require 'formula' +class Botan18 < Formula + homepage 'http://botan.randombit.net/' + url 'http://files.randombit.net/botan/v1.8/Botan-1.8.13.tbz' + md5 '26674282f146d187ba98c09a137368f5' +end + class Monotone < Formula homepage 'http://monotone.ca/' url 'http://www.monotone.ca/downloads/1.0/monotone-1.0.tar.bz2' @@ -7,7 +13,6 @@ class Monotone < Formula depends_on 'pkg-config' => :build depends_on 'gettext' - depends_on 'botan' depends_on 'libidn' depends_on 'lua' depends_on 'pcre' @@ -15,6 +20,18 @@ class Monotone < Formula fails_with_llvm "linker fails" def install + botan18_prefix = libexec+'botan18' + + Botan18.new.brew do + args = ["--prefix=#{botan18_prefix}"] + args << "--cpu=x86_64" if MacOS.prefer_64_bit? + system "./configure.py", *args + system "make", "CXX=#{ENV.cxx}", "install" + end + + ENV['botan_CFLAGS'] = "-I#{botan18_prefix}/include" + ENV['botan_LIBS'] = "-L#{botan18_prefix}/lib -lbotan" + # Monotone only needs headers from Boost (it's templates all the way down!), so let's avoid # building boost (which takes approximately forever) if it's not already installed. # This is suggested in the Monotone installation instructions. @@ -22,7 +39,7 @@ class Monotone < Formula boost = Formula.factory('boost') unless boost.installed? # Add header location to CPPFLAGS - boost.brew { ENV.append "CXXFLAGS", "-I"+Dir.pwd } + boost.brew { ENV.append "CPPFLAGS", "-I"+Dir.pwd } end system "./configure", "--disable-dependency-tracking", |
