From 6b8d25f2d21a3c19ecb0809d619999137cb94565 Mon Sep 17 00:00:00 2001 From: Jack Nagel Date: Tue, 4 Sep 2012 23:04:01 -0500 Subject: Clean up MacOS version method usage The MacOS.version? family of methods (other than "leopard?") are poorly defined and lead to confusing code. Replace them in formulae with more explicit comparisons. "MacOS.version" is a special version object that can be compared to numerics, symbols, and strings using the standard Ruby comparison methods. The old methods were moved to compat when the version comparison code was merged, and they must remain there "forever", but they should not be used in new code. Signed-off-by: Jack Nagel --- Library/Formula/ffmpeg.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'Library/Formula/ffmpeg.rb') diff --git a/Library/Formula/ffmpeg.rb b/Library/Formula/ffmpeg.rb index 9470c7975..90bb53590 100644 --- a/Library/Formula/ffmpeg.rb +++ b/Library/Formula/ffmpeg.rb @@ -26,7 +26,7 @@ class Ffmpeg < Formula option 'with-tools', 'Enable additional FFmpeg tools' # manpages won't be built without texi2html - depends_on 'texi2html' => :build if MacOS.mountain_lion? + depends_on 'texi2html' => :build if MacOS.version >= :mountain_lion depends_on 'yasm' => :build depends_on 'x264' unless build.include? 'without-x264' @@ -79,7 +79,7 @@ class Ffmpeg < Formula # For 32-bit compilation under gcc 4.2, see: # http://trac.macports.org/ticket/20938#comment:22 - ENV.append_to_cflags "-mdynamic-no-pic" if MacOS.leopard? or Hardware.is_32_bit? + ENV.append_to_cflags "-mdynamic-no-pic" if MacOS.version == :leopard or Hardware.is_32_bit? system "./configure", *args -- cgit v1.2.3