Xcode将在模拟器上运行应用程序,但不会在设备上运行应用程序 [英] Xcode will run app on simulator but not on device

查看:191
本文介绍了Xcode将在模拟器上运行应用程序,但不会在设备上运行应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

 错误:无法启动/用户 / michael / Library / Developer / Xcode / DerivedData / Build / Products / Debug-iphoneos / Word Processor.app/Word Processor' - 没有这样的文件或目录(/ Users / michael / Library / Developer / Xcode / DerivedData / Build /产品/ Debug-iphoneos / Word Processor.app/Word处理器)

应用程序在模拟器中运行正常。当我尝试在设备上调试时,似乎复制应用程序(我可以看到图标),但是随着上面的消息停止。 Xcode说它正在运行我的iPod上的应用程序,但我的iPod上没有任何事情。



当我点击应用程序时,应用程序似乎启动,但似乎缺少资源。
我的其他项目正常工作。需要更改哪些设置才能使其正常工作?看看错误信息,似乎是在我的mac的应用程序。但是这并没有什么意义,因为我试图在第四代iPod touch上运行它。我正在使用Xcode 4.3.1和iOS 5.1

解决方案

使用Mountain Lion和最新版本的Xcode(4.4.4F250)这个线程中的建议没有直接工作(干净,干净的项目,删除派生数据文件夹等)。这个顺序是。来自 DhilipSiva


  1. 断开您的设备

  2. 从您的设备中删除该应用<
  3. 退出Xcode(不要简单地关闭窗口,退出)

  4. 删除派生数据文件夹 rm -fr〜/ Library / Developer / Xcode / DerivedData (console)

  5. 启动Xcode,连接设备&运行项目


I receive the following error when trying to run the app on my device.

error: failed to launch '/Users/michael/Library/Developer/Xcode/DerivedData/Build/Products/Debug-iphoneos/Word Processor.app/Word Processor' -- No such file or directory (/Users/michael/Library/Developer/Xcode/DerivedData/Build/Products/Debug-iphoneos/Word Processor.app/Word Processor)

The app runs fine in the simulator. When I try to debug on the device, it appears to copy the app (I can see the icon), but then stalls with the above message. Xcode says it is running the app on my iPod, but nothing is happening on my iPod.

When I click on the app, the app appears to launch, but seems to be missing resources. Other projects of mine work properly. What setting do I need to change to make this work properly.? Looking at the error message, it seems to be looking in my mac for the app. But this doesn't make sense since I am trying to run it on my 4th gen iPod touch. I am using Xcode 4.3.1 and iOS 5.1

解决方案

With Mountain Lion and the latest version of Xcode (4.4.4F250), none of the suggestions in this thread worked directly (clean, clean project, remove derived data folder, etc). This sequence did. From DhilipSiva:

  1. Disconnect your device
  2. Delete the app from your device
  3. Quit Xcode (Don't just simply close the window, quit it)
  4. Delete derived data folder rm -fr ~/Library/Developer/Xcode/DerivedData (console)
  5. Start Xcode,connect device & run the project

这篇关于Xcode将在模拟器上运行应用程序,但不会在设备上运行应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆