命令工具ReactNative

M1处理器 cocoapods pod install 等命令

2022-06-20  本文已影响0人  AngryProject

错误信息:
Users/xxxxx/.rvm/rubies/ruby-3.0.0/lib/ruby/gems/3.0.0/gems/ffi-1.15.5/lib

Error (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e'))

dlopen(/Library/Ruby/Gems/2.6.0/gems/bigdecimal-1.4.4/lib/bigdecimal.bundle, 0x0009): tried: '/Library/Ruby/Gems/2.6.0/gems/bigdecimal-1.4.4/lib/bigdecimal.bundle' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64e')) - /Library/Ruby/Gems/2.6.0/gems/bigdecimal-1.4.4/lib/bigdecimal.bundle (LoadError)


更新Homebrew
/bin/zsh -c "$(curl -fsSL https://gitee.com/cunkai/HomebrewCN/raw/master/Homebrew.sh)"

source /Users/xxxxxx/.bash_profile

安装 rvm
curl -L get.rvm.io | bash -s stable  
source ~/.bashrc 
source ~/.bash_profile 

更新 ruby 到最新版
rvm list known 
rvm install 3.0.0
source ~/.rvm/scripts/rvm
rvm --default use 3.0.0
ruby -v

(更新 Gem  :  sudo gem update -n /usr/local/bin —system )

更新 cocoapods
sudo gem install -n /usr/local/bin cocoapods

cd 到项目

pod install

上一篇下一篇

猜你喜欢

热点阅读