ARCore SDK开发指南Step1 - CocoaPods安装

ARCore SDK开发指南Step1 - CocoaPods安装,第1张

项目场景:

为执行AugmentedFacesSample 附带的预配置 ARCore SDK,需要依赖项CocoaPods运行安装,在按照官网安装过程中遇到如下问题:


问题1

运行 sudo gem install cocoapods报错:

ERROR:  Error installing cocoapods:
	ERROR: Failed to build gem native extension.
解决方案:

换用brew安装,依次执行
cleanup -d -v
brew install cocoapods

如遇到以下报错信息:

==> `brew cleanup` has not been run in 30 days, running now...
Error: Permission denied @ apply2files - /usr/local/lib/docker/cli-plugins

执行brew unlink cocoapods && brew link cocoapods


问题2

在Podfile所在AugmentedFacesExample目录文件下运行 pod install报错:

Analyzing dependencies
Cloning spec repo `trunk` from `https://cdn.cocoapods.org/`
[!] Unable to add a source with url `https://cdn.cocoapods.org/` named `trunk`.
You can try adding it manually in `/Users/aspen/.cocoapods/repos` or via `pod repo add`.
解决方案:

依次执行,即可完成ARCore SDK安装
pod repo add-cdn trunk https://cdn.cocoapods.org/
pod install


此时,在Xcode项目AugmentedFacesSample所在的文件夹,产生一个*.xcworkspace文件,日后用于构建和运行应用程序。

欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/web/996524.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-05-21
下一篇 2022-05-21

发表评论

登录后才能评论

评论列表(0条)

保存