aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula
diff options
context:
space:
mode:
authorBen Lovett2010-12-29 22:16:42 -0800
committerAdam Vandenberg2010-12-29 22:42:22 -0800
commitea68146eff77a2e96a2d50be8bdabaedbf11d9a9 (patch)
tree44ba036d431be3a636a33ec408928f71a1dd7c83 /Library/Formula
parent161bca48d008cd5e305ef40d5b8f688db6e50438 (diff)
downloadhomebrew-ea68146eff77a2e96a2d50be8bdabaedbf11d9a9.tar.bz2
mtr - option for building without gtk+ support
Diffstat (limited to 'Library/Formula')
-rw-r--r--Library/Formula/mtr.rb12
1 files changed, 11 insertions, 1 deletions
diff --git a/Library/Formula/mtr.rb b/Library/Formula/mtr.rb
index f5be6c43f..dc3248bd8 100644
--- a/Library/Formula/mtr.rb
+++ b/Library/Formula/mtr.rb
@@ -5,10 +5,20 @@ class Mtr <Formula
homepage 'http://www.bitwizard.nl/mtr/'
md5 'fa68528eaec1757f52bacf9fea8c68a9'
+ depends_on 'gtk+' unless ARGV.include? "--no-gtk"
+
+ def options
+ [
+ ['--no-gtk', "Don't build with Gtk+ support"]
+ ]
+ end
+
def install
# We need to add this because nameserver8_compat.h has been removed in Snow Leopard
ENV['LIBS'] = "-lresolv"
- system "./configure", "--prefix=#{prefix}", "--disable-debug", "--disable-dependency-tracking"
+ args = ["--prefix=#{prefix}", "--disable-debug", "--disable-dependency-tracking"]
+ args << "--without-gtk" if ARGV.include? "--no-gtk"
+ system "./configure", *args
system "make install"
end