Making a standalone Qt application on Windows
-
I ran the configure again in the same folder I ran it as first, and I got a message that I could actually build it now. So I ran it, and while it was building, it gave me an error:
In file included from declarativemaps\qdeclarativepolylinemapitem.cpp:38: declarativemaps\qdeclarativepolylinemapitem_p_p.h:381:17: error: 'const char* MapPolylineShaderLineStrip::vertexShader() const' marked 'override', but does not override const char *vertexShader() const override { ^~~~~~~~~~~~ declarativemaps\qdeclarativepolylinemapitem_p_p.h:397:17: error: 'const char* MapPolylineShaderLineStrip::fragmentShader() const' marked 'override', but does not override const char *fragmentShader() const override { ^~~~~~~~~~~~~~ declarativemaps\qdeclarativepolylinemapitem_p_p.h: In member function 'virtual void MapPolylineShaderLineStrip::initialize()': declarativemaps\qdeclarativepolylinemapitem_p_p.h:411:23: error: 'program' was not declared in this scope m_matrix_id = program()->uniformLocation("qt_Matrix"); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem_p_p.h: At global scope: declarativemaps\qdeclarativepolylinemapitem_p_p.h:435:17: error: 'const char* MapPolylineShaderExtruded::vertexShader() const' marked 'override', but does not override const char *vertexShader() const override ^~~~~~~~~~~~ declarativemaps\qdeclarativepolylinemapitem_p_p.h:440:17: error: 'const char* MapPolylineShaderExtruded::fragmentShader() const' marked 'override', but does not override const char *fragmentShader() const override ^~~~~~~~~~~~~~ declarativemaps\qdeclarativepolylinemapitem_p_p.h: In member function 'virtual void MapPolylineShaderExtruded::initialize()': declarativemaps\qdeclarativepolylinemapitem_p_p.h:455:23: error: 'program' was not declared in this scope m_matrix_id = program()->uniformLocation("qt_Matrix"); ^~~~~~~ In file included from ..\..\include\QtLocation\5.15.2/QtLocation/private/qdeclarativepolygonmapitem_p_p.h:1, from declarativemaps\qdeclarativerectanglemapitem_p_p.h:53, from declarativemaps\qdeclarativepolylinemapitem.cpp:39: C:/Qt/5.15.2-static/qtlocation/src/location/declarativemaps/qdeclarativepolygonmapitem_p_p.h: At global scope: C:/Qt/5.15.2-static/qtlocation/src/location/declarativemaps/qdeclarativepolygonmapitem_p_p.h:152:17: error: 'const char* MapPolygonShader::vertexShader() const' marked 'override', but does not override const char *vertexShader() const override { ^~~~~~~~~~~~ C:/Qt/5.15.2-static/qtlocation/src/location/declarativemaps/qdeclarativepolygonmapitem_p_p.h:168:17: error: 'const char* MapPolygonShader::fragmentShader() const' marked 'override', but does not override const char *fragmentShader() const override { ^~~~~~~~~~~~~~ C:/Qt/5.15.2-static/qtlocation/src/location/declarativemaps/qdeclarativepolygonmapitem_p_p.h: In member function 'virtual void MapPolygonShader::initialize()': C:/Qt/5.15.2-static/qtlocation/src/location/declarativemaps/qdeclarativepolygonmapitem_p_p.h:186:23: error: 'program' was not declared in this scope m_matrix_id = program()->uniformLocation("qt_Matrix"); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem.cpp: In member function 'virtual void MapPolylineShaderLineStrip::updateState(const QSGMaterialShader::RenderState&, QSGMaterial*, QSGMaterial*)': declarativemaps\qdeclarativepolylinemapitem.cpp:1552:9: error: 'program' was not declared in this scope program()->setUniformValue(m_color_id, v); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem.cpp:1557:9: error: 'program' was not declared in this scope program()->setUniformValue(m_matrix_id, state.projectionMatrix()); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem.cpp:1560:5: error: 'program' was not declared in this scope program()->setUniformValue(m_mapProjection_id, geoProjection); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem.cpp: In member function 'virtual void MapPolylineShaderExtruded::updateState(const QSGMaterialShader::RenderState&, QSGMaterial*, QSGMaterial*)': declarativemaps\qdeclarativepolylinemapitem.cpp:1768:9: error: 'program' was not declared in this scope program()->setUniformValue(m_color_id, v); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem.cpp:1773:9: error: 'program' was not declared in this scope program()->setUniformValue(m_matrix_id, state.projectionMatrix()); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem.cpp:1777:5: error: 'program' was not declared in this scope program()->setUniformValue(m_mapProjection_id, geoProjection); ^~~~~~~ mingw32-make[4]: *** [Makefile.Release:35989: .obj/release/qdeclarativepolylinemapitem.o] Error 1 mingw32-make[4]: Leaving directory 'C:/Qt/5.15.2-static/qtlocation/src/location' mingw32-make[3]: *** [Makefile:49: release-all] Error 2 mingw32-make[3]: Leaving directory 'C:/Qt/5.15.2-static/qtlocation/src/location' mingw32-make[2]: *** [Makefile:184: sub-location-make_first] Error 2 mingw32-make[2]: Leaving directory 'C:/Qt/5.15.2-static/qtlocation/src' mingw32-make[1]: *** [Makefile:52: sub-src-make_first] Error 2 mingw32-make[1]: Leaving directory 'C:/Qt/5.15.2-static/qtlocation' mingw32-make: *** [Makefile:819: module-qtlocation-make_first] Error 2I didn't think much of it, and ran "mingw32-make install", but I got another error:
In file included from declarativemaps\qdeclarativepolylinemapitem.cpp:38: declarativemaps\qdeclarativepolylinemapitem_p_p.h:381:17: error: 'const char* MapPolylineShaderLineStrip::vertexShader() const' marked 'override', but does not override const char *vertexShader() const override { ^~~~~~~~~~~~ declarativemaps\qdeclarativepolylinemapitem_p_p.h:397:17: error: 'const char* MapPolylineShaderLineStrip::fragmentShader() const' marked 'override', but does not override const char *fragmentShader() const override { ^~~~~~~~~~~~~~ declarativemaps\qdeclarativepolylinemapitem_p_p.h: In member function 'virtual void MapPolylineShaderLineStrip::initialize()': declarativemaps\qdeclarativepolylinemapitem_p_p.h:411:23: error: 'program' was not declared in this scope m_matrix_id = program()->uniformLocation("qt_Matrix"); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem_p_p.h: At global scope: declarativemaps\qdeclarativepolylinemapitem_p_p.h:435:17: error: 'const char* MapPolylineShaderExtruded::vertexShader() const' marked 'override', but does not override const char *vertexShader() const override ^~~~~~~~~~~~ declarativemaps\qdeclarativepolylinemapitem_p_p.h:440:17: error: 'const char* MapPolylineShaderExtruded::fragmentShader() const' marked 'override', but does not override const char *fragmentShader() const override ^~~~~~~~~~~~~~ declarativemaps\qdeclarativepolylinemapitem_p_p.h: In member function 'virtual void MapPolylineShaderExtruded::initialize()': declarativemaps\qdeclarativepolylinemapitem_p_p.h:455:23: error: 'program' was not declared in this scope m_matrix_id = program()->uniformLocation("qt_Matrix"); ^~~~~~~ In file included from ..\..\include\QtLocation\5.15.2/QtLocation/private/qdeclarativepolygonmapitem_p_p.h:1, from declarativemaps\qdeclarativerectanglemapitem_p_p.h:53, from declarativemaps\qdeclarativepolylinemapitem.cpp:39: C:/Qt/5.15.2-static/qtlocation/src/location/declarativemaps/qdeclarativepolygonmapitem_p_p.h: At global scope: C:/Qt/5.15.2-static/qtlocation/src/location/declarativemaps/qdeclarativepolygonmapitem_p_p.h:152:17: error: 'const char* MapPolygonShader::vertexShader() const' marked 'override', but does not override const char *vertexShader() const override { ^~~~~~~~~~~~ C:/Qt/5.15.2-static/qtlocation/src/location/declarativemaps/qdeclarativepolygonmapitem_p_p.h:168:17: error: 'const char* MapPolygonShader::fragmentShader() const' marked 'override', but does not override const char *fragmentShader() const override { ^~~~~~~~~~~~~~ C:/Qt/5.15.2-static/qtlocation/src/location/declarativemaps/qdeclarativepolygonmapitem_p_p.h: In member function 'virtual void MapPolygonShader::initialize()': C:/Qt/5.15.2-static/qtlocation/src/location/declarativemaps/qdeclarativepolygonmapitem_p_p.h:186:23: error: 'program' was not declared in this scope m_matrix_id = program()->uniformLocation("qt_Matrix"); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem.cpp: In member function 'virtual void MapPolylineShaderLineStrip::updateState(const QSGMaterialShader::RenderState&, QSGMaterial*, QSGMaterial*)': declarativemaps\qdeclarativepolylinemapitem.cpp:1552:9: error: 'program' was not declared in this scope program()->setUniformValue(m_color_id, v); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem.cpp:1557:9: error: 'program' was not declared in this scope program()->setUniformValue(m_matrix_id, state.projectionMatrix()); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem.cpp:1560:5: error: 'program' was not declared in this scope program()->setUniformValue(m_mapProjection_id, geoProjection); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem.cpp: In member function 'virtual void MapPolylineShaderExtruded::updateState(const QSGMaterialShader::RenderState&, QSGMaterial*, QSGMaterial*)': declarativemaps\qdeclarativepolylinemapitem.cpp:1768:9: error: 'program' was not declared in this scope program()->setUniformValue(m_color_id, v); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem.cpp:1773:9: error: 'program' was not declared in this scope program()->setUniformValue(m_matrix_id, state.projectionMatrix()); ^~~~~~~ declarativemaps\qdeclarativepolylinemapitem.cpp:1777:5: error: 'program' was not declared in this scope program()->setUniformValue(m_mapProjection_id, geoProjection); ^~~~~~~ mingw32-make[4]: *** [Makefile.Release:35989: .obj/release/qdeclarativepolylinemapitem.o] Error 1 mingw32-make[4]: Leaving directory 'C:/Qt/5.15.2-static/qtlocation/src/location' mingw32-make[3]: *** [Makefile:74: release-debug-install] Error 2 mingw32-make[3]: Leaving directory 'C:/Qt/5.15.2-static/qtlocation/src/location' mingw32-make[2]: *** [Makefile:196: sub-location-install_subtargets] Error 2 mingw32-make[2]: Leaving directory 'C:/Qt/5.15.2-static/qtlocation/src' mingw32-make[1]: *** [Makefile:64: sub-src-install_subtargets] Error 2 mingw32-make[1]: Leaving directory 'C:/Qt/5.15.2-static/qtlocation' mingw32-make: *** [Makefile:831: module-qtlocation-install_subtargets] Error 2EDIT: And I also didn't add "-j 4" when I executed the "mingw32-make" command.
-
Where did you get Qt's sources from ?
-
Your error looks odd.
I would nuke that build and extract the sources again.
Also, please use an out of source build so you don't pollute the source tree and can restart more easily.
-
Your error looks odd.
I would nuke that build and extract the sources again.
Also, please use an out of source build so you don't pollute the source tree and can restart more easily.
-
Literally what is written: call configure from a folder outside of the sources.
-
@SGaist ok, but how do I call configure from a folder that doesn't have the configure.bat file?
@Sucharek said in Making a standalone Qt application on Windows:
but how do I call configure from a folder that doesn't have the configure.bat file?
By providing path to it? Either relative to your build folder or absolute path:
../QT_SRC_FOLDER/configure -
@Sucharek said in Making a standalone Qt application on Windows:
but how do I call configure from a folder that doesn't have the configure.bat file?
By providing path to it? Either relative to your build folder or absolute path:
../QT_SRC_FOLDER/configure -
Hi, so I built it again, and got the same error. The error is from QLocation, to on configure can I use "-nomake qlocation", or something like that? Also, the build takes about 10 hours, so that's why I'm responding after a very long time.
-
Hi @jsulm, ok I'll try that. Also, I ran the mingw32-make with -i (ignore errors), and it just ignored the qlocation errors, and don't see any more of them. I don't need QLocation, so it's fine if I don't have it. If it wouldn't work, I'll try the -configure myself to see if I can clear some more thing out. After the compile is done, I'll update you if I have any more issues.
-
Hi, so I ran the installation with my own command, which took about 40 hours, installed it, but got the same error in Qt Creator. No QML utility installed. Do I need to run something else, not "mingw32-make install"?
@Sucharek said in Making a standalone Qt application on Windows:
No QML utility installed
I don't know what QML utility. Does it work? I mean: can you build your apps using this Qt installation?
-
@Sucharek said in Making a standalone Qt application on Windows:
No QML utility installed
I don't know what QML utility. Does it work? I mean: can you build your apps using this Qt installation?
-
Hi, I've discovered a new thing. So when I initialize the static Qt version in Qt Creator, it still says "No QML utility installed", but when I add it as a kit, it works, builds, but it's not static. It needs the dlls. I don't know if it's the QML thing or something. Here's the config command I used:
C:\Qt\pre-static\configure -release -opensource -static -skip qt3d -skip qtdatavis3d -skip qtgamepad -skip qtcharts -skip qtlocation -skip qtlottie -skip qtmacextras -skip qtandroidextras -skip qtnetworkauth -skip qtpurchasing -skip qtquick3d -skip qtspeech -skip qttranslations -skip qtvirtualkeyboard -skip qtwebengine -skip qtwebglplugin -skip qtwebchannel -skip qtwebsockets -skip qtwebview -skip qtconnectivity -nomake examples -nomake tests -nomake tools -accessibility -platform win32-g++ -confirm-license -opengl desktop -prefix C:\Qt\5.15.2-static