Make licensechecker dependency optional

Change-Id: Ie867d2da37a507d36caaf16494f996b88ca4e142
Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
This commit is contained in:
Kai Koehne
2015-06-11 17:29:00 +02:00
parent bd3195ec6b
commit d49232bbf1
3 changed files with 13 additions and 4 deletions

View File

@@ -35,9 +35,12 @@
#include <coreplugin/actionmanager/actioncontainer.h>
#include <coreplugin/coreconstants.h>
#include <coreplugin/dialogs/ioptionspage.h>
#include <licensechecker/licensecheckerplugin.h>
#include <projectexplorer/projectpanelfactory.h>
#ifdef LICENSECHECKER
#include <licensechecker/licensecheckerplugin.h>
#endif
#include <extensionsystem/pluginmanager.h>
#include <QAction>
@@ -114,6 +117,7 @@ bool ClangStaticAnalyzerPlugin::initialize(const QStringList &arguments, QString
panelFactory->setSimpleCreateWidgetFunction<ProjectSettingsWidget>(QIcon());
ProjectExplorer::ProjectPanelFactory::registerFactory(panelFactory);
#ifdef LICENSECHECKER
LicenseChecker::LicenseCheckerPlugin *licenseChecker
= ExtensionSystem::PluginManager::getObject<LicenseChecker::LicenseCheckerPlugin>();
@@ -123,8 +127,10 @@ bool ClangStaticAnalyzerPlugin::initialize(const QStringList &arguments, QString
} else {
qWarning() << "Invalid license, disabling Clang Static Analyzer";
}
return true;
#else // LICENSECHECKER
return initializeEnterpriseFeatures(arguments, errorString);
#endif
}
bool ClangStaticAnalyzerPlugin::initializeEnterpriseFeatures(const QStringList &arguments,