diff --git a/drivers/common/CMakeLists.txt b/drivers/common/CMakeLists.txt index 362fca90f..82bcaaf35 100644 --- a/drivers/common/CMakeLists.txt +++ b/drivers/common/CMakeLists.txt @@ -194,6 +194,9 @@ tiny_resource_and_manifest(${TinyDrivers_target} # 'WINVER' macro redefined [-Wmacro-redefined] # Look also to the TinyCommon for conditional WINVER definition find_package(QT NAMES Qt6 Qt5 REQUIRED COMPONENTS Core) +if(QT_VERSION_MAJOR LESS 6) + message(FATAL_ERROR "TinyDrivers library is not supported with Qt version <6.") +endif() # No need to call the tiny_find_package() here as the core TinyOrm always depends on it find_package(Qt${QT_VERSION_MAJOR} ${minQtVersion} CONFIG REQUIRED COMPONENTS Core diff --git a/drivers/mysql/CMakeLists.txt b/drivers/mysql/CMakeLists.txt index faa69d7f7..140de5f88 100644 --- a/drivers/mysql/CMakeLists.txt +++ b/drivers/mysql/CMakeLists.txt @@ -148,6 +148,9 @@ tiny_resource_and_manifest(${TinyMySql_target} # 'WINVER' macro redefined [-Wmacro-redefined] # Look also to the TinyCommon for conditional WINVER definition find_package(QT NAMES Qt6 Qt5 REQUIRED COMPONENTS Core) +if(QT_VERSION_MAJOR LESS 6) + message(FATAL_ERROR "TinyMySql library is not supported with Qt version <6.") +endif() # No need to call the tiny_find_package() here as the core TinyOrm always depends on it find_package(Qt${QT_VERSION_MAJOR} ${minQtVersion} CONFIG REQUIRED COMPONENTS Core