Qt示例名为Boxes在Ubuntu上工作但不在Windows上(Qt 5.0.2)

问题描述:

我一直在寻找跨平台的GUI应用程序开发框架(用于构建Linux,Android,Windows应用程序和OS X的相同代码),我发现Qt是最好的(灵感来自VLC媒体播放器是用Qt构建的)。Qt示例名为Boxes在Ubuntu上工作但不在Windows上(Qt 5.0.2)

首先在Ubuntu中安装它我在构建示例时遇到了一些问题,但是我设法解决了这个问题,并且Qt中给出的每个示例都工作正常。

但是在Windows中,除了“Boxes”示例以外,每个示例都在工作。 enter image description here

问题:

warning: Qt was built with ANGLE, which provides only OpenGL ES 2.0 on top of DirectX 9.0c 
error: This example requires Qt to be configured with -opengl desktop 

安装的Qt 5.0.2适用于Windows 32位(VS 2010,OpenGL中,476 MB)后

error: Qt Creator needs a compiler set up to build. Configure a compiler in the kit options. 

所以,我检查了构建&运行选项,它显示 enter image description here

+0

您应该向Qt项目提交错误报告。 – rubenvb 2013-05-07 09:16:11

问题解决后:

  1. 微软的Visual Studio 2010
  2. 的Qt 5.0.2适用于Windows 32位(VS 2010,OpenGL中,476 MB)

但是,Qt的单独运行程序的形式当我打开编译EXE文件它的工作原理显示Qt5***.dll缺失。

解决缺少DLL:

打开编译Dependency Walkerexe,它会显示所有缺少DLL。现在去 \Qt\Qt5.0.2\5.0.2\msvc2010_opengl\bin 那里我们可以找到所有的Qt5 ***。dll复制它,并在exe位置过去。

您需要使用opengl桌面选项构建qt。

http://qt-project.org/downloads

Qt 5.0.2 for Windows 32-bit (VS 2010, OpenGL, 476 MB)

http://download.qt-project.org/official_releases/qt/5.0/5.0.2/qt-windows-opensource-5.0.2-msvc2010_32_opengl-x86-offline.exe.mirrorlist

安装此QT释放你的例子后,安装应工作

+0

正如你所说我安装了Qt 5.0.2的Windows 32位(VS 2010,OpenGL,476 MB),现在我得到了 ':-1:错误:Qt Creator需要一个编译器设置为构建。在工具包选项中配置一个编译器 – bkmagnetron 2013-05-07 15:34:56