QT_VERSION_STR для старых версий Qt

This commit is contained in:
Andrei Astafev 2024-04-08 22:38:24 +03:00
parent 4adeb9ab23
commit 361d78b1cc

View File

@ -11,9 +11,11 @@ int main( int argc, char** argv )
{ {
QCoreApplication app( argc, argv ); QCoreApplication app( argc, argv );
qDebug() << QString( "Qt version: %1.%2.%3" ).arg( QT_VERSION_MAJOR ).arg( QT_VERSION_MINOR ).arg( QT_VERSION_PATCH );
#if QT_VERSION >= 0x051000 #if QT_VERSION >= 0x051000
qDebug() << QString( "Qt version: %1.%2.%3" ).arg( QT_VERSION_MAJOR ).arg( QT_VERSION_MINOR ).arg( QT_VERSION_PATCH );
qDebug() << QString( "Min Linux: %1.%2.%3" ).arg( MINLINUX_MAJOR ).arg( MINLINUX_MINOR ).arg( MINLINUX_PATCH ); qDebug() << QString( "Min Linux: %1.%2.%3" ).arg( MINLINUX_MAJOR ).arg( MINLINUX_MINOR ).arg( MINLINUX_PATCH );
#else
qDebug() << QString( "Qt version: %1" ).arg( QT_VERSION_STR );
#endif #endif
return( 0 ); return( 0 );