在 QtCreator 中使用 QtMobility:设置?
我正在尝试建立一个开发环境来为 Symbian 设备开发 Qt 应用程序。我已经成功设置了环境,并且能够创建简单的应用程序(例如 HelloWorld)并让它们在我的设备上运行。我现在想尝试使用 QtMobility 包,但我很难让它在 QtCreator 中工作。
我得到了一些使用相机的示例代码(最初我只有 QtMobility 1.0.2,但现在我已经下载了 1.1.0 技术预览版)。我按照帮助文件中的说明安装它,这就是我所做的:
Extracted the zip file to C:\QtMobility
Opened a Qt Command prompt and ran configure (in the QtMobility directory)
Ran mingw32-make
Ran mingw32-make install
Finally I updated my PATH variable to include C:\QtMobility\lib
我回到 QtCreator(重新启动它)并查看首先调用宏 QTM_USE_NAMESPACE
的 cpp 文件,但它仍然是用红色下划线表示,因为它找不到 qmobilityglobal.h
文件。
有谁知道我在安装过程中是否遗漏了任何东西,可以告诉 QtCreator 在哪里可以找到 QtMobility 头文件?
I am trying to set up a development environment to play around with developing Qt apps for Symbian devices. I have succesfully set up the environment and am able to create simple apps such as HelloWorld and get them to run on my device. I would now like to try using the QtMobility package, but I am struggling to get it to work in QtCreator.
I got some sample code for using the camera (initially I only had QtMobility 1.0.2, but I have now downloaded the 1.1.0 technology preview version). I followed the instructions in the help file to install it, here is what I did:
Extracted the zip file to C:\QtMobility
Opened a Qt Command prompt and ran configure (in the QtMobility directory)
Ran mingw32-make
Ran mingw32-make install
Finally I updated my PATH variable to include C:\QtMobility\lib
I went back to QtCreator (restarted it) and looked at the cpp file that first calls the macro QTM_USE_NAMESPACE
but it is still underlined in red, because it can't find the qmobilityglobal.h
file.
Does anyone know if I have missed anything out during the installation that will tell the QtCreator where to find the QtMobility header files?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
mingw32-make
建议您正在构建win32-mingw
目标环境。要使用 Symbian SDK,您应该构建例如symbian-abld
。configure.bat
脚本将自动检测您正在构建的目标。只需确保QT_PATH
环境变量指向您拥有 Qt 工具链的 Symbian 版本的位置。(另请注意,对于
symbian-abld
来说,make install
是不必要的 - 构建步骤已将所有内容放在 Symbian SDK 目录中。)mingw32-make
suggests you're building forwin32-mingw
target environment. To work with Symbian SDKs, you should be building for e.g.symbian-abld
instead. Theconfigure.bat
script will auto-detect the target you are building for. Just make sure thatQT_PATH
environment variable points to a location where you have a Symbian build of the Qt toolchain.(Also note that
make install
is unnecessary withsymbian-abld
- the build step already puts everything in place in Symbian SDK directories.)