Mac10.13.4通过Homebrew安装libimobiledevice时候总会出问题
Warning: You are using OS X 10.13.
We do not provide support for this pre-release version.
You may encounter build failures or other breakage.
最后导致:
checking for gcc... clang
checking whether the C compiler works... no
原因是安装libimobiledevice的时候需要安装多个依赖项:libtasn1, libxml2, libplist, libusb, usbmuxd, makedepend
这些依赖项下载下来后老版本的Homebrew与OS X10.13.4系统(系统权限有改变)权限有冲突。
解决办法:
1.sudo chown -R XXX /usr/local (XXX表示当前用户名)
2./usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
3.中途可能会出现一些错误:
直接删除这些就可以了
rm -rf /usr/local/share/man/man1/brew.1
4.安装libimobiledevice
brew install libimobiledevice
至此问题解决。