Problem building with 6.2.4
-
I have been using the Qt open source for some time with no issues on a project using 5.15.2. Qt was originally set up with 5.12.5. When I recently switched to another project, it required adding 6.2.4, which I successfully added using Maintenance Tool.
When I went to build the new project I get several errors because it says QSslErrorPrivate is undefined. I Googled around and found nothing helpful. I looked through the includes and could not find its definition, so I asked colleagues if they had encountered this and what I should do.
No one had encountered anything like this. From their advice I have done the following:
- Uninstalled and reinstalled 6.2.4 several times using Maintenance Tool . Still same problem.
- Updated my Qt Creator to 10.0.1 using Maintenance Tool. (I am using MSVC 2019, x86_64 16.3.29409.12 amd64).
- Tried building the example program securesocketclient. With 6.2.4 I get a similar error with QSslCipherPrivate undefined. If I switch to 5.15.2 and build its securesocketclient example, it is successful.
- I went into C:/Qt/6.2.4, created a git repository and committed the entire directory. Then copied his files on top of mine. They were identical.
The only thing left that I have considered is to uninstall Qt Creator and reinstall it, but that makes me nervous.
Has anyone run into an issue like this or have a possible solution?
-
I have been using the Qt open source for some time with no issues on a project using 5.15.2. Qt was originally set up with 5.12.5. When I recently switched to another project, it required adding 6.2.4, which I successfully added using Maintenance Tool.
When I went to build the new project I get several errors because it says QSslErrorPrivate is undefined. I Googled around and found nothing helpful. I looked through the includes and could not find its definition, so I asked colleagues if they had encountered this and what I should do.
No one had encountered anything like this. From their advice I have done the following:
- Uninstalled and reinstalled 6.2.4 several times using Maintenance Tool . Still same problem.
- Updated my Qt Creator to 10.0.1 using Maintenance Tool. (I am using MSVC 2019, x86_64 16.3.29409.12 amd64).
- Tried building the example program securesocketclient. With 6.2.4 I get a similar error with QSslCipherPrivate undefined. If I switch to 5.15.2 and build its securesocketclient example, it is successful.
- I went into C:/Qt/6.2.4, created a git repository and committed the entire directory. Then copied his files on top of mine. They were identical.
The only thing left that I have considered is to uninstall Qt Creator and reinstall it, but that makes me nervous.
Has anyone run into an issue like this or have a possible solution?
@lcook99 said in Problem building with 6.2.4:
When I went to build the new project I get several errors because it says QSslErrorPrivate is undefined.
Please show the error message and compiler line which causes this error. Also make sure that you don't mix Qt5 and Qt6.
Also try to build a minimal Qt program instead your own to see if this is working.
-
When I build the securesocketclient example program I get the following error:
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory:1766: error: C2027: use of undefined type 'QSslCipherPrivate'
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory(1766): error C2027: use of undefined type 'QSslCipherPrivate'
C:\Qt\6.2.4\msvc2019_64\include\QtNetwork\qsslcipher.h(56): note: see declaration of 'QSslCipherPrivate'
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory(1765): note: while compiling class template member function 'void std::default_delete<_Ty>::operator ()(_Ty *) noexcept const'
with
[
_Ty=QSslCipherPrivate
]
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory(1875): note: see reference to function template instantiation 'void std::default_delete<_Ty>::operator ()(_Ty ) noexcept const' being compiled
with
[
_Ty=QSslCipherPrivate
]
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory(1804): note: see reference to class template instantiation 'std::default_delete<_Ty>' being compiled
with
[
_Ty=QSslCipherPrivate
]
C:\Qt\6.2.4\msvc2019_64\include\QtNetwork\qsslcipher.h(87): note: see reference to class template instantiation 'std::unique_ptr<QSslCipherPrivate,std::default_delete<_Ty>>' being compiled
with
[
_Ty=QSslCipherPrivate
]
C:\Qt\6.2.4\msvc2019_64\include\QtCore/qmetatype.h(2169): note: see reference to class template instantiation 'std::array<char,28>' being compiled
C:\Qt\6.2.4\msvc2019_64\include\QtNetwork\qnetworkreply.h(197): note: see reference to function template instantiation 'std::array<char,28> QtPrivate::typenameHelperQNetworkReply::NetworkError(void)' being compiled
C:\Qt\6.2.4\msvc2019_64\include\QtCore/qmetatype.h(2169): note: see reference to class template instantiation 'std::array<char,21>' being compiled
C:\Qt\6.2.4\msvc2019_64\include\QtNetwork\qnetworkinterface.h(185): note: see reference to function template instantiation 'std::array<char,21> QtPrivate::typenameHelper<QNetworkAddressEntry>(void)' being compiled
C:\Qt\6.2.4\msvc2019_64\include\QtCore/qmetatype.h(2169): note: see reference to class template instantiation 'std::array<char,31>' being compiled
C:\Qt\6.2.4\msvc2019_64\include\QtNetwork\qsslpresharedkeyauthenticator.h(94): note: see reference to function template instantiation 'std::array<char,31> QtPrivate::typenameHelper<QSslPreSharedKeyAuthenticator>(void)' being compiled
C:\Qt\6.2.4\msvc2019_64\include\QtCore/qmetatype.h(2378): note: see reference to class template instantiation 'std::array<char,30>' being compiled
C:\Qt\6.2.4\msvc2019_64\include\QtCore/qmetatype.h(1587): note: see reference to class template instantiation 'std::array<char,9>' being compiledThe main difference between this error and the one I get in our project is that our project cannot find QSslErrorPrivate instead of QSslCipherPrivate. Otherwise, they are the same.
Both the example and our project are using Desktop Qt 6.2.4 MSVC2019 64bit kit.
-
When I build our project the error I get is:
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory:1766: error: C2027: use of undefined type 'QSslErrorPrivate'
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory(1766): error C2027: use of undefined type 'QSslErrorPrivate'
C:\Qt\6.2.4\msvc2019_64\include\QtNetwork/qsslerror.h(55): note: see declaration of 'QSslErrorPrivate'
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory(1765): note: while compiling class template member function 'void std::default_delete<_Ty>::operator ()(_Ty *) noexcept const'
with
[
_Ty=QSslErrorPrivate
]
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory(1875): note: see reference to function template instantiation 'void std::default_delete<_Ty>::operator ()(_Ty *) noexcept const' being compiled
with
[
_Ty=QSslErrorPrivate
]
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory(1804): note: see reference to class template instantiation 'std::default_delete<_Ty>' being compiled
with
[
_Ty=QSslErrorPrivate
] -
When I build our project the error I get is:
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory:1766: error: C2027: use of undefined type 'QSslErrorPrivate'
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory(1766): error C2027: use of undefined type 'QSslErrorPrivate'
C:\Qt\6.2.4\msvc2019_64\include\QtNetwork/qsslerror.h(55): note: see declaration of 'QSslErrorPrivate'
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory(1765): note: while compiling class template member function 'void std::default_delete<_Ty>::operator ()(_Ty *) noexcept const'
with
[
_Ty=QSslErrorPrivate
]
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory(1875): note: see reference to function template instantiation 'void std::default_delete<_Ty>::operator ()(_Ty *) noexcept const' being compiled
with
[
_Ty=QSslErrorPrivate
]
C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC\Tools\MSVC\14.23.28105\include\memory(1804): note: see reference to class template instantiation 'std::default_delete<_Ty>' being compiled
with
[
_Ty=QSslErrorPrivate
]It's a compiler bug: https://bugreports.qt.io/browse/QTBUG-97999
-
It's a compiler bug: https://bugreports.qt.io/browse/QTBUG-97999
@Christian-Ehrlicher Updated to latest compiler and everything builds now.
Thank you very much.
-
@Christian-Ehrlicher Updated to latest compiler and everything builds now.
Thank you very much.
@lcook99 Then please mark this topic as solved. Thx.
-