|
|
|
@ -2,12 +2,17 @@ find_package( KPMcore 3.3 )
|
|
|
|
|
find_package( Qt5 REQUIRED DBus ) # Needed for KPMCore
|
|
|
|
|
find_package( KF5 REQUIRED I18n WidgetsAddons ) # Needed for KPMCore
|
|
|
|
|
|
|
|
|
|
set( _partition_defs "" )
|
|
|
|
|
|
|
|
|
|
if ( KPMcore_FOUND )
|
|
|
|
|
include_directories( ${KPMCORE_INCLUDE_DIR} )
|
|
|
|
|
include_directories( ${PROJECT_BINARY_DIR}/src/libcalamares )
|
|
|
|
|
|
|
|
|
|
if ( KPMcore_VERSION VERSION_GREATER "3.3.0")
|
|
|
|
|
add_definitions(-DWITH_KPMCOREGT33) # kpmcore greater than 3.3
|
|
|
|
|
list( APPEND _partition_defs WITH_KPMCORE331API) # kpmcore > 3.3.0 with deprecations
|
|
|
|
|
endif()
|
|
|
|
|
if ( KPMcore_VERSION VERSION_GREATER "3.90")
|
|
|
|
|
list( APPEND _partition_defs WITH_KPMCORE4API) # kpmcore 4 with new API
|
|
|
|
|
endif()
|
|
|
|
|
|
|
|
|
|
# The PartitionIterator is a small class, and it's easiest -- but also a
|
|
|
|
@ -21,6 +26,7 @@ if ( KPMcore_FOUND )
|
|
|
|
|
LINK_PRIVATE_LIBRARIES
|
|
|
|
|
kpmcore
|
|
|
|
|
calamares
|
|
|
|
|
COMPILE_DEFINITIONS ${_partition_defs}
|
|
|
|
|
SHARED_LIB
|
|
|
|
|
)
|
|
|
|
|
|
|
|
|
@ -38,7 +44,8 @@ if ( KPMcore_FOUND )
|
|
|
|
|
Qt5::Test
|
|
|
|
|
)
|
|
|
|
|
set_target_properties( fsresizertest PROPERTIES AUTOMOC TRUE )
|
|
|
|
|
target_include_directories(fsresizertest PRIVATE /usr/local/include )
|
|
|
|
|
target_include_directories( fsresizertest PRIVATE /usr/local/include )
|
|
|
|
|
target_compile_definitions( fsresizertest PRIVATE ${_partition_defs} )
|
|
|
|
|
endif()
|
|
|
|
|
else()
|
|
|
|
|
calamares_skip_module( "fsresizer (missing suitable KPMcore)" )
|
|
|
|
|