安装fastlane
-
sudo gem install fastlane >
You don't have write permissions for the /usr/bin directory.
权限问题,将fastlane安装在/usr/local/bin:sudo gem install fastlane -n /usr/local/bin -
Failed to build gem native extension. >
Failed to build gem native extension,......To see why this extension failed to compile, please check the mkmf.log which can be found here:
可以打开mkmf.log: open mkmf.log 查看问题,发现是fatal error: 'ruby/config.h' file not found #include "ruby/config.h" 原因是缺少文件,将Xcode的配置拷贝到/usr/local/include:sudo cp -rf /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/include/ruby-2.6.0/universal-darwin19/ruby /usr/local/include/ -
ERROR: Failed to build gem native extension. >
No rule to make target `/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/include/ruby-2.6.0/universal-darwin20/ruby/config.h', needed by `unf.o'. Stop.'
需要在 ruby-2.6.0 目录下创建一个 universal-darwin20,因为cp -r命令失败,我的操作是到目录下面手动拷贝,/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/include/ruby-2.6.0/universal-darwin20
fastlane -v
网友评论