From 8f86b197f2f9b0dc37528dab70123798c01c9e51 Mon Sep 17 00:00:00 2001 From: Teo Mrnjavac Date: Wed, 16 Mar 2016 13:20:39 +0100 Subject: [PATCH] Initialize crash handler. --- src/calamares/main.cpp | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/src/calamares/main.cpp b/src/calamares/main.cpp index bc27688f3..7cd2728d2 100644 --- a/src/calamares/main.cpp +++ b/src/calamares/main.cpp @@ -19,10 +19,16 @@ #include "CalamaresApplication.h" +#include "CalamaresConfig.h" #include "kdsingleapplicationguard/kdsingleapplicationguard.h" #include "utils/CalamaresUtils.h" #include "utils/Logger.h" +#ifdef WITH_KCRASH +#include +#include +#endif + #include #include #include @@ -32,6 +38,22 @@ main( int argc, char* argv[] ) { CalamaresApplication a( argc, argv ); +#ifdef WITH_KCRASH + KAboutData aboutData( "calamares", + "Calamares", + a.applicationVersion(), + "The universal system installer", + KAboutLicense::GPL_V3, + QString(), + QString(), + "https://calamares.io", + "teo@kde.org" ); + KAboutData::setApplicationData( aboutData ); + KCrash::initialize(); + KCrash::setCrashHandler(); + // TODO: umount anything in /tmp/calamares-... as an emergency save function +#endif + QCommandLineParser parser; parser.setApplicationDescription( "Distribution-independent installer framework" ); parser.addHelpOption();