Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-63210

'uses undefined class ...' and 'unexpected token(s) preceding ...' errors for MSVC builds on Windows

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 5.9.3, 5.10.0 Beta 3
    • 5.11
    • qtbase: 5ec02f7792e97208c0f621c9e8a16854168022e3 qtconnectivity: 6029bad7d1007aecd155985ba13d6c23a01015b8

    Description

      Hello everyone,

      Got errors for builds using MSVC:

              cd bluetooth\ && ( if not exist Makefile c:\libQT-5.10-dev\build\qtbase\bin\qmake.exe -o Makefile c:\libQT-5.10-dev\build\qtconnectivity\src\bluetooth\bluetooth.pro ) && "C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\VC\Tools\MSVC\14.11.25503\bin\HostX64\x64\nmake.exe" -f Makefile
      
      Microsoft (R) Program Maintenance Utility Version 14.11.25507.1
      Copyright (C) Microsoft Corporation.  All rights reserved.
      
              "C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\VC\Tools\MSVC\14.11.25503\bin\HostX64\x64\nmake.exe" -f Makefile.Release
      
      Microsoft (R) Program Maintenance Utility Version 14.11.25507.1
      Copyright (C) Microsoft Corporation.  All rights reserved.
      
              cl -c -nologo -Zc:wchar_t -FS -Zc:rvalueCast -Zc:inline -Zc:strictStrings -Zc:throwingNew -Zc:referenceBinding -O2 -MD -utf-8 -D_HAS_EXCEPTIONS=0 -W3 -w34100 -w34189 -w44996 -w44456 -w44457 -w44458 -wd4577 -wd4467 -DUNICODE -D_UNICODE -DWIN32 -DWIN64 -DQT_WINRT_BLUETOOTH -DCLASSIC_APP_BUILD -DQT_NO_NARROWING_CONVERSIONS_IN_CONNECT -DQT_BUILD_BLUETOOTH_LIB -DQT_BUILDING_QT -D_CRT_SECURE_NO_WARNINGS -D_USE_MATH_DEFINES -DQT_NO_CAST_TO_ASCII -DQT_ASCII_CAST_WARNINGS -DQT_MOC_COMPAT -DQT_USE_QSTRINGBUILDER -DQT_DEPRECATED_WARNINGS -DQT_DISABLE_DEPRECATED_BEFORE=0x040800 -DQT_NO_EXCEPTIONS -DQT_NO_DEBUG -DQT_CORE_LIB -DNDEBUG -D_WINDLL -I. -I..\..\include -I..\..\include\QtBluetooth -I..\..\include\QtBluetooth\5.11.0 -I..\..\include\QtBluetooth\5.11.0\QtBluetooth -Itmp -Ic:\libQT-5.10-dev\build\qtbase\include\QtCore\5.11.0 -Ic:\libQT-5.10-dev\build\qtbase\include\QtCore\5.11.0\QtCore -Ic:\libQT-5.10-dev\build\qtbase\include -Ic:\libQT-5.10-dev\build\qtbase\include\QtCore -I.moc\release -Ic:\libQT-5.10-dev\build\qtbase\mkspecs\win32-msvc -Fo.obj\release\ @C:\Users\test\AppData\Local\Temp\nmE282.tmp
      qbluetoothdevicediscoveryagent.cpp
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothdevicediscoveryagent_p.h(169): error C2079: 'QBluetoothDeviceDiscoveryAgentPrivate::worker' uses undefined class 'QPointer<QWinRTBluetoothDeviceDiscoveryWorker>'
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothdevicediscoveryagent_p.h(170): error C2143: syntax error: missing ';' before '*'
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothdevicediscoveryagent_p.h(170): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothdevicediscoveryagent_p.h(170): error C2238: unexpected token(s) preceding ';'
      qbluetoothservicediscoveryagent.cpp
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothservicediscoveryagent_p.h(207): error C2079: 'QBluetoothServiceDiscoveryAgentPrivate::worker' uses undefined class 'QPointer<QWinRTBluetoothServiceDiscoveryWorker>'
      qbluetoothsocket.cpp
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothsocket_p.h(223): error C3646: 'm_readMutex': unknown override specifier
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothsocket_p.h(223): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
      qbluetoothserver.cpp
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothserver_p.h(126): error C3646: 'pendingConnectionsMutex': unknown override specifier
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothserver_p.h(126): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
      qbluetoothlocaldevice.cpp
      qbluetoothtransfermanager.cpp
      qbluetoothtransferreply.cpp
      qbluetoothdevicediscoveryagent_winrt.cpp
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothdevicediscoveryagent_p.h(169): error C2079: 'QBluetoothDeviceDiscoveryAgentPrivate::worker' uses undefined class 'QPointer<QWinRTBluetoothDeviceDiscoveryWorker>'
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothdevicediscoveryagent_p.h(170): error C2143: syntax error: missing ';' before '*'
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothdevicediscoveryagent_p.h(170): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
      c:\libqt-5.10-dev\build\qtconnectivity\src\bluetooth\qbluetoothdevicediscoveryagent_p.h(170): error C2238: unexpected token(s) preceding ';'
      .\qbluetoothdevicediscoveryagent_winrt.cpp(531): error C2614: 'QBluetoothDeviceDiscoveryAgentPrivate': illegal member initialization: 'leScanTimer' is not a base or member
      .\qbluetoothdevicediscoveryagent_winrt.cpp(531): fatal error C1903: unable to recover from previous error(s); stopping compilation
      Internal Compiler Error in C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\VC\Tools\MSVC\14.11.25503\bin\HostX64\x64\cl.EXE.  You will be prompted to send an error report to Microsoft later.
      NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\VC\Tools\MSVC\14.11.25503\bin\HostX64\x64\cl.EXE"' : return code '0x1'
      Stop.
      NMAKE : fatal error U1077: '"C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise\VC\Tools\MSVC\14.11.25503\bin\HostX64\x64\nmake.exe"' : return code '0x2'
      Stop.
      NMAKE : fatal error U1077: 'cd' : return code '0x2'
      Stop.
      NMAKE : fatal error U1077: 'cd' : return code '0x2'
      Stop.

      which relate to Change #201345.

       

      Reproduced for:
        - Qt5-dev builds using MSVC with -no-pch key,

      not reproduced for:
        - Qt5-dev builds using MSVC with -pch key OR reverted Change #201345,
        - Qt5-dev builds using mingw-w64 and ICC on Windows.

       

       

      Best,

      Alexander

       

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            owolff Oliver Wolff
            sav sav
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes