Add optional configure flag for Last.fm support in mpd

As of mpd 0.15, mpd provides experimental native support for Last.fm radio.

This commit adds an optional configure flag (--lastfm) to give Homebrew
users a chance to try it out. (I'm using it here with good results.)

See http://mpd.wikia.com/wiki/Last.fm_Radio for more details about how to
use Last.fm with mpd if enabled.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
This commit is contained in:
Peter Aronoff 2010-07-14 11:32:56 -04:00 committed by Adam Vandenberg
parent eb204999b2
commit ef5ee117a1

View file

@ -17,6 +17,10 @@ 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
# make faad.h findable (when brew is used elsewhere than /usr/local/)
ENV.append 'CFLAGS', "-I#{HOMEBREW_PREFIX}/include"
@ -32,6 +36,7 @@ class Mpd <Formula
"--enable-zip",
]
configure_args << "--disable-curl" if MACOS_VERSION <= 10.5
configure_args << "--enable-lastfm" if ARGV.include?("--lastfm")
system "./configure", *configure_args
system "make install"