2019-08-02 10:57:12 +02:00
|
|
|
find_package( Qt5 COMPONENTS Core Gui Widgets REQUIRED )
|
2019-08-06 14:33:57 +02:00
|
|
|
set( _extra_libraries "" )
|
|
|
|
|
|
|
|
### OPTIONAL AppData XML support in PackageModel
|
|
|
|
#
|
|
|
|
#
|
|
|
|
find_package(Qt5 COMPONENTS Xml)
|
|
|
|
if ( Qt5Xml_FOUND )
|
|
|
|
add_definitions( -DHAVE_XML )
|
|
|
|
list( APPEND _extra_libraries Qt5::Xml )
|
|
|
|
endif()
|
|
|
|
|
2019-08-02 10:57:12 +02:00
|
|
|
|
|
|
|
calamares_add_plugin( packagechooser
|
|
|
|
TYPE viewmodule
|
|
|
|
EXPORT_MACRO PLUGINDLLEXPORT_PRO
|
|
|
|
SOURCES
|
|
|
|
PackageChooserPage.cpp
|
|
|
|
PackageChooserViewStep.cpp
|
2019-08-02 13:05:46 +02:00
|
|
|
PackageModel.cpp
|
2019-08-02 17:02:02 +02:00
|
|
|
RESOURCES
|
|
|
|
packagechooser.qrc
|
2019-08-02 10:57:12 +02:00
|
|
|
UI
|
|
|
|
page_package.ui
|
|
|
|
LINK_PRIVATE_LIBRARIES
|
|
|
|
calamaresui
|
2019-08-06 14:33:57 +02:00
|
|
|
${_extra_libraries}
|
2019-08-02 10:57:12 +02:00
|
|
|
SHARED_LIB
|
|
|
|
)
|
|
|
|
|
|
|
|
if( ECM_FOUND AND BUILD_TESTING )
|
|
|
|
ecm_add_test(
|
|
|
|
Tests.cpp
|
|
|
|
TEST_NAME
|
2019-08-04 20:04:32 +02:00
|
|
|
packagechoosertest
|
2019-08-02 10:57:12 +02:00
|
|
|
LINK_LIBRARIES
|
|
|
|
${CALAMARES_LIBRARIES}
|
2019-08-06 14:33:57 +02:00
|
|
|
calamares_viewmodule_packagechooser
|
2019-08-02 10:57:12 +02:00
|
|
|
Qt5::Core
|
|
|
|
Qt5::Test
|
2019-08-06 14:33:57 +02:00
|
|
|
Qt5::Gui
|
|
|
|
${_extra_libraries}
|
2019-08-02 10:57:12 +02:00
|
|
|
)
|
2019-08-04 20:04:32 +02:00
|
|
|
calamares_automoc( packagechoosertest)
|
2019-08-02 10:57:12 +02:00
|
|
|
endif()
|