Tip: Mac 的ruby和环境千万别乱搞,否则xcode、编译、打包、自动打包、等都可能会出现各种麻烦问题。mac系统最好也别用beta版本。
1、xcode打包 hd_hoc 包报错:
/Library/Ruby/Site/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require': cannot load such file -- sqlite3 (LoadError)
from /Library/Ruby/Site/2.3.0/rubygems/core_ext/kernel_require.rb:55:in `require'
from /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool:24:in `<main>'
2017-11-05 11:53:46 +0000 /Applications/Xcode.app/Contents/Developer/usr/bin/ipatool exited with 1
2017-11-05 11:53:46 +0000 ipatool JSON: (null)
根本原因是缺少sqlite3
使用命令:
gem list | grep sqlite3
gem list | grep CFPropertyList
如果没有输出,证明没有安装。执行命令:
sudo gem install sqlite3
sudo gem install CFPropertyList
!!!!! 执行完,必须重启电脑才能生效 !!!