if( WITH_PARTITIONMANAGER ) add_definitions( -DCALAMARES ) include_directories( ${PROJECT_BINARY_DIR}/src/calamares ) calamares_add_plugin( partition TYPE viewmodule EXPORT_MACRO PLUGINDLLEXPORT_PRO CONFIG_FILE module.conf SOURCES CreatePartitionDialog.cpp CreatePartitionJob.cpp DeviceModel.cpp PartitionModel.cpp PartitionPage.cpp PartitionViewStep.cpp PMUtils.cpp UI CreatePartitionDialog.ui PartitionPage.ui LINK_LIBRARIES calapm ${CALAMARES_LIBRARIES} calamares_bin SHARED_LIB ) # Temporary, until views are integrated set( partview_SRCS CreatePartitionDialog.cpp CreatePartitionJob.cpp DeviceModel.cpp PartitionCoreModule.cpp PartitionModel.cpp PartitionPage.cpp PMUtils.cpp ${calamares_SOURCE_DIR}/viewpages/AbstractPage.cpp main.cpp ) qt5_wrap_ui( partview_SRCS CreatePartitionDialog.ui PartitionPage.ui ) include_directories( ${CMAKE_CURRENT_BINARY_DIR} ) add_executable( partview ${partview_SRCS} ) target_link_libraries( partview calapm ${CALAMARES_LIBRARIES} Qt5::Widgets Qt5::Gui Qt5::Core ) set_target_properties( partview PROPERTIES AUTOMOC TRUE ) endif( WITH_PARTITIONMANAGER )