iPad应用无法在Retina模拟器中安装

4
我为此费尽心思,但可能只是犯了一个愚蠢的错误。在切换到Xcode 4.5.1后(可能发生在4.5),我简直无法将应用程序加载到iPad Retina模拟器中。我已经编辑了编译方案,要求始终使用iPad的Retina显示屏。但还是不行。过去,你可以随时更改模拟器,打开哪个模拟器就是项目编译的模拟器。但我不知道如何在4.5中实现这一点。帮帮我!

1
模拟器运行的是哪个操作系统版本?我刚刚在我的设备上尝试了一下,如果使用5.0版本,似乎只会启动非Retina模拟器。 - James P
2个回答

5

有些奇怪的事情正在发生,似乎不符合预期。请按以下顺序尝试这些解决方案。

  1. Your method is correct, you set your Simulator Display preference when editing your schemes. Make sure your destination for the scheme is the iPad simulator, that it's tied to the Run scheme, and set iPad Simulator display to Retina. Save/apply your scheme changes, try to run your app. If that doesn't work, close + re-open Xcode, check scheme settings to see if they stuck, and try again

    How to change simulator display preference

    You may want to double check if your changes stuck. Delve into your project file (by right clicking on your project file, and selecting "Show Package Contents"). Then navigate to:

    xcuserdata->username.xcuserdatad->xcschemes->ProjectName.xcscheme
    

    Open it up in your favourite editor, and check to see if there's a:

    simulatorIPadDisplay = "2.000000"
    

    ...for your required scheme

  2. If none of that worked, then it may be an issue with your derived data (unlikely, but step 1 should have worked). Go to Organizer, and select the Projects tab. Then hit 'Delete...' for derived data. Do the same as before; run, close Xcode, check and re-run.

    How to delete derived data within Organizer

  3. Well we really are in a pickle, that is the only method to set your preferred simulator display for a build scheme. You may need to resort to removing Xcode and re-installing, and trying the previous steps again.

  4. What on earth is going on?! We've exhausted our methods, you may need to let Apple know about this issue.


越来越好奇了。你有关Derived Data的评论让我去查找了一下,根据Xcode组织者的说法,在~/Library/Developer/Xcode/DerivedData中明显存在Derived Data(要删除)。我尝试手动删除该文件夹,Xcode按照我的预期重新构建了索引,但是组织者中的Derived Data条目仍然被禁用。我将Xcode移到回收站并下载了一个新版本,结果还是一样。我想下一步就是进行完全卸载、重新安装并观察情况的变化。但如果失去所有自定义设置的话,我会感到非常遗憾。 - rsswtmr

4

经过长时间的“查找所有设置文件并保存它们,删除Xcode及其所有设置文件,重新安装Xcode,重新下载模拟器和文档,替换设置文件等等”后,我发现自己仍处于同样的境地。没有视网膜模拟器。

问题不在于Xcode或项目文件 - 5.0模拟器根本无法以视网膜模式启动。我在编译方案中切换到5.16.0模拟器时发现,它们可以正常工作。切换回5.0,我就被困在普通模拟器模式下。我一直使用5.0模拟器是为了测试最低公共iOS功能。此外,iOS 6.0存在一个影响通过IPSec进行大包传输的错误,尚未得到修复。

因此,我仍然不知道缺少的派生数据状态是怎么回事,除了现在已经解决了,我认为重新安装应用程序是解决方法。


1
你没有看到我的评论吗?5.0版本的模拟器在Retina上无法启动,我猜测是因为没有运行5.0的Retina iPad。 - James P
直到我回答完了你的问题,才发现你的评论。你可以手动将5.0模拟器切换为Retina。你只是不能在编译/运行/调试过程中作为一部分启动它。你说得对,确实没有运行5.0的Retina版iPad - 我没有想到这点。 - rsswtmr

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接