From 9889bd6cbe7849074ca76d1058846559b9df1af5 Mon Sep 17 00:00:00 2001 From: Adriaan de Groot Date: Mon, 25 Feb 2019 08:44:08 -0500 Subject: [PATCH] [welcome] Be louder when libparted is disabled --- src/modules/welcome/checker/GeneralRequirements.cpp | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/modules/welcome/checker/GeneralRequirements.cpp b/src/modules/welcome/checker/GeneralRequirements.cpp index 0a841eca1..7880d3c65 100644 --- a/src/modules/welcome/checker/GeneralRequirements.cpp +++ b/src/modules/welcome/checker/GeneralRequirements.cpp @@ -187,6 +187,18 @@ GeneralRequirements::setConfigurationMap( const QVariantMap& configurationMap ) incompleteConfiguration = true; } +#ifdef WITHOUT_LIBPARTED + if ( m_entriesToCheck.contains( "storage" ) ) + cWarning() << "GeneralRequirements checks 'storage' but libparted is disabled."; + if ( m_entriesToRequire.contains( "storage" ) ) + { + // Warn, but also drop the required bit because otherwise installation + // will be impossible (because the check always returns false). + cWarning() << "GeneralRequirements requires 'storage' check but libparted is disabled."; + m_entriesToRequire.removeAll( "storage" ); + } +#endif + // Help out with consistency, but don't fix for ( const auto& r : m_entriesToRequire ) if ( !m_entriesToCheck.contains( r ) )