15

I followed the instructions in the PhoneGap 2.0.0 getting started with iOS guide. It seems not update to date, because some files in the created project have other names than in the guide. Apart from this, a warning and error occures while building.

  1. Warning: Check dependencies: Missing dependency target "CordovaLib (from CordovaLib.xcodeproj)"
  2. Error: CpResource /VERSION /<...>/Test.app/VERSION cd /<...>/test-phonegap setenv PATH "/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin" builtin-copy -exclude .DS_Store -exclude CVS -exclude .svn -exclude .git -exclude .hg -resolve-src-symlinks -strip-tool /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/strip /VERSION /<...>/Build/Products/Debug-iphonesimulator/Test.app

error: /VERSION: No such file or directory

Do you have any ideas how get it working? Thanks and best regards.

-- Guide: http://docs.phonegap.com/en/2.0.0/guide_getting-started_ios_index.md.html#Getting%20Started%20with%20iOS

4

6 回答 6

15

下载并解压PhoneGap 2.0.0后,打开“phonegap-phonegap-ff91e6e/lib/ios/Cordova-2.0.0.dmg”,然后安装“Cordova-2.0.0.pkg”。关闭并重新打开您的项目。它应该工作。

于 2012-07-24T18:44:59.177 回答
11

You need to manually set the CORDOVALIB setting:

Open XCode -> Preferences, go to Locations -> Source Trees

If you don't have a CORDOVALIB entry there, create one:

Click "+" at the bottom, enter:

  • Setting Name: CORDOVALIB
  • Display Name: CORDOVALIB
  • Path: /Users/[your_user_name]/Documents/CordovaLib

The "Path" should point to the folder created by the Cordova Installer (Cordova-2.0.0.pkg).

于 2012-09-06T09:08:06.500 回答
3

为我找到解决方案:将 CordovaLib.xcodeproj 导入项目的工作区。如果您同时打开了 2 个打开的 PhoneGap 项目,则 CordovaLib 将仅可用于这两个项目中的一个...关闭所有 phonegap 项目并一次只打开一个。

于 2012-07-26T14:18:32.690 回答
2

我刚刚清理了项目并且它工作了:产品 - >清洁

于 2012-08-17T10:27:48.963 回答
0

将 CordovaLib.xcodeproj(在我的 Documents/CordovaLib 目录中 - 安装程序至少完成了该部分...)拖放到我的项目中(将其创建为子项目)为我消除了这些错误。

于 2012-08-22T13:58:05.550 回答
0

我发现我正在使用 Mountain Lion 并且遇到了同样的问题。我必须转到系统偏好设置>安全和隐私>“允许从以下位置下载应用程序”

...然后检查“任何地方”的选项。默认情况下,它们会锁定外部应用程序以仅从 Mac App Store 加载。

于 2012-08-06T21:48:56.237 回答