我找到了解决方案,伙计。当我用谷歌搜索这个问题时,你应该得到相同的答案,就像这样:
$ sudo arch -x86_64 gem install ffi
$ arch -x86_64 pod install
但这是错误的!!!检查您的错误日志
/Library/Ruby/Site/2.6.0/rubygems/core_ext/kernel_require.rb:85:in `require': dlopen(/Library/Ruby/Gems/2.6.0/gems/date-3.1.1/lib/date_core .bundle, 9): 没有找到合适的图片。确实找到了:(LoadError)/Library/Ruby/Gems/2.6.0/gems/date-3.1.1/lib/date_core.bundle: mach-o,但是架构错误/Library/Ruby/Gems/2.6.0/gems /date-3.1.1/lib/date_core.bundle:mach-o,但架构错误 - /Library/Ruby/Gems/2.6.0/gems/date-3.1.1/lib/date_core.bundle
这意味着您需要宝石的日期。所以:
sudo gem install date
它完成了!
您可能还会看到此错误:
dlopen(/Library/Ruby/Gems/2.6.0/gems/bigdecimal-3.0.2/lib/bigdecimal.bundle, 9): no suitable image found. Did find: (LoadError)
/Library/Ruby/Gems/2.6.0/gems/bigdecimal-3.0.2/lib/bigdecimal.bundle: mach-o, but wrong architecture
/Library/Ruby/Gems/2.6.0/gems/bigdecimal-3.0.2/lib/bigdecimal.bundle: mach-o, but wrong architecture - /Library/Ruby/Gems/2.6.0/gems/bigdecimal-3.0.2/lib/bigdecimal.bundle
所以就:
sudo gem install bigdecimal
它完成了!