x264: add mp4 support

Closes Homebrew/homebrew#27882.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
master
Tsukasa OMOTO 2014-03-26 13:38:00 +00:00 committed by Mike McQuaid
parent 95bcd9731c
commit 12f4819b08
1 changed files with 11 additions and 0 deletions

View File

@ -30,6 +30,12 @@ class X264 < Formula
depends_on 'yasm' => :build
option '10-bit', 'Build a 10-bit x264 (default: 8-bit)'
option "with-mp4=", "Select mp4 output: none (default), l-smash or gpac"
case ARGV.value "with-mp4"
when "l-smash" then depends_on "l-smash"
when "gpac" then depends_on "gpac"
end
def install
args = %W[
@ -38,6 +44,11 @@ class X264 < Formula
--enable-static
--enable-strip
]
if Formula["l-smash"].installed?
args << "--disable-gpac"
elsif Formula["gpac"].installed?
args << "--disable-lsmash"
end
args << "--bit-depth=10" if build.include? '10-bit'
# For running version.sh correctly