[SOLVED] How to compile QT examples with QT creator and visual studio 2012 compiler
ArMD last edited by ArMD
I used the following configure options and commands to build qt5.5:
configure -developer-build -opensource -confirm-license -platform win32-msvc2013 -opengl desktop -nomake examples -nomake tests
QT is built successfully. After this, I installed QT creator 3.4.0 beta and configured qmake for qt5.5 and using Microsoft Visual studio C++ compiler 12.0 . Now when i try to build the qt3D examples using the QT creator, I am getting the following compile errors:
qtmain.lib(qtmain_win.obj) : error LNK2019: unresolved external symbol __imp__CommandLineToArgvW@8 referenced in function _WinMain@16
release\cylinder-cpp.exe : fatal error LNK1120: 1 unresolved externals
jom: C:\qt5.5\build-qt3d-Desktop-Release\examples\cylinder-cpp\Makefile.Release [release\cylinder-cpp.exe] Error 1120
jom: C:\qt5.5\build-qt3d-Desktop-Release\examples\cylinder-cpp\Makefile [release] Error 2
12:57:27: The process "C:\Qt\qtcreator-3.3.81\bin\jom.exe" exited with code 2.
Error while building/deploying project qt3d (kit: Desktop)
When executing step "Make"
12:57:27: Elapsed time: 00:03.
I understand that this error is because of winmain function missing which is required by visual studio compiler for any windows applications, However how does qt take care of it? What are the header files to be included to avoid this error for qt examples?
Please help me with your suggstions and let me know if I am missing any steps also.
ArMD last edited by
I was able to resolve this problem. The issue was, I had run "nmake install" instead of "nmake".
refer to : https://bugreports.qt.io/browse/QTBUG-44862.