From 408620ea99606f8b27ebf237fa3800e40e2c9cd3 Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Thu, 2 Mar 2017 11:41:47 +0100 Subject: Fix building with -no-feature-process Drop an unused include, don't try to build qmlplugindump in this case, and add some guards around QProcess includes and usages. Change-Id: I6ce5985a8dd1967f146016a7acd1ea31fb3bda2a Reviewed-by: Simon Hausmann --- tests/auto/qml/qmlmin/tst_qmlmin.cpp | 8 +++++--- .../auto/qml/qqmlapplicationengine/tst_qqmlapplicationengine.cpp | 2 ++ tests/auto/quick/examples/tst_examples.cpp | 1 - 3 files changed, 7 insertions(+), 4 deletions(-) (limited to 'tests') diff --git a/tests/auto/qml/qmlmin/tst_qmlmin.cpp b/tests/auto/qml/qmlmin/tst_qmlmin.cpp index 3ed0aa7446..90868d2ead 100644 --- a/tests/auto/qml/qmlmin/tst_qmlmin.cpp +++ b/tests/auto/qml/qmlmin/tst_qmlmin.cpp @@ -29,7 +29,9 @@ #include #include #include +#if QT_CONFIG(process) #include +#endif #include #include #include @@ -42,7 +44,7 @@ public: private slots: void initTestCase(); -#if !defined(QTEST_CROSS_COMPILED) // sources not available when cross compiled +#if QT_CONFIG(process) && !defined(QTEST_CROSS_COMPILED) // sources not available when cross compiled void qmlMinify_data(); void qmlMinify(); #endif @@ -166,7 +168,7 @@ Examples are any .qml files under the examples/ directory that start with a lower case letter. */ -#if !defined(QTEST_CROSS_COMPILED) // sources not available when cross compiled +#if QT_CONFIG(process) && !defined(QTEST_CROSS_COMPILED) // sources not available when cross compiled void tst_qmlmin::qmlMinify_data() { QTest::addColumn("file"); @@ -183,7 +185,7 @@ void tst_qmlmin::qmlMinify_data() } #endif -#if !defined(QTEST_CROSS_COMPILED) // sources not available when cross compiled +#if QT_CONFIG(process) && !defined(QTEST_CROSS_COMPILED) // sources not available when cross compiled void tst_qmlmin::qmlMinify() { QFETCH(QString, file); diff --git a/tests/auto/qml/qqmlapplicationengine/tst_qqmlapplicationengine.cpp b/tests/auto/qml/qqmlapplicationengine/tst_qqmlapplicationengine.cpp index 98b92e5fab..f2754d636b 100644 --- a/tests/auto/qml/qqmlapplicationengine/tst_qqmlapplicationengine.cpp +++ b/tests/auto/qml/qqmlapplicationengine/tst_qqmlapplicationengine.cpp @@ -29,7 +29,9 @@ #include "../../shared/util.h" #include #include +#if QT_CONFIG(process) #include +#endif #include class tst_qqmlapplicationengine : public QQmlDataTest diff --git a/tests/auto/quick/examples/tst_examples.cpp b/tests/auto/quick/examples/tst_examples.cpp index 1ca809c05f..ffb7fb5789 100644 --- a/tests/auto/quick/examples/tst_examples.cpp +++ b/tests/auto/quick/examples/tst_examples.cpp @@ -29,7 +29,6 @@ #include #include #include -#include #include #include #include -- cgit v1.2.3 From 13335bdee5482ae04d5b0d4c933ca328a1100cb6 Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Mon, 6 Mar 2017 13:49:42 +0100 Subject: Fix build with -no-feature-library The versionUriList() function is unused in this case, and we cannot build the extension plugins test. Change-Id: I6c2ea1c2d078e508b0752efb45f4ccdfdbcbf22e Reviewed-by: Simon Hausmann --- tests/auto/qml/qml.pro | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/auto/qml/qml.pro b/tests/auto/qml/qml.pro index 7d182b7255..b347b603bb 100644 --- a/tests/auto/qml/qml.pro +++ b/tests/auto/qml/qml.pro @@ -70,14 +70,17 @@ qtHaveModule(widgets) { qjsvalue } -SUBDIRS += $$PUBLICTESTS \ - qqmlextensionplugin +SUBDIRS += $$PUBLICTESTS SUBDIRS += $$METATYPETESTS qtConfig(process) { !contains(QT_CONFIG, no-qml-debug): SUBDIRS += debugger SUBDIRS += qmllint qmlplugindump } +qtConfig(library) { + SUBDIRS += qqmlextensionplugin +} + qtConfig(private_tests): \ SUBDIRS += $$PRIVATETESTS -- cgit v1.2.3