安装cocoapods时,查询rvm和ruby都安装上了,但是查询gem镜像的时候为空
然后执行gem sources -a http://ruby.taobao.org/命令后就报下面的错误:
错误提示:Unable to require openssl, install OpenSSL and rebuild Ruby (preferred) or use non-HTTPS sources (Gem::Exception)(编译的 Ruby 2.3.0 缺少 openssl 支持)
解决方法:
rvm reinstall 2.6.1 --with-openssl-dir=/usr/local/Cellar/openssl/1.0.2q(rvm版本号最好是最新的)
然后执行sudo gem install cocoapods
网友评论