Library not loaded: /usr/local/o
2020-06-01 本文已影响0人
阿召
家里电脑好久没用,安装cocoapods时报错,应该是本地的openssl升级了导致的
➜ ~ sudo gem install cocoapods
Password:
ERROR: Loading command: install (LoadError)
dlopen(/usr/local/Cellar/ruby/2.4.1_1/lib/ruby/2.4.0/x86_64-darwin16/openssl.bundle, 9): Library not loaded: /usr/local/opt/openssl/lib/libssl.1.0.0.dylib
Referenced from: /usr/local/Cellar/ruby/2.4.1_1/lib/ruby/2.4.0/x86_64-darwin16/openssl.bundle
Reason: image not found - /usr/local/Cellar/ruby/2.4.1_1/lib/ruby/2.4.0/x86_64-darwin16/openssl.bundle
ERROR: While executing gem ... (NoMethodError)
undefined method `invoke_with_build_args' for nil:NilClass
解决办法:切换openssl 版本
brew switch openssl 1.0.2m