From c8d0d77b5aef41b5d46357621bcb7eebe715e596 Mon Sep 17 00:00:00 2001 From: Adam Vandenberg Date: Sun, 26 Aug 2012 19:34:55 -0700 Subject: mpd: use new dsl --- Library/Formula/mpd.rb | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'Library/Formula') diff --git a/Library/Formula/mpd.rb b/Library/Formula/mpd.rb index fe61998cf..d347376d3 100644 --- a/Library/Formula/mpd.rb +++ b/Library/Formula/mpd.rb @@ -7,6 +7,8 @@ class Mpd < Formula head "git://git.musicpd.org/master/mpd.git" + option "lastfm", "Compile with experimental support for Last.fm radio" + depends_on 'pkg-config' => :build depends_on 'glib' depends_on 'libid3tag' @@ -20,12 +22,8 @@ class Mpd < Formula depends_on 'libmms' => :optional depends_on 'libzzip' => :optional - def options - [["--lastfm", "Compile with experimental support for Last.fm radio"]] - end - def install - system "./autogen.sh" if ARGV.build_head? + system "./autogen.sh" if build.head? # make faad.h findable (when brew is used elsewhere than /usr/local/) ENV.append 'CFLAGS', "-I#{HOMEBREW_PREFIX}/include" @@ -39,7 +37,7 @@ class Mpd < Formula "--enable-zip", "--enable-lame-encoder"] args << "--disable-curl" if MacOS.leopard? - args << "--enable-lastfm" if ARGV.include?("--lastfm") + args << "--enable-lastfm" if build.include?("lastfm") system "./configure", *args system "make install" -- cgit v1.2.3