homebrew-core/Formula/flac.rb

32 lines
972 B
Ruby
Raw Normal View History

2009-06-05 11:57:50 +00:00
require 'brewkit'
class Flac2Mp3 <GithubGistFormula
2009-07-07 15:09:44 +00:00
@url='http://gist.github.com/raw/124242/79857936f1d72824be0fb5d2ac845c02322abea0/flac2mp3'
2009-07-31 13:04:49 +00:00
@md5='8351009b64afedfeb7a9e162ccd8d94c'
2009-06-05 11:57:50 +00:00
end
class Flac <Formula
@homepage='http://flac.sourceforge.net'
@url='http://kent.dl.sourceforge.net/sourceforge/flac/flac-1.2.1.tar.gz'
@md5='153c8b15a54da428d1f0fadc756c22c7'
def install
# sadly the asm optimisations won't compile since Leopard, and nobody
# cares or knows how to fix it
# TODO --enable-sse
system "./configure --disable-debug --disable-asm-optimizations --prefix='#{prefix}' --mandir='#{prefix}/share/man'"
2009-07-31 13:04:49 +00:00
ENV['OBJ_FORMAT']='macho'
system "make install"
2009-06-05 11:57:50 +00:00
2009-06-05 12:43:11 +00:00
(doc.parent+"#{@name}-#{@version}").mv doc
2009-06-05 11:57:50 +00:00
Flac2Mp3.new.brew do |flac2mp3|
FileUtils.chmod 0544, flac2mp3.name
FileUtils.cp flac2mp3.name, bin
end
end
def caveats
"The flac2mp3 Ruby script depends on Lame." if `which lame`.empty?
end
end