Qt 5.2 VS2010 - ‘GLES2/gl2.h’: No such file or directory
-
wrote on 20 Dec 2013, 13:14 last edited by
bq. fatal error C1083: Cannot open include file: ‘GLES2/gl2.h’: No such file or directory
This is the error I get after trying to use QFileDialog.
Well I got some other QFileDialog unidentified errors first, but adding...
@#include <QtGUI>
#include <QFileDialog>@
...took care of them.But now I have the above.
The file is present in this folder...
C:\Qt\Qt5.2.0\5.2.0\msvc2010\include\QtANGLE\GLES2
Which I have in my include directorie path, as well as just...
C:\Qt\Qt5.2.0\5.2.0\msvc2010\include\QtANGLEThe error comes from qopengl.h and is line 82...
@# include <GLES2/gl2.h>@Any ideas on my mistake, and what I should try?
-
Hi,
Since you are building with ANGLE, did you install the Direct X sdk ?
-
wrote on 20 Dec 2013, 13:24 last edited by
I did not, I was unaware I needed it.
Thought I only needed that if I was compiling Qt sources.I'd appreciate any advice or links you might offer.
-
Indeed, sorry, I misunderstood your original post.
You should not have this problem then
As a workaround you can add
@$(QTDIR)\include\QtANGLE@
To your pro file
-
wrote on 20 Dec 2013, 13:38 last edited by
I'll try that, thanks.
First though, I'll have to figure out how to make a .pro file because there is not one (that I can see( in my solution explorer.
Thanks for the tip, I appreciate it.
-
wrote on 20 Dec 2013, 13:45 last edited by
From the Qt5 menu in VS I selected "create basic .pro file"
But something looks awry about the generated file.
@# ----------------------------------------------------
This file is generated by the Qt Visual Studio Add-in.
------------------------------------------------------
TEMPLATE = app
TARGET = QTGUIHELLOWORLD
DESTDIR = ../Win32/Debug
QT += core widgets gui
CONFIG += debug
DEFINES += WIN64 QT_DLL QT_WIDGETS_LIB
INCLUDEPATH += ./GeneratedFiles
.
./GeneratedFiles/Debug
DEPENDPATH += .
MOC_DIR += ./GeneratedFiles/debug
OBJECTS_DIR += debug
UI_DIR += ./GeneratedFiles
RCC_DIR += ./GeneratedFiles
include(QTGUIHELLOWORLD.pri)@Most notably, the line "DEFINES += WIN64 QT_DLL QT_WIDGETS_LIB"
I'm very new to Qt but I definitely not using a 64bit windows, however my CPU (AMD) is 64 bit.
-
wrote on 20 Dec 2013, 14:46 last edited by
If I add this to my existing .pro
INCLUDEPATH += "C:/Qt/Qt5.2.0/5.2.0/msvc2010/include/QtANGLE/GLES2/gl2.h"
Intellisense still tells me it cannot find it, and my project will not compile.
If I add #include "C:/Qt/Qt5.2.0/5.2.0/msvc2010/include/QtANGLE/GLES2/gl2.h" to any of my project files, intellisense is happy, but project still will not compile because of same errors as above.
-
wrote on 20 Dec 2013, 18:28 last edited by
New info:
If I use QFileDialog in Qt Creator, everything is just fine, and it compiles and runs.
I'm sure though that it's still using the VS 2010 compiler.
-
wrote on 20 Dec 2013, 19:36 last edited by
Does this look correct, what I've added to vc++ directories -> include directories?...
"$(QTDIR)msvc2010\include\QtANGLE"
-
wrote on 20 Dec 2013, 20:01 last edited by
I downloaded and installed
Qt 5.2.0 for Windows 32-bit (VS 2010, 570 MB) (Info)If I get rid of that and get
Qt 5.2.0 for Windows 32-bit (VS 2010, OpenGL, 569 MB) (Info)
Instead, do you think this error will go away? -
The OpenGL build will indeed not use ANGLE
-
wrote on 20 Dec 2013, 22:25 last edited by
Thanks, I'll keep it in mind if I cannot find the solution, to whatever it is I'm doing wrong.
-
wrote on 28 Feb 2014, 09:25 last edited by
Not sure if you still have the problem, but I had the same issue.
Simple do not include QtGui and everything works fine!
-
wrote on 22 Dec 2014, 12:26 last edited by
Adding $(QTDIR)\include\QtANGLE to Project Properties->C++->General->Additional Include Directories has solved the problem for me.
-
wrote on 22 Dec 2014, 12:26 last edited by
Adding $(QTDIR)\include\QtANGLE to Project Properties->C++->General->Additional Include Directories has solved the problem for me.