Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where can I get version 16.0.0 of libfreetype.6.dylib for ImageMagick on MAMP

When running imagemagick under MAMP I get the error message:

command output :"dyld: Library not loaded: /opt/local/lib/libfreetype.6.dylib
Referenced from: /Applications/MAMP/bin/ImageMagick/ImageMagick-6.7.9/bin/convert
Reason: Incompatible library version: convert requires version 16.0.0 or later, but libfreetype.6.dylib provides version 15.0.0"

I have searched everywhere I can think of but can't find a solution to this. One posting I saw suggested commenting out the DYLD_LIBRARY_PATH in envvars but this did not make any difference.

like image 999
Bill Noble Avatar asked Oct 07 '12 11:10

Bill Noble


2 Answers

Figured it out. I ran:

$ locate libfreetype.6.dylib

and discovered that there are multiple version of that dylib including a version in /opt/local/lib where macports installs imagemagick. I copied that version to the location in MAMP where it was installed and it solved the issue.

$ cp /opt/local/lib/libfreetype.6.dylib /Applications/MAMP/Library/lib/

Make sure you make a backup of the MAMP version before copying over it just in case something goes wrong.

like image 163
Jim S. Avatar answered Jan 03 '23 14:01

Jim S.


I had the same issue. For me works this:

sudo port selfupdate
sudo port install ImageMagick

sudo pecl update-channels
sudo pecl install imagick

Then I run

find . -name "imagick.so"

and use the given path in MAMP php.ini.

In the end I commented out the DYLD_LIBRARY_PATH lines in /Applications/MAMP/Library/bin/envvars

like image 32
elweilando Avatar answered Jan 03 '23 14:01

elweilando