diff options
| author | Nibbles 2bits | 2012-02-14 01:53:00 -0800 |
|---|---|---|
| committer | Jack Nagel | 2012-02-15 12:19:42 -0600 |
| commit | f97f5a0a9b426a832a4a45fe2b8a6e5996063655 (patch) | |
| tree | 39e0018921ea0653d8f301f19af619dc3f086c98 /Library/Formula | |
| parent | 97c76e2a9a1889dfe2b3f36162d00157b76916de (diff) | |
| download | homebrew-f97f5a0a9b426a832a4a45fe2b8a6e5996063655.tar.bz2 | |
mcabber: fixes for autogen.sh
Define a couple of variables to help --HEAD run autogen.sh and locate
our m4 macros. Adds a Dir.chdir for HEAD, and a depend_on libotr,
otherwise configure will choke once you generate it and run it. Adds a
caveat to inform the user how to setup their .mcabberrc configuration
file. This compiles on Lion and Snow Lep with all five compilers,
either stable or head.
Changes --enable-otr from an option to being the default.
Closes #10174.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library/Formula')
| -rw-r--r-- | Library/Formula/mcabber.rb | 31 |
1 files changed, 23 insertions, 8 deletions
diff --git a/Library/Formula/mcabber.rb b/Library/Formula/mcabber.rb index d413177f9..99126f0a3 100644 --- a/Library/Formula/mcabber.rb +++ b/Library/Formula/mcabber.rb @@ -11,31 +11,46 @@ class Mcabber < Formula 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 + depends_on 'libotr' + depends_on 'libidn' + depends_on 'aspell' if ARGV.include? '--enable-aspell' + depends_on 'enchant' if ARGV.include? '--enable-enchant' 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 - system "./autogen.sh" if ARGV.build_head? + if ARGV.build_head? then + ENV['LIBTOOLIZE'] = '/usr/bin/glibtoolize' + ENV['ACLOCAL'] = "/usr/bin/aclocal -I #{HOMEBREW_PREFIX}/share/aclocal" + Dir.chdir 'mcabber' + inreplace 'autogen.sh', 'libtoolize', '$LIBTOOLIZE' + inreplace 'autogen.sh', 'aclocal', '$ACLOCAL' + system "./autogen.sh" + end + args = ["--disable-debug", "--disable-dependency-tracking", - "--prefix=#{prefix}"] + "--prefix=#{prefix}", "--enable-otr"] 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 + + def caveats + <<-EOS.undent + A configuration file is necessary to start mcabber. The template is here: + #{share}/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 end |
