xcode 无法从设备读取
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/10926900/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Could not read from the device
提问by sniper
I am trying to install a new version of my application on the top of the last version through Xcode.
我正在尝试通过 Xcode 在上一个版本的顶部安装我的应用程序的新版本。
Whenever I try to install it with the same provisional profile and details, I encountered this problem. This problem occurs after the build (while copying the files).
每当我尝试使用相同的临时配置文件和详细信息安装它时,都会遇到此问题。构建后(复制文件时)会出现此问题。
Has anyone faced this issue??
有人遇到过这个问题吗??
PS: I have attached the error screenshot:
PS:我附上了错误截图:
!
!
采纳答案by sniper
I got the solution for this!
我得到了解决方案!
To avoid this error, just add a user-defined build setting:
为避免此错误,只需添加用户定义的构建设置:
PREBINDING = NO
This would be added under the user-defined section in Build phases.
这将添加到构建阶段的用户定义部分下。
回答by jcpennypincher
What worked for me were these steps:
对我有用的是这些步骤:
- Delete the existing app you are trying to build from iPhone/iPad
- Sync with iTunes
- Kill both Xcode and iTunes completely
- Open Xcode and Build & Run
- 删除您尝试从 iPhone/iPad 构建的现有应用程序
- 与 iTunes 同步
- 完全杀死 Xcode 和 iTunes
- 打开 Xcode 和 Build & Run
回答by mgj
For me, just deleting the app from my device and restarting Xcode was enough. Restarting Xcode seems to be the solution to many problems these days...
对我来说,只需从我的设备中删除应用程序并重新启动 Xcode 就足够了。重新启动 Xcode 似乎是这些天许多问题的解决方案......
回答by sanjeev sharma
Delete the previously installed build from the device, quit Xcode, restart the device, and then install the application after cleaning all targets.
从设备中删除之前安装的构建,退出Xcode,重新启动设备,然后在清理所有目标后安装应用程序。
回答by William Denniss
Clearly this is a YMMVsituation. I had a very stubborn case of this, and here's what worked for me:
显然,这是YMMV 的情况。我有一个非常顽固的案例,这对我有用:
- Deleted the app from the device
- Viewed the profiles of the device in Xcode → Organiser
- I noticed there were two copies of the development profile that I was signing with installed (all profiles on the device were valid, including these two)
- Deleted all instances (i.e. both) of the development profile I'm signing with
- Build and run from Xcode. The app was re-installed, along with one copy of the development profile, and it worked.
- 从设备上删除了应用程序
- 在 Xcode → Organizer 中查看设备的配置文件
- 我注意到有两个我正在签名的开发配置文件副本安装(设备上的所有配置文件都是有效的,包括这两个)
- 删除了我正在签署的开发配置文件的所有实例(即两个)
- 从 Xcode 构建和运行。重新安装了该应用程序以及一份开发配置文件,并且可以正常工作。
Based on this, I would try: Remove all instances of the development profile you are signing with your development profile from the device, and try running it again. I don't know if step 1 is necessary; I suspect it may not be.
基于此,我会尝试:从设备中删除您使用开发配置文件签名的开发配置文件的所有实例,然后再次尝试运行它。我不知道是否需要第 1 步;我怀疑可能不是。
回答by skram
To fix it, try these few steps:
要修复它,请尝试以下几个步骤:
Synchronize your device in iTunes. (If you really want to save current version, make a backup
before
proceeding.)Delete the app you're try-ing to
update
over, then restore the device from the backup.Synchronise again.
在 iTunes 中同步您的设备。(如果您确实想保存当前版本,请进行备份
before
。)删除您正在尝试使用的应用程序
update
,然后从备份中恢复设备。再次同步。
Finally, in Xcode, menu Build→ Cleanand try installing over.
最后,在 Xcode 中,菜单Build→ Clean并尝试安装。
I hope this helps!
我希望这有帮助!