98e050bd6c
Replaced the plethora of ternaries we've used all over the place to determine whether x86_64 or i386 is called for.
21 lines
653 B
Ruby
21 lines
653 B
Ruby
require 'formula'
|
|
|
|
class Botan < Formula
|
|
homepage 'http://botan.randombit.net/'
|
|
url 'http://botan.randombit.net/files/Botan-1.10.5.tbz'
|
|
sha1 '998b25d78e139b9c9402919aec4daa1c6118f2fb'
|
|
|
|
option 'enable-debug', 'Enable debug build of Botan'
|
|
|
|
def install
|
|
args = ["--prefix=#{prefix}"]
|
|
args << "--cpu=#{MacOS.preferred_arch}"
|
|
args << "--enable-debug" if build.include? "enable-debug"
|
|
args << "--cc=#{ENV.compiler}"
|
|
|
|
system "./configure.py", *args
|
|
# A hack to force them use our CFLAGS. MACH_OPT is empty in the Makefile
|
|
# but used for each call to cc/ld.
|
|
system "make", "install", "MACH_OPT=#{ENV.cflags}"
|
|
end
|
|
end
|