75 lines
2.1 KiB
Ruby
75 lines
2.1 KiB
Ruby
class Ncmpcpp < Formula
|
|
desc "Ncurses-based client for the Music Player Daemon"
|
|
homepage "http://rybczak.net/ncmpcpp/"
|
|
url "http://ncmpcpp.rybczak.net/stable/ncmpcpp-0.7.4.tar.bz2"
|
|
sha256 "d70425f1dfab074a12a206ddd8f37f663bce2bbdc0a20f7ecf290ebe051f1e63"
|
|
|
|
bottle do
|
|
cellar :any
|
|
sha256 "3357ef209a42faa042a113303e67c8099ac5d0c95cd024c21b6f2cffcc1f53a1" => :el_capitan
|
|
sha256 "3e47d92bb80359c937f1609707d6c3c75cbada8cf1528b42b900a14bb2909fde" => :yosemite
|
|
sha256 "c6e1d2e642ee783f7f44c6ed744d4039bcb72c19c60fc615d200fc392aab543b" => :mavericks
|
|
end
|
|
|
|
head do
|
|
url "git://repo.or.cz/ncmpcpp.git"
|
|
|
|
depends_on "autoconf" => :build
|
|
depends_on "automake" => :build
|
|
depends_on "libtool" => :build
|
|
end
|
|
|
|
deprecated_option "outputs" => "with-outputs"
|
|
deprecated_option "visualizer" => "with-visualizer"
|
|
deprecated_option "clock" => "with-clock"
|
|
|
|
option "with-outputs", "Compile with mpd outputs control"
|
|
option "with-visualizer", "Compile with built-in visualizer"
|
|
option "with-clock", "Compile with optional clock tab"
|
|
|
|
depends_on "pkg-config" => :build
|
|
depends_on "libmpdclient"
|
|
depends_on "readline"
|
|
depends_on "fftw" if build.with? "visualizer"
|
|
|
|
if MacOS.version < :mavericks
|
|
depends_on "boost" => "c++11"
|
|
depends_on "taglib" => "c++11"
|
|
else
|
|
depends_on "boost"
|
|
depends_on "taglib"
|
|
end
|
|
|
|
needs :cxx11
|
|
|
|
def install
|
|
ENV.cxx11
|
|
ENV.append "LDFLAGS", "-liconv"
|
|
ENV.append "BOOST_LIB_SUFFIX", "-mt"
|
|
ENV.append "CXXFLAGS", "-D_XOPEN_SOURCE_EXTENDED"
|
|
|
|
args = [
|
|
"--disable-dependency-tracking",
|
|
"--prefix=#{prefix}",
|
|
"--with-taglib",
|
|
"--with-curl",
|
|
"--enable-unicode",
|
|
]
|
|
|
|
args << "--enable-outputs" if build.with? "outputs"
|
|
args << "--enable-visualizer" if build.with? "visualizer"
|
|
args << "--enable-clock" if build.with? "clock"
|
|
|
|
if build.head?
|
|
# Also runs configure
|
|
system "./autogen.sh", *args
|
|
else
|
|
system "./configure", *args
|
|
end
|
|
system "make", "install"
|
|
end
|
|
|
|
test do
|
|
assert_match version.to_s, shell_output("#{bin}/ncmpcpp --version")
|
|
end
|
|
end
|