aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Formula
diff options
context:
space:
mode:
authorsamueljohn2012-01-26 14:11:29 +0100
committerCharlie Sharpsteen2012-02-04 22:37:40 -0800
commit6d0c16e6338e6604c6fd2d362f32b3d68703cc15 (patch)
treeaa19694273cf8fac40e2873f6f65d9a561adfa5f /Library/Formula
parentb769471577cbad4f2c8d5b3153be20482c27e4df (diff)
downloadhomebrew-6d0c16e6338e6604c6fd2d362f32b3d68703cc15.tar.bz2
vtk: Fix for vtk with --python (collect2: ld returned 1 exit status)
- Work-a-round: Add a temp symlink from Cellar/vtk to the cwd such that building the wrappers can find the libs. Then remove the symlink and let `make install` move everything into place. Closes #9796. Signed-off-by: Charlie Sharpsteen <source@sharpsteen.net>
Diffstat (limited to 'Library/Formula')
-rw-r--r--Library/Formula/vtk.rb12
1 files changed, 11 insertions, 1 deletions
diff --git a/Library/Formula/vtk.rb b/Library/Formula/vtk.rb
index 39fa2a823..9a2105fd0 100644
--- a/Library/Formula/vtk.rb
+++ b/Library/Formula/vtk.rb
@@ -68,7 +68,17 @@ class Vtk < Formula
args << ".."
Dir.chdir 'build' do
system "cmake", *args
- system "make install"
+ # Work-a-round to avoid:
+ # ld: file not found: /usr/local/Cellar/vtk/5.8.0/lib/vtk-5.8/libvtkDICOMParser.5.8.dylib for architecture x86_64"
+ # collect2: ld returned 1 exit status
+ # make[2]: *** [bin/vtkpython] Error 1
+ # We symlink such that the DCMAKE_INSTALL_NAME_DIR is available and points to the current build/bin
+ mkpath "#{lib}" # create empty directories, because we need it here
+ system "ln -s " + ENV['DYLD_LIBRARY_PATH'] + " '#{lib}/vtk-5.8'"
+ system "make"
+ system "rm '#{lib}/vtk-5.8'" # Remove our symlink, was only needed to make make succeed.
+ # end work-a-round
+ system "make install" # Finally move libs in their places.
end
end
end