Answers:
要使Snow Leopard上的Xcode 4.2在运行iOS 5.1的设备上运行代码,您可以执行以下操作:
如果您有另一台运行Lion和Xcode 4.3.1的Mac,则可以从以下位置复制文件:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.1(9B176)
将复制的文件放在Snow Leopard Mac上的同等位置:
/Developer/Platforms/iPhoneOS.platform/DeviceSupport
同样,复制在此目录中找到的iOS 5.1 SDK文件:
/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk
还要将“ version.plist”从iPhoneOS.platform文件夹中的Lion机复制到Snow Leopard机。
在Snow Leopard机器上重新启动Xcode,然后重新连接设备,这似乎很高兴。
如果您无法使用Lion和Xcode 4.3.1访问计算机:
您可以从以下位置获取文件,这些文件4.3.1 DMG
可以从Apple 下载:Apple开发人员下载。
挂载DMG,在Xcode图标上显示包内容并向下钻取
/Volumes/Xcode/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport
请按照上述步骤。
您可能会发现在终端窗口中使用Apple专有的ditto
方法(sudo ditto src dest
)复制文件夹更为方便。
请注意,此技巧也适用于最新的iOS 6 SDK。
我现在正在研究这个。我有同样的问题。
这里的主要问题是:
1)苹果公司从未提供过警告对话框,警告说这可能使人们在Snow Leopard下无法发展。
2)没有简单的方法可以撤销此操作。
3)这不应在点发布更新中发生。
我已经尝试从此处为我的Gen 4 iPod Touch从5.0.1安装以前的ipsw: 在哪里下载ipod touch固件还原链接 它不会安装。
我从这里下载了Lion Xcode 4.3.1(首先以开发人员身份登录) Lion Xcode 4.3.1
并在此处的开发论坛中运行一些脚本:
sudo cp -R /Volumes/Xcode/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/
sudo cp -R /Volumes/Xcode/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/
sudo cp -R /Volumes/Xcode/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.1\ \(9B176\) /Developer/Platforms/iPhoneOS.platform/DeviceSupport/
cd /Developer/Platforms/iPhoneOS.platform/DeviceSupport/
sudo rm -f ./Latest
sudo ln -s ./5.1\ \(9B176\) ./Latest
卸载Lion DMG,然后重新启动Xcode。这使我能够在模拟器中测试5.1,但由于SIGABRT或链接错误而导致每个设备的构建中断。
我要去苹果商店,让他们还原我的设备。如果有更多信息,我会让大家知道。这是一个非常昂贵和非常不愉快的惊喜。
添加到上面的Richards解决方案中,我发现如果您还从XCode 4.3.1 dmg复制...
编辑:更新到dmg中的正确路径
/Volumes/Xcode/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS5.1.sdk ~~(整个目录树)
至
/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/
XCode调试器将正确启动(没有所有错误日志和转储)
ie:
===============================================================================
warning: Unable to read symbols from "dyld" (prefix __dyld_) (not yet mapped into memory).
warning: Unable to read symbols from "SystemConfiguration" (not yet mapped into memory).
warning: Unable to read symbols for /Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.1 (9B176)/Symbols/System/Library/Frameworks/MessageUI.framework/MessageUI (file not found).
warning: No copy of dyld found locally, reading from memory on remote device. This may slow down the debug session.
warning: No copy of <No file name> found locally, reading from memory on remote device. This may slow down the debug session.
warning: No copy of <No file name> found locally, reading from memory on remote device. This may slow down the debug session.
warning: Unable to read symbols for /Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.1 (9B176)/Symbols/System/Library/Frameworks/SystemConfiguration.framework/SystemConfiguration (file not found).
warning: No copy of SystemConfiguration.framework/SystemConfiguration found locally, reading from memory on remote device. This may slow down the debug session.
warning: Unable to read symbols for /Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.1 (9B176)/Symbols/System/Library/Frameworks/MessageUI.framework/MessageUI (file not found).
warning: No copy of MessageUI.framework/MessageUI found locally, reading from memory on remote device. This may slow down the debug session.
warning: Unable to read symbols for /Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.1 (9B176)/Symbols/System/Library/Frameworks/AudioToolbox.framework/AudioToolbox (file not found).
warning: No copy of AudioToolbox.framework/AudioToolbox found locally, reading from memory on remote device. This may slow down the debug session.
warning: Unable to read symbols for /Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.1 (9B176)/Symbols/System/Library/Frameworks/iAd.framework/iAd (file not found).
warning: No copy of iAd.framework/iAd found locally, reading from memory on remote device. This may slow down the debug session.
warning: Unable to read symbols for /Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.1 (9B176)/Symbols/System/Library/PrivateFrameworks/SpringBoardServices.framework/SpringBoardServices (file not found).
warning: No copy of SpringBoardServices.framework/SpringBoardServices found locally, reading from memory on remote device. This may slow down the debug session.
warning: Unable to read symbols for /Developer/Platforms/iPhoneOS.platform/DeviceSupport/5.1 (9B176)/Symbols/System/Library/PrivateFrameworks/FTClientServices.framework/FTClientServices (file not found).
warning: No copy of FTClientServices.framework/FTClientServices found locally, reading from memory on remote device. This may slow down the debug session.
===============================================================================
这里有一个答案,也提供了模拟器v 5.1的副本。无需人工操作。只需打开终端,复制并粘贴提供的命令。
http://www.iphonedevsdk.com/forum/iphone-sdk-development/100229-snow-leopard-sdk-5-1-a.html
如果您还想将iphone模拟器5.1添加到您的xcode中,然后复制
/Volumes/Xcode/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator5.1.sdk
整个目录到以下路径=>
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/
之后您还可以使用iPhone模拟器5.1调试应用程序。
您可以在5.1或5.1.1设备上使用针对5.0编译的应用程序,方法是将它们编译并手动将.app文件拖到iTunes中。今天在10.6.8和XCode 4.2上试用。
通过以下链接下载设备的iOS 5.0.1固件:http : //www.iphonefirmware.com/firmwares-download。
并在iTunes上进行手动还原。
我是今天(3月8日)在iPad 2上完成此操作的,并且可以正常运行,但是Apple似乎仍在签署此iOS版本。
在xcode 4.2上无法使用5.1设备,因为您不想升级,因此可以使用管理器,选择设备并使用还原功能。您可以使用Google搜索5.0.1版本并使用该版本。
(尽管升级到狮子是超级便宜的)
编辑:似乎这是可能的,向上滚动以获得最高投票率的答案。
您还必须添加Symbols别名。例如,/Developer/Platforms/iPhoneOS.platform/DeviceSupport/6.0 (10A403)
您必须添加指向此符号的Symbols别名,/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.0.sdk
以便xcode 4.2可以检测到您的ios6设备(已在mac mini 1.5 intel core雪豹上进行了测试)。干杯
Symbols
复制DeviceSupport/6.0 (10A403)
文件夹后,别名已经存在。