Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. General talk
  3. Qt 6
  4. Error during building Qt6 + MSVC2019
Forum Updated to NodeBB v4.3 + New Features

Error during building Qt6 + MSVC2019

Scheduled Pinned Locked Moved Unsolved Qt 6
2 Posts 2 Posters 589 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • F Offline
    F Offline
    freedbrt
    wrote on last edited by
    #1

    I'm trying to build latest Qt6 dev build for windows.

    Configure summary:
    Building for: win32-msvc (x86_64, CPU features: sse sse2)
    Compiler: msvc 19.28.29336.0
    Windows 10

    and i've got next error, in this file, and in several others with the same error (in this module)

    FAILED: qtquickcontrols2/src/quicktemplates2/CMakeFiles/qtquicktemplates2plugin.dir/qtquicktemplates2plugin.cpp.obj
    C:\PROGRA~2\MICROS~2\2019\PROFES~1\VC\Tools\MSVC\1428~1.293\bin\Hostx86\x64\cl.exe  /nologo /TP -DQT_CORE_LIB -DQT_DEPRECATED_WARNINGS -DQT_DEPRECATED_WARNINGS_SINCE=0x060000 -DQT_DISABLE_DEPRECATED_BEFORE=0x040800 -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_NO_EXCEPTIONS -DQT_OPENGL_LIB -DQT_PLUGIN -DQT_QMLMODELS_LIB -DQT_QML_LIB -DQT_QUICKTEMPLATES2_LIB -DQT_QUICK_LIB -DUNICODE -DWIN32 -DWIN64 -D_CRT_SECURE_NO_WARNINGS -D_ENABLE_EXTENDED_ALIGNED_STORAGE -D_UNICODE -D_WIN64 -Dqtquicktemplates2plugin_EXPORTS -Iqtquickcontrols2\src\quicktemplates2\qtquicktemplates2plugin_autogen\include -Iqtquickcontrols2\src\quicktemplates2 -Iqtbase\include -Iqtbase\mkspecs\win32-msvc -Iqtbase\include\QtQml -Iqtbase\include\QtCore -Iqtbase\include\QtNetwork -Iqtbase\include\QtQuickTemplates2 -Iqtbase\include\QtGui -Iqtbase\include\QtQuick -Iqtbase\include\QtQmlModels -Iqtbase\include\QtOpenGL -Iqtbase\include\QtQuickTemplates2\6.2.0 -Iqtbase\include\QtQuickTemplates2\6.2.0\QtQuickTemplates2 -Iqtdeclarative\src\qmlmodels -Iqtbase\include\QtQmlModels\6.2.0 -Iqtbase\include\QtQmlModels\6.2.0\QtQmlModels -Iqtbase\src\corelib -Iqtbase\include\QtCore\6.2.0 -Iqtbase\include\QtCore\6.2.0\QtCore -Iqtdeclarative\src\qml -Iqtbase\include\QtQml\6.2.0 -Iqtbase\include\QtQml\6.2.0\QtQml /DWIN32 /D_WINDOWS /GR /Zi     /RTC1 -MDd /W3 /wd4530 /wd4577 /WX -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -Zc:externConstexpr -Zc:wchar_t -Zc:__cplusplus -permissive- -utf-8 -std:c++17 /showIncludes /Foqtquickcontrols2\src\quicktemplates2\CMakeFiles\qtquicktemplates2plugin.dir\qtquicktemplates2plugin.cpp.obj /Fdqtquickcontrols2\src\quicktemplates2\CMakeFiles\qtquicktemplates2plugin.dir\ /FS -c qtquickcontrols2\src\quicktemplates2\qtquicktemplates2plugin.cpp
    qtquickcontrols2\src\quicktemplates2\qtquicktemplates2plugin.cpp(87): error C2220: the following warning is treated as an error
    qtquickcontrols2\src\quicktemplates2\qtquicktemplates2plugin.cpp(87): warning C4138: '*/' found outside of comment
    

    This happened because there is a flag /WX, which means treat warnings as an error.
    At qtquickcontrols2\src\quicktemplates2\qtquicktemplates2plugin.cpp(87) line source code have next code:

    void QtQuickTemplates2Plugin::registerTypes(const char */*uri*/)
    

    And visual studio marks this as a warnings. Can please help me anyone, how can I fix this? How do disable /WX flag, or is there another way out?

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      As a workaround you can either uncomment the parameter name or just remove it.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt Extensions
      • Unsolved