2

I am trying to use paperclip on macosx with phusion passenger. When i try to make an upload, apache give me :

dyld: Library not loaded: /usr/local/lib/libjpeg.8.dylib
  Referenced from: /usr/local/lib/libtiff.3.dylib
  Reason: Incompatible library version: libtiff.3.dylib requires version 13.0.0 or later, but libjpeg.8.dylib provides version 12.0.0

But when i run my rails application with rails server, everything works fine. When i try to use the identify command in my terminal as well.

Paperclip give me this error :

/Var/Folders/Nj/9xt2kprd01n3ssch3rd44pmh0000gn/T/Stream20120222-92627-1l2u297.Png Is Not Recognized By The 'Identify' Command.

Any idea? I am using MacOsx Lion

Sebastien
  • 6,640
  • 14
  • 57
  • 105
  • Did you solve this? I'm having a similar issue with ffmpeg on MaxOsx Lion - http://stackoverflow.com/questions/10107671/ffmpeg-mamp-dyld-library-not-loaded-error – benedict_w Apr 12 '12 at 11:21
  • Hello, no i don't, i forgave...When i want to use this, i launch the rails server and no phusion. – Sebastien Apr 12 '12 at 13:18
  • Similar problem here, perhaps. Used to work, but now: `dyld: Library not loaded: /usr/local/lib/libtiff.3.dylib Referenced from: /usr/local/bin/identify Reason: image not found` – Leo May 15 '12 at 16:14

2 Answers2

2

Further to my comment, I just had a similar problem and solved it as follows (not sure if this will work for you).

As per this homebrew/imagemagick issue, precompiled binaries may reference the wrong library versions when something else is upgraded.

Therefore, recompiling Imagemagick from source may help. For my own install, via Homebrew, this did it:

> brew uninstall imagemagick
> brew install imagemagick --build-from-source

My guess is that in your case Apache and/or Passenger may be calling a different version of Imagemagick, or operating as a different user with different load paths and therefore not finding the library.

Leo
  • 4,217
  • 4
  • 25
  • 41
1

I was running into this same issue on OS X 10.8 and reinstalling imagemagick from source had no effect but reinstalling libtiff from source did. yay! :)

brew uninstall libtiff
brew install libtiff --build-from-source

I found this out by using otool -L which showed that somehow libtiff was pointing to a newer version of libjpeg than installed on my system. reinstalling it from source causes it to link against the older version.

hope that helps!

Victor Powell
  • 1,828
  • 1
  • 12
  • 8