【问题标题】:Compiling Qt 5, getting warning "The build will most likely fail."编译 Qt 5,收到警告“构建很可能会失败。”
【发布时间】:2013-05-20 09:34:14
【问题描述】:

我正在关注this tutorial 在 Windows 上使用 Visual Studio 2008 作为编译器编译 Qt 5。

运行 configure.bat 时,我收到警告 - The build will most likely fail.

这是完整的命令:

configure -developer-build -opensource -nomake examples -nomake tests

这是 configure.bat 输出的摘录:

Running configuration tests...
WARNING: The DirectX SDK could not be detected:
  There is no Direct X SDK installed or the environment variable "DXSDK_DIR" is
not set.
Disabling the ANGLE backend.

WARNING: Using OpenGL ES 2.0 without ANGLE.
Specify -opengl desktop to use Open GL.
The build will most likely fail.

我应该怎么做才能避免这个警告?我应该指定-opengl,还是应该安装Direct X SDK?

编辑

构建(我运行 nmake)确实失败了,抱怨缺少 GLES2/gl2.h

c:\workspace\qt5source\qt5\qtbase\include\qtgui\../../src/gui/opengl/qopengl.h(82) : fatal error C1083: Cannot open include file: 'GLES2/gl2.h': No such file or directory

【问题讨论】:

  • 你想保持跨平台,还是只针对 Windows?
  • 我只针对 Windows。
  • 您的目标(和构建)系统是否支持完整的 OpenGL(即不支持 OpenGL ES)?
  • 我不知道。我只能说我正在使用 VS2008 工具链。不确定它是否支持完整的 OpenGL。
  • 这是硬件要求而不是软件要求,您的工具链将同时支持两者。你有什么显卡?如果您没有,您的处理器是否内置了一个?

标签: windows qt visual-studio-2008 build qt5


【解决方案1】:

OpenGL ES 是针对智能手机和平板电脑的 OpenGL 规范的精简版,ANGLE 提供将 OpenGL ES API 调用转换为 DirectX 等效项的能力。

除非您计划创建面向 OpenGL ES 平台 Windows 的应用程序,否则只需将 -opengl desktop 传递给 configure。否则,您需要获取 DirectX SDK 才能启用 ANGLE 支持。

【讨论】:

    猜你喜欢
    • 2023-03-13
    • 1970-01-01
    • 2012-02-29
    • 1970-01-01
    • 2014-12-19
    • 2017-08-20
    • 1970-01-01
    • 2015-11-06
    • 1970-01-01
    相关资源
    最近更新 更多