2009-10-15 08:07:12 +00:00
|
|
|
require 'formula'
|
2009-06-04 18:21:19 +00:00
|
|
|
|
|
|
|
class Mad <Formula
|
2009-10-08 22:43:50 +00:00
|
|
|
homepage 'http://www.underbit.com/products/mad/'
|
|
|
|
url 'http://downloads.sourceforge.net/project/mad/libmad/0.15.1b/libmad-0.15.1b.tar.gz'
|
|
|
|
md5 '1be543bc30c56fb6bea1d7bf6a64e66c'
|
2009-06-04 18:21:19 +00:00
|
|
|
|
2009-10-12 20:45:40 +00:00
|
|
|
def mad_pc
|
|
|
|
return <<-EOS
|
|
|
|
prefix=#{HOMEBREW_PREFIX}
|
|
|
|
exec_prefix=${prefix}
|
|
|
|
libdir=${exec_prefix}/lib
|
|
|
|
includedir=${prefix}/include
|
|
|
|
|
|
|
|
Name: mad
|
|
|
|
Description: MPEG Audio Decoder
|
|
|
|
Version: #{@version}
|
|
|
|
Requires:
|
|
|
|
Conflicts:
|
|
|
|
Libs: -L${libdir} -lmad -lm
|
|
|
|
Cflags: -I${includedir}
|
|
|
|
EOS
|
|
|
|
end
|
|
|
|
|
2009-06-04 18:21:19 +00:00
|
|
|
def install
|
|
|
|
system "./configure --disable-debugging --enable-fpm=intel --prefix='#{prefix}'"
|
|
|
|
system "make install"
|
2009-10-12 20:45:40 +00:00
|
|
|
|
|
|
|
(lib+'pkgconfig'+'mad.pc').write mad_pc
|
2009-06-04 18:21:19 +00:00
|
|
|
end
|
|
|
|
end
|