2013-08-05 09:46:31 +00:00
|
|
|
require 'formula'
|
|
|
|
|
|
|
|
class Mkvtomp4 < Formula
|
2014-01-11 22:48:41 +00:00
|
|
|
homepage 'https://github.com/gavinbeatty/mkvtomp4/'
|
|
|
|
url 'https://github.com/gavinbeatty/mkvtomp4/archive/mkvtomp4-v1.3.tar.gz'
|
|
|
|
sha1 'eab345f40a2d6f30847300f8e2880354e08356d2'
|
2013-08-05 09:46:31 +00:00
|
|
|
|
|
|
|
depends_on 'gpac'
|
2014-01-11 22:48:41 +00:00
|
|
|
depends_on 'ffmpeg' => :recommended
|
2013-08-05 09:46:31 +00:00
|
|
|
depends_on 'mkvtoolnix'
|
2014-05-01 20:08:39 +00:00
|
|
|
depends_on :python if MacOS.version <= :snow_leopard
|
2013-08-05 09:46:31 +00:00
|
|
|
|
|
|
|
def install
|
2014-05-01 20:08:39 +00:00
|
|
|
ENV["PYTHONPATH"] = lib+"python2.7/site-packages"
|
2014-01-12 15:49:45 +00:00
|
|
|
ENV.prepend_create_path 'PYTHONPATH', lib+'python2.7/site-packages'
|
|
|
|
|
2013-08-05 09:46:31 +00:00
|
|
|
system "make"
|
2014-01-11 22:48:41 +00:00
|
|
|
system "python", "setup.py", "install", "--prefix=#{prefix}"
|
2014-01-12 15:49:45 +00:00
|
|
|
|
2014-05-01 20:08:39 +00:00
|
|
|
bin.install "mkvtomp4.py" => "mkvtomp4"
|
2014-01-12 15:49:45 +00:00
|
|
|
bin.env_script_all_files(libexec+'bin', :PYTHONPATH => ENV['PYTHONPATH'])
|
2014-01-11 22:48:41 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
test do
|
|
|
|
system "#{bin}/mkvtomp4", "--help"
|
2013-08-05 09:46:31 +00:00
|
|
|
end
|
|
|
|
end
|