diff options
author | Christian Kandeler <christian.kandeler@qt.io> | 2018-11-20 16:27:19 +0100 |
---|---|---|
committer | Christian Kandeler <christian.kandeler@qt.io> | 2018-11-21 12:31:21 +0000 |
commit | 428cc6188fb4f99bca8522530ed400357cfe38ec (patch) | |
tree | 5091edd0ee1184d50ddc2a8bf6ef305a9481e8d2 /tests/auto/blackbox/tst_blackboxbase.cpp | |
parent | 04df7bbcf1a346c2e2bf15755790c8554a0b2c96 (diff) |
qbs build: Fix look-up of qbs executable by autotests
The code worked only if qbs.installPrefix was empty.
Change-Id: I9ba69f10c976b4a2b71ae4934c4cdac58895882a
Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'tests/auto/blackbox/tst_blackboxbase.cpp')
-rw-r--r-- | tests/auto/blackbox/tst_blackboxbase.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/auto/blackbox/tst_blackboxbase.cpp b/tests/auto/blackbox/tst_blackboxbase.cpp index b07f14553..e1844b69c 100644 --- a/tests/auto/blackbox/tst_blackboxbase.cpp +++ b/tests/auto/blackbox/tst_blackboxbase.cpp @@ -46,9 +46,9 @@ using qbs::Profile; static QString initQbsExecutableFilePath() { - const QString qbsInstallRoot = QString::fromLocal8Bit(qgetenv("QBS_INSTALL_ROOT")); - return HostOsInfo::appendExecutableSuffix(QDir::cleanPath(!qbsInstallRoot.isEmpty() - ? qbsInstallRoot + QLatin1String("/bin/qbs") + const QString qbsInstallDir = QString::fromLocal8Bit(qgetenv("QBS_INSTALL_DIR")); + return HostOsInfo::appendExecutableSuffix(QDir::cleanPath(!qbsInstallDir.isEmpty() + ? qbsInstallDir + QLatin1String("/bin/qbs") : QCoreApplication::applicationDirPath() + QLatin1String("/qbs"))); } |