cmake: Compile tst_qtwidgets only if QtWidgets frontend is built

The QtQuick frontend is now buildable withotu the QtWidgets one.
This commit is contained in:
Sergio Martins
2022-05-29 22:13:20 +01:00
parent c36832d71c
commit 04b9590d59

View File

@@ -32,9 +32,11 @@ target_link_libraries(tst_docks kddockwidgets Qt${Qt_VERSION_MAJOR}::Test)
set_compiler_flags(tst_docks)
# tst_qtwidgets
add_executable(tst_qtwidgets qtwidgets/tst_qtwidgets.cpp ${TESTING_SRCS} ${TESTING_RESOURCES})
target_link_libraries(tst_qtwidgets kddockwidgets Qt${Qt_VERSION_MAJOR}::Test)
set_compiler_flags(tst_qtwidgets)
if (KDDW_FRONTEND_QTWIDGETS)
add_executable(tst_qtwidgets qtwidgets/tst_qtwidgets.cpp ${TESTING_SRCS} ${TESTING_RESOURCES})
target_link_libraries(tst_qtwidgets kddockwidgets Qt${Qt_VERSION_MAJOR}::Test)
set_compiler_flags(tst_qtwidgets)
endif()
add_executable(tst_multisplitter tst_multisplitter.cpp)
target_link_libraries(tst_multisplitter kddockwidgets Qt${Qt_VERSION_MAJOR}::Test)