【问题标题】:Cocoapods Unable to find a targetCocoapods 找不到目标
【发布时间】:2014-12-17 00:32:42
【问题描述】:

我正在尝试在我的 vmbox 上使用 cocoapods 在项目中安装一些库。当前 Podfile 与我的 .xcodeproj 位于同一目录中,我的 Podfile 的内容是:

platform :ios, '7.0'

pod 'Mantle'
pod 'LBBlurredImage'
pod 'TSMessages'
pod 'ReactiveCocoa'

尝试运行时:

pod install

从命令行我得到错误

[!] Unable to find a target

【问题讨论】:

标签: virtualbox cocoapods


【解决方案1】:

这里有类似的问题:

How do I select a project in my Podfile? I'm getting the error: Unable to find the Xcode project for the target 'Pods'

对我来说,我按照教程中的说明使用 pico 编辑器进行了编辑,并且效果很好。

【讨论】:

    【解决方案2】:

    出现问题是因为您的 Xcode(项目文件 -> 目标)中的“目标构建”为空。在 Xcode 6.0+ 中,当您创建一个“空”项目(文件 -> 新项目 -> 其他)时,它会创建一个完全空的项目,这与以前的版本不同。如果您想在 Xcode 5 中创建一个空项目,您需要创建一个“单一视图应用程序”并进行一些更改,如下所述:How to create an Empty Application in Xcode 6 without Storyboard

    【讨论】:

      猜你喜欢
      • 2018-05-29
      • 2014-11-23
      • 1970-01-01
      • 1970-01-01
      • 2016-10-09
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2015-12-24
      相关资源
      最近更新 更多