aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAdam Vandenberg2012-07-30 13:01:46 -0700
committerAdam Vandenberg2012-08-08 22:01:39 -0700
commited8ab581edb4bd142493335daa3bbb1eaeb9b15a (patch)
treec48da6fad66c9729fea7df9c76246121fcd06b98
parent1f6d0fef66baace0af46fed11ba42ec792172018 (diff)
downloadhomebrew-ed8ab581edb4bd142493335daa3bbb1eaeb9b15a.tar.bz2
zeromq: use options dsl
-rw-r--r--Library/Formula/zeromq.rb14
1 files changed, 5 insertions, 9 deletions
diff --git a/Library/Formula/zeromq.rb b/Library/Formula/zeromq.rb
index 32422a3fe..d70305747 100644
--- a/Library/Formula/zeromq.rb
+++ b/Library/Formula/zeromq.rb
@@ -10,7 +10,7 @@ class Zeromq < Formula
md5 '1b11aae09b19d18276d0717b2ea288f6'
head 'https://github.com/zeromq/libzmq.git'
- if ARGV.build_head?
+ if build.head?
depends_on :automake
depends_on :libtool
end
@@ -20,12 +20,8 @@ class Zeromq < Formula
cause "Segfault while linking"
end
- def options
- [
- ['--with-pgm', 'Build with PGM extension'],
- ['--universal', 'Build as a Universal Intel binary.']
- ]
- end
+ option :universal
+ option 'with-pgm', 'Build with PGM extension'
def build_fat
# make 32-bit
@@ -44,13 +40,13 @@ class Zeromq < Formula
end
def install
- system "./autogen.sh" if ARGV.build_head?
+ system "./autogen.sh" if build.head?
if ARGV.build_universal?
build_fat
else
args = ["--disable-dependency-tracking", "--prefix=#{prefix}"]
- args << "--with-pgm" if ARGV.include? '--with-pgm'
+ args << "--with-pgm" if build.include? 'with-pgm'
system "./configure", *args
end