无法在 iOS4 上编译 Three20 模板
我从 github 上获取了 Three20 的最新版本并安装了他们的模板。我在 XCode 中打开它,构建它,运行它,然后我意识到该模板还没有准备好 iOS4。
我发现的第一个问题是“未找到 Base SDK”。我在编辑项目设置中通过将 Base SDK 更改为“iOS Device 4.1”解决了这个问题。
然后我又跑了一次。我收到大量与“Three20/Three.h:没有这样的文件或目录”相关的错误。我将“../third20/src”添加到我的标题搜索路径中,但没有帮助。
有谁知道为什么?我还应该改变什么?
仅供参考:
XCode 版本 3.2.4
Three20 最新版本(9 月 29 日)
目录:
xcode/myproject/
xcode/two20/
PS:该模板在 SDK 3.0 中工作正常
I pulled the latest version of three20 from github and installed their template. I opened it up in XCode, built it, ran it, then I realized the template isn't iOS4 ready.
The first issue I found was "Base SDK not found". I solved it in Edit Project Setting by changing the Base SDK to "iOS Device 4.1".
Then I ran it again. I got tons of errors related to "Three20/Three.h: No such file or directory". I added the "../three20/src" to my Header Search Paths but it doesn't help.
Does anyone know why? What else should I change?
FYI:
XCode Version 3.2.4
Latest version of three20 (29 September)
Directories:
xcode/myproject/
xcode/three20/
PS: the template works fine in SDK 3.0
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
自从将 Three20 正确添加到你的新 iOS4 中后,我也很抓狂,这里列出了非常基本的说明: http:// github.com/facebook/third20 也不起作用。
问题:可以将新的 Three20 编译到您的 iOS 项目中并收到此错误:找不到#import“Three20/Three20.h”。
对于有相同问题的人来说,以下是最佳解决方案:
1) 将您的 Three20 添加到您的 iphone 项目路径中,如下所示:
[你的项目路径]/[iOS项目名称]/third20/..
2) cd Three20 目录
3)运行:
python src/scripts/ttmodule.py -p [yourProjectPath]/[iOSProjectName]/[iOSProjectName].xcodeproj Three20 -c Debug -c Release
4) 现在转到 XCode 并进行构建。
感谢 jverkoey 将其添加到 ...man
如果你读过这篇文章,你会为我们省去很多麻烦:-) 荣誉,伙计! :- )
br>
如果这个答案对您有帮助,请投票。谢谢:-)
I was pulling my hair out as well since adding three20 correctly to your new iOS4 with really basic instructions listed here: http://github.com/facebook/three20 did not work as well.
Issue: Can compile newly three20 to your iOS project and got this error: Can't find #import "Three20/Three20.h".
Here is the best solution for those have the same issue:
1) Add your three20 to your iphone project path like this:
[yourProjectPath]/[iOSProjectName]/three20/..
2) cd three20 dir
3) run:
python src/scripts/ttmodule.py -p [yourProjectPath]/[iOSProjectName]/[iOSProjectName].xcodeproj Three20 -c Debug -c Release
4) go to XCode and do a build now.
Thanks to jverkoey for adding this in ...man
u save us a lot of headache if u ever read this :- ) kudos bud! :- )
http://github.com/facebook/three20/commit/0814b1c149cbe987557c88a271f999c3f9f3ae64
Please vote this answers if it help u. Thanks :-)
结果我必须使用 http://github.com/ECP/ Three20 代替。
Turn out I have to use http://github.com/ECP/three20 instead .
我从 Twitter 得到的答案 - “需要手动设置每个项目的构建目标”
他可能是对的。
An answer I got from twitter - "need to manually set build target of each projects"
He might be right.
我的解决方案是将以下内容添加到 Xcode 中的标头搜索路径:
Xcode 4 屏幕截图:
当然,您的可能会有所不同,但也许这个会帮助某人。
My solution was to add the following to the Header Search Path in Xcode:
Xcode 4 screen shot:
Yours may be different of course, but maybe this will help someone.
另外,尝试检查“项目设置”下的“模拟器”和“设备”的“部署目标”。就我而言,由于目标设置为 2.2,因此出现了数千个错误。 iOS 4.1 和 Xcode 3.2.4 似乎不再支持 2.2。
Also, try checking the Deployment Target under Project Settings, for both, Simulator and Device. In my case, I got thousands of errors because the target was set to 2.2. It seems there is no support for 2.2 anymore in iOS 4.1 and Xcode 3.2.4.