QSK_QT_VERSION removed as CMAKE_PREFIX_PATH offers a more general
solution for selecting a specific Qt version
This commit is contained in:
parent
683088539f
commit
530720beb3
@ -5,15 +5,9 @@
|
|||||||
|
|
||||||
macro(qsk_setup_Qt)
|
macro(qsk_setup_Qt)
|
||||||
|
|
||||||
# Use QSK_QT_VERSION specified with baseline 5.15
|
# relying on cmake heuristics to select a specific Qt version is no good idea.
|
||||||
# otherwise fallback to latest known supported Qt version gte 5.15
|
# using -DCMAKE_PREFIX_PATH="..." is highly recommended
|
||||||
# set vars for correct alpha descending sort order and direction (ex. Qt6, Qt5)
|
find_package(QT "5.15" NAMES Qt6 Qt5 REQUIRED COMPONENTS Quick)
|
||||||
if ( NOT QSK_QT_VERSION ) # QSK_QT_VERSION=Qt5
|
|
||||||
set(QSK_QT_VERSION Qt6 Qt5)
|
|
||||||
set(CMAKE_FIND_PACKAGE_SORT_ORDER NAME)
|
|
||||||
set(CMAKE_FIND_PACKAGE_SORT_DIRECTION DEC)
|
|
||||||
endif()
|
|
||||||
find_package(QT "5.15" NAMES ${QSK_QT_VERSION} REQUIRED COMPONENTS Quick)
|
|
||||||
|
|
||||||
if(QT_VERSION_MAJOR VERSION_GREATER_EQUAL 6)
|
if(QT_VERSION_MAJOR VERSION_GREATER_EQUAL 6)
|
||||||
# we need the qsb tool for Qt6
|
# we need the qsb tool for Qt6
|
||||||
|
Loading…
x
Reference in New Issue
Block a user