6929ec8c8a
Closes Homebrew/homebrew#19199. Signed-off-by: Adam Vandenberg <flangy@gmail.com>
26 lines
914 B
Ruby
26 lines
914 B
Ruby
require 'formula'
|
|
|
|
class Rtorrent < Formula
|
|
homepage 'http://libtorrent.rakshasa.no/'
|
|
url 'http://libtorrent.rakshasa.no/downloads/rtorrent-0.9.3.tar.gz'
|
|
sha256 '9e93ca41beb1afe74ad7ad8013e0d53ae3586c9b0e97263d722f721535cc7310'
|
|
|
|
depends_on 'pkg-config' => :build
|
|
depends_on 'libsigc++'
|
|
depends_on 'libtorrent'
|
|
depends_on 'xmlrpc-c' => :optional
|
|
|
|
def install
|
|
args = ["--disable-debug", "--disable-dependency-tracking", "--prefix=#{prefix}"]
|
|
args << "--with-xmlrpc-c" if build.with? "xmlrpc-c"
|
|
if MacOS.version == :leopard
|
|
inreplace 'configure' do |s|
|
|
s.gsub! ' pkg_cv_libcurl_LIBS=`$PKG_CONFIG --libs "libcurl >= 7.15.4" 2>/dev/null`',
|
|
' pkg_cv_libcurl_LIBS=`$PKG_CONFIG --libs "libcurl >= 7.15.4" | sed -e "s/-arch [^-]*/-arch $(uname -m) /" 2>/dev/null`'
|
|
end
|
|
end
|
|
system "./configure", *args
|
|
system "make"
|
|
system "make install"
|
|
end
|
|
end
|