From 44af54419eaceb27bb729717d6363917fd6bb819 Mon Sep 17 00:00:00 2001 From: Ulf Hermann Date: Wed, 23 Nov 2016 12:25:17 +0100 Subject: Properly use the "process" feature Replace all QT_NO_PROCESS with QT_CONFIG(process), define it in qconfig-bootstrapped.h, add QT_REQUIRE_CONFIG(process) to the qprocess headers, exclude the sources from compilation when switched off, guard header inclusions in places where compilation without QProcess seems supported, drop some unused includes, and fix some tests that were apparently designed to work with QT_NO_PROCESS but failed to. Change-Id: Ieceea2504dea6fdf43b81c7c6b65c547b01b9714 Reviewed-by: Oswald Buddenhagen --- tests/benchmarks/corelib/io/io.pro | 2 +- tests/benchmarks/corelib/io/qprocess/tst_bench_qprocess.cpp | 6 ------ 2 files changed, 1 insertion(+), 7 deletions(-) (limited to 'tests/benchmarks') diff --git a/tests/benchmarks/corelib/io/io.pro b/tests/benchmarks/corelib/io/io.pro index 38a1f6b15b..23f9c190aa 100644 --- a/tests/benchmarks/corelib/io/io.pro +++ b/tests/benchmarks/corelib/io/io.pro @@ -5,7 +5,7 @@ SUBDIRS = \ qfile \ qfileinfo \ qiodevice \ - qprocess \ qtemporaryfile \ qtextstream +qtConfig(process): SUBDIRS += qprocess diff --git a/tests/benchmarks/corelib/io/qprocess/tst_bench_qprocess.cpp b/tests/benchmarks/corelib/io/qprocess/tst_bench_qprocess.cpp index 782cad94a1..5bd4bc5520 100644 --- a/tests/benchmarks/corelib/io/qprocess/tst_bench_qprocess.cpp +++ b/tests/benchmarks/corelib/io/qprocess/tst_bench_qprocess.cpp @@ -33,15 +33,11 @@ class tst_QProcess : public QObject { Q_OBJECT -#if !defined(QT_NO_PROCESS) private slots: void echoTest_performance(); - -#endif // QT_NO_PROCESS }; -#if !defined(QT_NO_PROCESS) void tst_QProcess::echoTest_performance() { QProcess process; @@ -87,7 +83,5 @@ void tst_QProcess::echoTest_performance() QVERIFY(process.waitForFinished()); } -#endif // QT_NO_PROCESS - QTEST_MAIN(tst_QProcess) #include "tst_bench_qprocess.moc" -- cgit v1.2.3