forked from Homebrew/legacy-homebrew
-
Notifications
You must be signed in to change notification settings - Fork 0
/
mcabber.rb
40 lines (33 loc) · 1.23 KB
/
mcabber.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
33
34
35
36
37
38
39
40
require 'formula'
class Mcabber <Formula
url 'http://mcabber.com/files/mcabber-0.10.1.tar.bz2'
homepage 'http://mcabber.com/'
md5 'fe96beab30f535d5d6270fd1719659b4'
head 'http://mcabber.com/hg/'
depends_on 'pkg-config' => :build
depends_on 'glib'
depends_on 'loudmouth'
depends_on 'gpgme'
depends_on 'libgcrypt'
depends_on 'aspell' => :optional if ARGV.include? '--enable-aspell'
depends_on 'enchant' => :optional if ARGV.include? '--enable-enchant'
depends_on 'libotr' => :optional if ARGV.include? '--enable-otr'
depends_on 'libidn' => :optional
def options
[
["--enable-enchant", "Enable spell checking support via enchant"],
["--enable-aspell", "Enable spell checking support via aspell"],
["--enable-otr", "Enable support for off-the-record messages"]
]
end
def install
args = ["--disable-debug", "--disable-dependency-tracking",
"--prefix=#{prefix}"]
args << "--enable-aspell" if ARGV.include? "--enable-aspell"
args << "--enable-enchant" if ARGV.include? "--enable-enchant"
args << "--enable-otr" if ARGV.include? "--enable-otr"
system "./configure", *args
system "make install"
(share+'mcabber').install %w[mcabberrc.example contrib]
end
end