Skip to content

Commit

Permalink
reject configuration with unsupported Qt versions
Browse files Browse the repository at this point in the history
  • Loading branch information
pedrolcl committed Sep 24, 2024
1 parent f337821 commit e546b55
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,8 @@ else()
find_package(QT NAMES Qt6 REQUIRED)
endif()

if ((CMAKE_SYSTEM_NAME MATCHES "Linux") AND (QT_VERSION_MAJOR EQUAL 6) AND (QT_VERSION VERSION_LESS 6.4))
message(WARNING "Unsupported Qt version ${QT_VERSION} for ${CMAKE_SYSTEM_NAME}")
if (((CMAKE_SYSTEM_NAME MATCHES "Linux") AND (QT_VERSION_MAJOR EQUAL 6) AND (QT_VERSION VERSION_LESS 6.4)) OR QT_VERSION VERSION_GREATER 6.5.99)
message(FATAL_ERROR "Unsupported Qt version ${QT_VERSION} for ${CMAKE_SYSTEM_NAME}")
endif()

find_package(Qt${QT_VERSION_MAJOR} COMPONENTS Core Gui Widgets Multimedia REQUIRED)
Expand Down

0 comments on commit e546b55

Please # to comment.