[calamares] Make KCoreAddons a requirement
- Require KCoreAddons for KAboutData (also, optionally, for KOSRelease)
This commit is contained in:
parent
a6db224fcb
commit
bcb7f17584
@ -261,6 +261,8 @@ if( Qt5_VERSION VERSION_GREATER 5.12.1 )
|
|||||||
list( APPEND _tx_ok "eo" )
|
list( APPEND _tx_ok "eo" )
|
||||||
endif()
|
endif()
|
||||||
endif()
|
endif()
|
||||||
|
# Optional Qt parts
|
||||||
|
find_package( Qt5DBus CONFIG )
|
||||||
|
|
||||||
find_package( YAMLCPP ${YAMLCPP_VERSION} REQUIRED )
|
find_package( YAMLCPP ${YAMLCPP_VERSION} REQUIRED )
|
||||||
if( INSTALL_POLKIT )
|
if( INSTALL_POLKIT )
|
||||||
@ -291,7 +293,14 @@ if( ECM_FOUND )
|
|||||||
include(KDEInstallDirs)
|
include(KDEInstallDirs)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
find_package( KF5 COMPONENTS CoreAddons Crash )
|
find_package( KF5 QUIET COMPONENTS CoreAddons Crash )
|
||||||
|
set_package_properties(
|
||||||
|
KF5::CoreAddons PROPERTIES
|
||||||
|
TYPE REQUIRED
|
||||||
|
DESCRIPTION "Classes built on QtCore for About Data"
|
||||||
|
URL "https://api.kde.org/frameworks/kcoreaddons/"
|
||||||
|
PURPOSE "About Calamares"
|
||||||
|
)
|
||||||
if( NOT KF5Crash_FOUND )
|
if( NOT KF5Crash_FOUND )
|
||||||
set( WITH_KF5Crash OFF )
|
set( WITH_KF5Crash OFF )
|
||||||
endif()
|
endif()
|
||||||
@ -590,10 +599,25 @@ add_custom_target( uninstall
|
|||||||
|
|
||||||
### CMAKE SUMMARY REPORT
|
### CMAKE SUMMARY REPORT
|
||||||
#
|
#
|
||||||
feature_summary(WHAT ALL)
|
|
||||||
|
|
||||||
get_directory_property( SKIPPED_MODULES
|
get_directory_property( SKIPPED_MODULES
|
||||||
DIRECTORY src/modules
|
DIRECTORY src/modules
|
||||||
DEFINITION LIST_SKIPPED_MODULES
|
DEFINITION LIST_SKIPPED_MODULES
|
||||||
)
|
)
|
||||||
calamares_explain_skipped_modules( ${SKIPPED_MODULES} )
|
calamares_explain_skipped_modules( ${SKIPPED_MODULES} )
|
||||||
|
|
||||||
|
feature_summary(
|
||||||
|
WHAT DISABLED_FEATURES
|
||||||
|
DESCRIPTION "The following features have been disabled:"
|
||||||
|
QUIET_ON_EMPTY
|
||||||
|
)
|
||||||
|
feature_summary(
|
||||||
|
WHAT OPTIONAL_PACKAGES_NOT_FOUND
|
||||||
|
DESCRIPTION "The following OPTIONAL packages were not found:"
|
||||||
|
QUIET_ON_EMPTY
|
||||||
|
)
|
||||||
|
feature_summary(
|
||||||
|
WHAT REQUIRED_PACKAGES_NOT_FOUND
|
||||||
|
FATAL_ON_MISSING_REQUIRED_PACKAGES
|
||||||
|
DESCRIPTION "The following REQUIRED packages were not found:"
|
||||||
|
QUIET_ON_EMPTY
|
||||||
|
)
|
||||||
|
@ -46,11 +46,11 @@ target_link_libraries( calamares_bin
|
|||||||
calamaresui
|
calamaresui
|
||||||
Qt5::Core
|
Qt5::Core
|
||||||
Qt5::Widgets
|
Qt5::Widgets
|
||||||
|
KF5::CoreAddons
|
||||||
)
|
)
|
||||||
if( WITH_KF5Crash )
|
if( WITH_KF5Crash )
|
||||||
target_link_libraries( calamares_bin
|
target_link_libraries( calamares_bin
|
||||||
PRIVATE
|
PRIVATE
|
||||||
KF5::CoreAddons
|
|
||||||
KF5::Crash
|
KF5::Crash
|
||||||
)
|
)
|
||||||
target_compile_definitions( calamares_bin PRIVATE WITH_KF5Crash )
|
target_compile_definitions( calamares_bin PRIVATE WITH_KF5Crash )
|
||||||
|
@ -26,8 +26,8 @@
|
|||||||
|
|
||||||
#include "3rdparty/kdsingleapplicationguard/kdsingleapplicationguard.h"
|
#include "3rdparty/kdsingleapplicationguard/kdsingleapplicationguard.h"
|
||||||
|
|
||||||
#ifdef WITH_KF5Crash
|
|
||||||
#include <KF5/KCoreAddons/KAboutData>
|
#include <KF5/KCoreAddons/KAboutData>
|
||||||
|
#ifdef WITH_KF5Crash
|
||||||
#include <KF5/KCrash/KCrash>
|
#include <KF5/KCrash/KCrash>
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -93,7 +93,6 @@ main( int argc, char* argv[] )
|
|||||||
{
|
{
|
||||||
CalamaresApplication a( argc, argv );
|
CalamaresApplication a( argc, argv );
|
||||||
|
|
||||||
#ifdef WITH_KF5Crash
|
|
||||||
KAboutData aboutData( "calamares",
|
KAboutData aboutData( "calamares",
|
||||||
"Calamares",
|
"Calamares",
|
||||||
a.applicationVersion(),
|
a.applicationVersion(),
|
||||||
@ -104,12 +103,14 @@ main( int argc, char* argv[] )
|
|||||||
"https://calamares.io",
|
"https://calamares.io",
|
||||||
"https://github.com/calamares/calamares/issues" );
|
"https://github.com/calamares/calamares/issues" );
|
||||||
KAboutData::setApplicationData( aboutData );
|
KAboutData::setApplicationData( aboutData );
|
||||||
|
a.setApplicationDisplayName( QString() ); // To avoid putting an extra "Calamares/" into the log-file
|
||||||
|
|
||||||
|
#ifdef WITH_KF5Crash
|
||||||
KCrash::initialize();
|
KCrash::initialize();
|
||||||
// KCrash::setCrashHandler();
|
// KCrash::setCrashHandler();
|
||||||
KCrash::setDrKonqiEnabled( true );
|
KCrash::setDrKonqiEnabled( true );
|
||||||
KCrash::setFlags( KCrash::SaferDialog | KCrash::AlwaysDirectly );
|
KCrash::setFlags( KCrash::SaferDialog | KCrash::AlwaysDirectly );
|
||||||
// TODO: umount anything in /tmp/calamares-... as an emergency save function
|
// TODO: umount anything in /tmp/calamares-... as an emergency save function
|
||||||
a.setApplicationDisplayName( QString() );
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
handle_args( a );
|
handle_args( a );
|
||||||
|
Loading…
Reference in New Issue
Block a user