aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorJack Nagel2012-08-13 09:35:48 -0500
committerJack Nagel2012-08-13 09:35:48 -0500
commitc57802ee7d0f7a72612ffce22f672f7ef208967c (patch)
tree7b9d371c000833afb465cce3b5cfaf0594facca7 /Library
parente4c89eef4c46af2c504383ae98c7bcd066a8cb90 (diff)
downloadhomebrew-c57802ee7d0f7a72612ffce22f672f7ef208967c.tar.bz2
wireshark: use options DSL
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library')
-rw-r--r--Library/Formula/wireshark.rb14
1 files changed, 5 insertions, 9 deletions
diff --git a/Library/Formula/wireshark.rb b/Library/Formula/wireshark.rb
index ee83575e5..871cb655c 100644
--- a/Library/Formula/wireshark.rb
+++ b/Library/Formula/wireshark.rb
@@ -11,17 +11,13 @@ class Wireshark < Formula
depends_on 'pcre' => :optional
depends_on 'glib'
- if ARGV.include? '--with-x'
+ if build.include? 'with-x'
depends_on :x11
depends_on 'gtk+'
end
- def options
- [
- ['--with-x', 'Include X11 support'],
- ['--with-python', 'Enable experimental python bindings']
- ]
- end
+ option 'with-x', 'Include X11 support'
+ option 'with-python', 'Enable experimental Python bindings'
def install
args = ["--disable-dependency-tracking", "--prefix=#{prefix}"]
@@ -29,10 +25,10 @@ class Wireshark < Formula
# Optionally enable experimental python bindings; is known to cause
# some runtime issues, e.g.
# "dlsym(0x8fe467fc, py_create_dissector_handle): symbol not found"
- args << '--without-python' unless ARGV.include? '--with-python'
+ args << '--without-python' unless build.include? 'with-python'
# actually just disables the GTK GUI
- args << '--disable-wireshark' unless ARGV.include? '--with-x'
+ args << '--disable-wireshark' unless build.include? 'with-x'
system "./configure", *args
system "make"