summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKai Koehne <kai.koehne@theqtcompany.com>2015-06-11 17:21:54 +0200
committerKai Koehne <kai.koehne@theqtcompany.com>2015-06-25 16:31:54 +0300
commiteee4f2c6ac87fc42a34be04a755167bb9fdc50d2 (patch)
tree8187c1a72d825df5ce21358b8734341f5ab9c245
parenta133256e3704a7ca685d2f8082c69e5bc8bdaee9 (diff)
downloadqt-creator-eee4f2c6ac87fc42a34be04a755167bb9fdc50d2.tar.gz
Make licensechecker dependency optional
Change-Id: Ia353ef7065dbd7dd3ff1f3a9293613cf7f14ce37 Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
-rw-r--r--plugins/autotest/autotest.pro1
-rw-r--r--plugins/autotest/autotest_dependencies.pri5
-rw-r--r--plugins/autotest/autotestplugin.cpp6
3 files changed, 9 insertions, 3 deletions
diff --git a/plugins/autotest/autotest.pro b/plugins/autotest/autotest.pro
index 4d3c6643f2..4022cb4399 100644
--- a/plugins/autotest/autotest.pro
+++ b/plugins/autotest/autotest.pro
@@ -7,6 +7,7 @@ include(../../qtcreatorplugin.pri)
include(autotest_dependencies.pri)
DEFINES += AUTOTEST_LIBRARY
+CONFIG(licensechecker): DEFINES += LICENSECHECKER
SOURCES += \
testtreeview.cpp \
diff --git a/plugins/autotest/autotest_dependencies.pri b/plugins/autotest/autotest_dependencies.pri
index a21b5fce96..74dc51e15b 100644
--- a/plugins/autotest/autotest_dependencies.pri
+++ b/plugins/autotest/autotest_dependencies.pri
@@ -5,8 +5,9 @@ QTC_PLUGIN_DEPENDS += \
projectexplorer \
cpptools \
qmljstools \
- qmakeprojectmanager \
- licensechecker
+ qmakeprojectmanager
+
+CONFIG(licensechecker): QTC_PLUGIN_DEPENDS += licensechecker
QTC_LIB_DEPENDS += \
cplusplus \
diff --git a/plugins/autotest/autotestplugin.cpp b/plugins/autotest/autotestplugin.cpp
index a2ab783418..525f21ae3e 100644
--- a/plugins/autotest/autotestplugin.cpp
+++ b/plugins/autotest/autotestplugin.cpp
@@ -38,7 +38,9 @@
#include <extensionsystem/pluginmanager.h>
-#include <licensechecker/licensecheckerplugin.h>
+#ifdef LICENSECHECKER
+# include <licensechecker/licensecheckerplugin.h>
+#endif
#include <QAction>
#include <QMessageBox>
@@ -89,6 +91,7 @@ QSharedPointer<TestSettings> AutotestPlugin::settings() const
bool AutotestPlugin::checkLicense()
{
+#ifdef LICENSECHECKER
LicenseChecker::LicenseCheckerPlugin *licenseChecker
= ExtensionSystem::PluginManager::getObject<LicenseChecker::LicenseCheckerPlugin>();
@@ -97,6 +100,7 @@ bool AutotestPlugin::checkLicense()
return false;
} else if (!licenseChecker->enterpriseFeatures())
return false;
+#endif // LICENSECHECKER
return true;
}