70 lines
2.0 KiB
Ruby
70 lines
2.0 KiB
Ruby
class Ncmpcpp < Formula
|
|
desc "Ncurses-based client for the Music Player Daemon"
|
|
homepage "https://rybczak.net/ncmpcpp/"
|
|
url "https://rybczak.net/ncmpcpp/stable/ncmpcpp-0.8.1.tar.bz2"
|
|
sha256 "4df9570a1db4ba2dc9b759aab88b283c00806fb5d2bce5f5d27a2eb10e6888ff"
|
|
revision 1
|
|
|
|
bottle do
|
|
cellar :any
|
|
sha256 "36c74f63fa67f4dc84efdcd203d56f0918d35c2d6923de359f127b564c99308f" => :high_sierra
|
|
sha256 "343c653c3ec11828500c31c6a5cc5aed9eda846b6cc5f74ddac9ad87c71b97a1" => :sierra
|
|
sha256 "4c05fa5f8db01f70c7392cf6102639abe45a375de0992fe074d3b28f5d37ba47" => :el_capitan
|
|
end
|
|
|
|
head do
|
|
url "https://github.com/arybczak/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 "boost"
|
|
depends_on "libmpdclient"
|
|
depends_on "ncurses"
|
|
depends_on "readline"
|
|
depends_on "taglib"
|
|
depends_on "fftw" if build.with? "visualizer"
|
|
|
|
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"
|
|
|
|
system "./autogen.sh" if build.head?
|
|
system "./configure", *args
|
|
system "make"
|
|
system "make", "install"
|
|
end
|
|
|
|
test do
|
|
ENV.delete("LC_CTYPE")
|
|
assert_match version.to_s, shell_output("#{bin}/ncmpcpp --version")
|
|
end
|
|
end
|