Ruby on rails 我如何让Cucumber和RMagick在雪豹身上玩得很好?

Ruby on rails 我如何让Cucumber和RMagick在雪豹身上玩得很好?,ruby-on-rails,macos,osx-snow-leopard,cucumber,Ruby On Rails,Macos,Osx Snow Leopard,Cucumber,我安装了SnowLeopard,经过几次重新安装,一切都很顺利。但现在当我运行cucumber时,我得到了下面的错误,我无法通过谷歌搜索找到任何结论。有没有人遇到过这种情况,或者可能有一些故障排除步骤要尝试 $ cucumber features dyld: NSLinkModule() error dyld: Library not loaded: /opt/local/lib/libfreetype.6.dylib Referenced from: /usr/local/lib/rub

我安装了SnowLeopard,经过几次重新安装,一切都很顺利。但现在当我运行cucumber时,我得到了下面的错误,我无法通过谷歌搜索找到任何结论。有没有人遇到过这种情况,或者可能有一些故障排除步骤要尝试

$ cucumber features 
dyld: NSLinkModule() error
dyld: Library not loaded: /opt/local/lib/libfreetype.6.dylib
  Referenced from: /usr/local/lib/ruby/gems/1.8/gems/rmagick-2.10.0/lib/RMagick2.bundle
  Reason: no suitable image found.  Did find:
    /opt/local/lib/libfreetype.6.dylib: can't map
    /usr/local/lib/libfreetype.6.dylib: mach-o, but wrong architecture
Trace/BPT trap

您应该检查rmagick是否为新osx的正确版本和编译是否正确。

它导致.dylib文件位于/usr/X11/lib/libfreetype.6.dylib

所以这只是从那里复制它的问题,或者做一个符号链接:

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

这可能只是另一个32/64位的问题(“错误的体系结构”),至少如果“file/opt/local/lib/libfreetype.6.dylib”的输出不是特别的话。重新编译二进制文件并确保它们与正在运行的内核匹配。