diff options
| author | nibbles 2bits | 2012-05-12 10:02:35 -0700 |
|---|---|---|
| committer | Jack Nagel | 2012-05-13 13:37:06 -0500 |
| commit | 05abb1e26fc7a33f491942cc19edebc7145f0e80 (patch) | |
| tree | 08bfba5f2c3cd7b19af9171b5665d49772bf68df /Library/Formula/avidemux.rb | |
| parent | 55107b6af6f228b27e78c8e7b9fe78929da95432 (diff) | |
| download | homebrew-05abb1e26fc7a33f491942cc19edebc7145f0e80.tar.bz2 | |
avidemux: fix failing inreplace
The two inreplaces that add an RPATH to the x264 and xvid dylibs
are not meant to run unless the Qt gui is built. The conditional
that stops them from running was not coded correctly. This commit
changes the conditional to only run the inreplaces if Qt4 is
installed using `linked_keg.exist?`.
Fixes an issue reported in #12051
Closes #12213.
Signed-off-by: Jack Nagel <jacknagel@gmail.com>
Diffstat (limited to 'Library/Formula/avidemux.rb')
| -rw-r--r-- | Library/Formula/avidemux.rb | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/Library/Formula/avidemux.rb b/Library/Formula/avidemux.rb index b71d7a3d0..a8f8e8e52 100644 --- a/Library/Formula/avidemux.rb +++ b/Library/Formula/avidemux.rb @@ -139,15 +139,13 @@ class Avidemux < Formula system "make" # Two dylibs that are only built as part of the Qt gui need an RPATH - # set on their internal deps. Check if they exist before patching them. - # A patch to introduce RPATH use upstream is being fashioned. - fxv = 'ADM_videoEncoder/ADM_vidEnc_xvid/qt4/cmake_install.cmake' - fx2 = 'ADM_videoEncoder/ADM_vidEnc_x264/qt4/cmake_install.cmake' - if (File.exists? fxv and File.exists? fx2) then - inreplace fxv, + # set on their internal deps. Check if Qt4 exists before patching them, + # otherwise the inreplaces will fail. + if Formula.factory('qt').linked_keg.exist? + inreplace 'ADM_videoEncoder/ADM_vidEnc_xvid/qt4/cmake_install.cmake', '"libADM_vidEnc_xvid.dylib"', '"${CMAKE_INSTALL_PREFIX}/lib/ADM_plugins/videoEncoder/libADM_vidEnc_xvid.dylib"' - inreplace fx2, + inreplace 'ADM_videoEncoder/ADM_vidEnc_x264/qt4/cmake_install.cmake', '"libADM_vidEnc_x264.dylib"', '"${CMAKE_INSTALL_PREFIX}/lib/ADM_plugins/videoEncoder/libADM_vidEnc_x264.dylib"' end |
