homebrew-core/Formula/cmus.rb
Leon Zhang 1cb108bf5c cmus: add -isystem to CFLAGS for non-/usr/local installs
To satisfy configure script to check "mp4v2/mp4v2.h", add -isystem to CFLAGS

Closes Homebrew/homebrew#11513.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2012-04-08 13:34:16 -07:00

33 lines
988 B
Ruby

require 'formula'
class Cmus < Formula
url 'http://downloads.sourceforge.net/cmus/cmus-v2.4.3.tar.bz2'
homepage 'http://cmus.sourceforge.net/'
md5 '75452cf007637214c4ab5444e076114b'
head 'https://git.gitorious.org/cmus/cmus.git', :using => :git
depends_on 'pkg-config' => :build
depends_on 'libao'
depends_on 'mad'
depends_on 'libogg'
depends_on 'libvorbis'
depends_on 'faad2'
depends_on 'flac'
depends_on 'mp4v2'
depends_on 'libcue' if ARGV.build_head?
skip_clean 'bin/cmus'
skip_clean 'bin/cmus-remote'
def install
# We add this to CPPFLAGS and LDFLAGS in ENV, but cmus doesn't
# pick up on that. Adding this patch because I am too lazy to
# send a patch upstream to respect CPPFLAGS - @adamv
unless HOMEBREW_PREFIX.to_s == '/usr/local'
ENV.append 'CFLAGS', "-isystem #{HOMEBREW_PREFIX}/include -L#{HOMEBREW_PREFIX}/lib"
end
system "./configure", "prefix=#{prefix}", "mandir=#{man}"
system "make install"
end
end