x264 2197

Upgrade x264 to version 2197, the 2012-06-09 stable tarball.
Add a caveat advising the user to recompile brews that use x264.
Add a conditional when building head that sets `GIT_DIR` and runs
`version.sh` so that folks can easily see the current version.

Because version 2197 was inadvertently used a couple of commits
ago, some folks may have a tarball with this name in their cache
that will fail sha1 check.  Hopefully they will know enough to
delete the version in their cache and attempt the install again.
Compiles well using clang and llvm from XCode-4.3.2 on Lion.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
This commit is contained in:
nibbles 2bits 2012-06-10 00:25:15 -07:00 committed by Adam Vandenberg
parent e3fcac9e1c
commit d278d02a1b

View file

@ -2,9 +2,9 @@ require 'formula'
class X264 < Formula
homepage 'http://www.videolan.org/developers/x264.html'
url 'http://download.videolan.org/pub/videolan/x264/snapshots/x264-snapshot-20120425-2245-stable.tar.bz2'
sha1 '969e015e5df24091b5e62873808e6529a7f2fb7f'
version 'r2189' # use version.sh to find this with brew install -i --HEAD x264
url 'http://download.videolan.org/pub/videolan/x264/snapshots/x264-snapshot-20120609-2245-stable.tar.bz2'
sha1 '9abf3129cf4ebdf4409164a9334f52aad935bdd2'
version 'r2197' # brew install -v --HEAD x264 will display the version.
head 'http://git.videolan.org/git/x264.git', :branch => 'stable'
@ -15,6 +15,10 @@ class X264 < Formula
end
def install
if ARGV.build_head?
ENV['GIT_DIR'] = cached_download/'.git'
system './version.sh'
end
args = ["--prefix=#{prefix}", "--enable-shared"]
args << "--bit-depth=10" if ARGV.include?('--10-bit')
@ -29,4 +33,12 @@ class X264 < Formula
system "make install"
end
def caveats; <<-EOS.undent
Because x264 installs its library with a version number that changes,
any of these that you have installed should be reinstalled each time you
upgrade x264.
avidemux, ffmbc, ffmpeg, gst-plugins-ugly
EOS
end
end