Lion OSX: How to install libfreetype.6.dylib?

前端 未结 4 1469
滥情空心
滥情空心 2021-02-19 03:47

I am trying to install a ruby gem, but the installation process is stopped, because:

ld: file not found: /usr/local/lib/libfreetype.6.dylib for architecture x86_         


        
相关标签:
4条回答
  • 2021-02-19 04:23

    Gabriel F. Engel's answer almost worked for me. I had to do the following change:

    brew install freetype
    brew link --overwrite freetype
    
    0 讨论(0)
  • 2021-02-19 04:37

    What library are you trying to install? Could it by chance be ImageMagick? Also, if it's a RubyGem, why is the post tagged with homebrew?

    Anyways, I got this error when installing ImageMagick, you need to symlink /opt/X11/lib/libfreetype.6.dylib to /usr/local/lib.

    do this:

    ln -s /opt/X11/lib/libfreetype.6.dylib /usr/local/lib/libfreetype.6.dylib

    0 讨论(0)
  • 2021-02-19 04:38

    Your compiler is trying to link to an lib at a location that doesn't have the lib, however it seems that you have installed it with homebrew. Try running ln -s /usr/local/Cellar/freetype/2.4.10/lib/libfreetype.6.dylib /usr/local/lib/libfreetype.6.dylib to create one, or you can just use the without-freetype flag to skip it.

    0 讨论(0)
  • 2021-02-19 04:39

    If you're using brew, you can:

    brew link --overwrite freetype

    0 讨论(0)
提交回复
热议问题