在 xcode 3.2.5 上安装 iOS SDK 4.1
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/4341667/
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
Installing iOS SDK 4.1 on xcode 3.2.5
提问by Luis
I've read through a lot of posts and couldn't really figure out the answer to this question. So I apologize if I duplicating it here.
我已经阅读了很多帖子,但无法真正找出这个问题的答案。所以如果我在这里复制它,我深表歉意。
I have installed xcode 3.2.5 to my machine and it comes with SDK 4.2. My iPhone is on 4.1 and I am not planning to move it to 4.2 just yet. Problem is that I can't use this phone for testing. Since the only SDK that I have installed is 4.2, when I try to run debug with my iPhone, I get this message:
我已经在我的机器上安装了 xcode 3.2.5,它带有 SDK 4.2。我的 iPhone 是 4.1,我不打算将它移到 4.2。问题是我不能用这款手机进行测试。由于我安装的唯一 SDK 是 4.2,当我尝试使用 iPhone 运行调试时,我收到以下消息:
Can't install application
无法安装应用程序
The info.plist for application at /blabla/app.app specifies a minimum OS of 4.2, which is too high to be installed on this device.
/blabla/app.app 中应用程序的 info.plist 指定最低操作系统为 4.2,这对于在此设备上安装来说太高了。
So, I got to Targets -> Get Info and I see that it is indeed targeting 4.2 (but that is the only option available - since I don't have the other SDK's installed).
所以,我进入了 Targets -> Get Info,我看到它确实针对 4.2(但这是唯一可用的选项 - 因为我没有安装其他 SDK)。
So, the question is: how to I keep xcode 3.2.5, but install SDK 4.1 in addition to 4.2?
所以,问题是:如何保留 xcode 3.2.5,但除了 4.2 之外还安装 SDK 4.1?
回答by danfelabs
It took a while to figure this out.
I couldn't see 'iOS Deployment Target' on the info.plist either. Here's what I did.
花了一段时间才弄清楚这一点。
我也无法在 info.plist 上看到“iOS 部署目标”。这就是我所做的。
a) Project -> Edit Project Settings
b) go to 'deployment' section
c) Change
'Targeted Device Family' = iPhone/iPad
'iOS Deployment Target = 'iOS 4.1'
a) 项目 -> 编辑项目设置
b) 转到“部署”部分
c) 更改
“目标设备系列”= iPhone/iPad
“iOS 部署目标 =“iOS 4.1”
回答by Daniel A. White
Open up your info.plist
in your project. There is a place where you can define for iOS 4.1.
info.plist
在你的项目中打开你的。有一个地方可以为 iOS 4.1 定义。
回答by ??u??
Just open the previous SDK dmg, then go to Packages, and install the SDK 4.1 package.
只需打开之前的 SDK dmg,然后转到 Packages,并安装 SDK 4.1 包。
More info : Install sdk 2.0 to 3.1 for xcode 3.2
更多信息:为 xcode 3.2 安装 sdk 2.0 到 3.1
Note : the "Packages" directory is not visible in the dmg since xcode_3.2.5_and_ios_sdk_4.2_final. Just use the Terminal (or finder "Go to folder") to open "/Volumes/Xcode and iOS SDK/Packages".
注意:自 xcode_3.2.5_and_ios_sdk_4.2_final 以来,“Packages”目录在 dmg 中不可见。只需使用终端(或查找器“转到文件夹”)打开“/Volumes/Xcode and iOS SDK/Packages”。
Edit : the xcode4.1 for Snow Leopard create an app called "Install Xcode.app". The packages directory is inside the app package.
编辑:雪豹的 xcode4.1 创建一个名为“安装 Xcode.app”的应用程序。包目录位于应用程序包内。
回答by Sam Ritchie
The best way to do this is to find a copy of Xcode 3.2.4, with iOS 4.1, and install it in a separate directory. When you install, take the dropdown that's set to Developer and switch it to DevOld
, or something similar. As there's no way to install new SDKs in the new version of Xcode, keeping multiple versions is the best you can do.
执行此操作的最佳方法是找到 Xcode 3.2.4 和 iOS 4.1 的副本,并将其安装在单独的目录中。安装时,选择设置为 Developer 的下拉菜单并将其切换为DevOld
,或类似的内容。由于无法在新版本的 Xcode 中安装新的 SDK,因此最好保留多个版本。
If you simply want to be able to run your app in 4.1, not necessarily develop in it, go into your target's settings, and under the build tab, set the iOS Deployment Target
key to 4.1 or below.
如果您只是希望能够在 4.1 中运行您的应用程序,而不必在其中进行开发,请进入目标设置,然后在构建选项卡下,将iOS Deployment Target
密钥设置为 4.1 或更低版本。
Good luck!
祝你好运!
回答by Alex Fedoseev
What you need to do is: In the BUILD section of the Project info click on Show and change its value from Setting defined at this level to All Settings.
您需要做的是:在项目信息的 BUILD 部分中,单击 Show 并将其值从在此级别定义的设置更改为所有设置。
In the updated list of settings you will surely locate the desired one.
在更新的设置列表中,您一定会找到所需的设置。
Good Luck!
祝你好运!