homebrew-core/Formula/mcabber.rb

66 lines
1.9 KiB
Ruby

class Mcabber < Formula
desc "Console Jabber client"
homepage "https://mcabber.com/"
url "https://mcabber.com/files/mcabber-1.0.5.tar.bz2"
sha256 "a0f200817d2b6196fe4d37918ce16f6fed83a3cef861d7165161e8b1cafcad47"
bottle do
sha256 "809dca7d8e2f2ed7071db7d27f36632911b0d0f1d7f1c962b081751122e15048" => :sierra
sha256 "99877d1d1808737d8752c5d72d702cc0119e9a1b35266f146d8c4cf705ca0615" => :el_capitan
sha256 "3a253108087149fcd756b108dace85cb59c85ed662f655b89662a50a206ccaa7" => :yosemite
end
head do
url "https://mcabber.com/hg/", :using => :hg
depends_on "autoconf" => :build
depends_on "automake" => :build
depends_on "libtool" => :build
end
deprecated_option "enable-aspell" => "with-aspell"
deprecated_option "enable-enchant" => "with-enchant"
depends_on "pkg-config" => :build
depends_on "glib"
depends_on "loudmouth"
depends_on "gpgme"
depends_on "libgcrypt"
depends_on "libotr"
depends_on "libidn"
depends_on "aspell" => :optional
depends_on "enchant" => :optional
def install
if build.head?
cd "mcabber"
inreplace "autogen.sh", "libtoolize", "glibtoolize"
system "./autogen.sh"
end
args = ["--disable-debug", "--disable-dependency-tracking",
"--prefix=#{prefix}",
"--enable-otr"]
args << "--enable-aspell" if build.with? "aspell"
args << "--enable-enchant" if build.with? "enchant"
system "./configure", *args
system "make", "install"
pkgshare.install %w[mcabberrc.example contrib]
end
def caveats; <<-EOS.undent
A configuration file is necessary to start mcabber. The template is here:
#{pkgshare}/mcabber/mcabberrc.example
And there is a Getting Started Guide you will need to setup Mcabber:
http://wiki.mcabber.com/index.php/Getting_started
EOS
end
test do
system "#{bin}/mcabber", "-V"
end
end