Skip to content

Commit

Permalink
Match exact Qt versions for QtScxml and QtStateMachine
Browse files Browse the repository at this point in the history
If pointed towards a different prefix for Qt, it's possible to have
QtScxml and QtStateMachine fall back to the system Qt which may be a
completely different version. This prevents an issues where you could be
building with Qt 6.5, and it falls back to system Qt 6.6 for example.

Fixes #893
  • Loading branch information
redstrate committed Jan 10, 2024
1 parent ac8ed0c commit 2b053b2
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 @@ -480,9 +480,9 @@ endif()
find_package(Qt${QT_VERSION_MAJOR}IviCore 1.1 NO_MODULE QUIET) # 1.1 is based on 5.8
find_package(Qt${QT_VERSION_MAJOR}IviVehicleFunctions 1.1 NO_MODULE QUIET)
find_package(Qt${QT_VERSION_MAJOR}IviMedia 1.1 NO_MODULE QUIET)
find_package(Qt${QT_VERSION_MAJOR}Scxml 5.8 NO_MODULE QUIET)
find_package(Qt${QT_VERSION_MAJOR}Scxml ${Qt${QT_VERSION_MAJOR}_VERSION} EXACT NO_MODULE QUIET)
if(QT_VERSION_MAJOR GREATER_EQUAL 6)
find_package(Qt${QT_VERSION_MAJOR}StateMachine NO_MODULE QUIET)
find_package(Qt${QT_VERSION_MAJOR}StateMachine ${Qt${QT_VERSION_MAJOR}_VERSION} EXACT NO_MODULE QUIET)
endif()

# if translation/doc host tools are missing, the Qt5 cmake config files throw errors...
Expand Down

0 comments on commit 2b053b2

Please sign in to comment.