build-system: update cmake to allow Qt5 and Qt6

Qt6 builds of course still fail, but now they are at least possible.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2022-02-09 15:02:30 -08:00
parent c4319e3995
commit ce254bee57
6 changed files with 97 additions and 33 deletions

View file

@ -21,8 +21,6 @@ set(SUBSURFACE_GENERIC_MODELS_LIB_SRCS
filterconstraintmodel.h
filterpresetmodel.cpp
filterpresetmodel.h
maplocationmodel.cpp
maplocationmodel.h
models.cpp
models.h
tankinfomodel.cpp
@ -31,6 +29,13 @@ set(SUBSURFACE_GENERIC_MODELS_LIB_SRCS
weightsysteminfomodel.h
)
if(NOT USINGQT6)
LIST(APPEND SUBSURFACE_GENERIC_MODELS_LIB_SRCS
maplocationmodel.cpp
maplocationmodel.h
)
endif()
# models exclusively used in desktop builds
set(SUBSURFACE_DESKTOP_MODELS_LIB_SRCS
divecomputerextradatamodel.cpp