为 iOS 编译 Qt(UIKit 灯塔)第 2 部分 [英] Compiling Qt for iOS (UIKit lighthouse) part 2

查看:34
本文介绍了为 iOS 编译 Qt(UIKit 灯塔)第 2 部分的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试为 iOS 模拟器编译 Qt,如 这篇文章.

I'm trying to compile Qt for the iOS simulator, as explained in this article.

起初我遇到了这个问题但之后(有点)自己解决了我还有一些.

At first I ran into this problem but after it (kinda) solved itself I had some more.

首先,我在执行第一个命令后不断收到此错误,该命令应该构建 qmake (../qt/configure ... etc etc):

First I kept getting this error after executing the first command, which is supposed to build qmake (../qt/configure ... etc etc):

OpenGL ES 2.0 功能测试失败!您可能需要通过编辑/Qt/qt/mkspecs/qpa/macx-iphonesimulator-g++ 中的 QMAKE_INCDIR_OPENGL_ES2、QMAKE_LIBDIR_OPENGL_ES2 和 QMAKE_LIBS_OPENGL_ES2 来修改包含和库搜索路径.

既然知道自己有4.3 SDK,就深入研究了一下,分析了configure脚本,查了一下发现qmake生成的Makefile,需要g++-4.2(我没有),所以我只是 ln -s g++ g++-4.2ln -s gcc gcc-4.2/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/.

Since I knew that I had the 4.3 SDK, I delved into it some more, analyzed the configure script, and after some tracing I saw that the Makefile generated by qmake, required g++-4.2 (which I didn't have), so I just ln -s g++ g++-4.2 and ln -s gcc gcc-4.2 in /Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin/.

我不确定上述步骤是否重要,这就是我写这些步骤的原因.无论如何,配置步骤成功了.现在我运行 make.在一些成功编译的文件之后,我得到了这个:

I'm not sure if the aforementioned steps matter, that's why I'm writing about them. Anyway, with that, the configure step was successful. Now I ran make. After some successfully compiled files I got this:

In file included from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/WebServicesCore.framework/Headers/WebServicesCore.h:15,
from /Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk/System/Library/Frameworks/CoreServices.framework/Headers/CoreServices.h:37,
from ../../include/QtCore/private/../../../../qt/src/corelib/kernel/qcore_mac_p.h:83,
from ../../include/QtCore/private/qcore_mac_p.h:1,
from /Qt/qt/src/corelib/tools/qlocale_mac.mm:49:
/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator4.3.sdk/System/Library/Frameworks/CoreServices.framework/Frameworks/WebServicesCore.framework/Headers/WSMethodInvocation.h:759: 
error: 'CFXMLTreeRef' has not been declared

同样的错误在 WebServicesCore.h 的几个不同行中又出现了几次.所以,基本上,这就是我现在卡住的地方.

The same error appears several more times, from several different lines of WebServicesCore.h. So, basically, here's where I'm stuck now.

有什么帮助吗?又来了?...

Any help? Again?...

当然,当我配置并尝试为设备(而不是模拟器)制作 Qt 时,会发生 100% 相同的事情

Absolutely, 100% the same thing happens when I configure and try to make Qt for the device (as opposed to the simulator)

附加信息:

  • gcc --version : i686-apple-darwin11-llvm-gcc-4.2 (GCC) 4.2.1(基于 Apple Inc. build 5658)(LLVM build 2336.1.00)
  • iOS SDK:我有 4.3 和 5
  • OS X 版本:10.7.2
  • Xcode 版本(如果重要的话):4.2.1

推荐答案

你是不是忘记添加 -nomake tools 和其他 -nomake ... 到你的配置?

Didn't you forget to add -nomake tools and other -nomake ... to your configure ?

试试戳这些家伙:http://labs.qt.nokia.com/2011/08/09/update-on-uikit-lighthouse-platform/

这篇关于为 iOS 编译 Qt(UIKit 灯塔)第 2 部分的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆