New formula: ocp (open-cubic-player)
Closes Homebrew/homebrew#8503. Signed-off-by: Misty De Meo <mistydemeo@gmail.com>
This commit is contained in:
parent
fcac1da152
commit
ddbe1d0ffb
1 changed files with 40 additions and 0 deletions
40
Formula/ocp.rb
Normal file
40
Formula/ocp.rb
Normal file
|
@ -0,0 +1,40 @@
|
|||
require "formula"
|
||||
|
||||
class Ocp < Formula
|
||||
url "http://downloads.sourceforge.net/project/opencubicplayer/ocp-0.1.21/ocp-0.1.21.tar.bz2"
|
||||
md5 '558a6eacfadfd9c60c97a6e9c7f83f47'
|
||||
homepage "http://sourceforge.net/p/opencubicplayer/home/"
|
||||
|
||||
depends_on "mad" unless ARGV.include? "--without-mad"
|
||||
depends_on "flac" unless ARGV.include? "--without-flac"
|
||||
depends_on "adplug" if ARGV.include? "--with-adplug"
|
||||
|
||||
def options
|
||||
[
|
||||
["--without-mad", "disable mad mpeg audio support"],
|
||||
["--without-flac", "disable FLAC support"],
|
||||
["--with-adplug", "enable adplug support"],
|
||||
]
|
||||
end
|
||||
|
||||
def install
|
||||
ENV.deparallelize
|
||||
|
||||
args = ["--prefix=#{prefix}",
|
||||
"--without-x11",
|
||||
"--without-sdl",
|
||||
"--without-desktop_file_install"]
|
||||
|
||||
if ARGV.include? "--without-mad"
|
||||
args << "--without-mad"
|
||||
elsif ARGV.include? "--without-flac"
|
||||
args << "--without-flac"
|
||||
elsif ARGV.include? "--with-adplug"
|
||||
args << "--with-adplug"
|
||||
end
|
||||
|
||||
system "./configure", *args
|
||||
system "make"
|
||||
system "make install"
|
||||
end
|
||||
end
|
Loading…
Reference in a new issue