RemoteLinux: Compile fix with Qt6

QMap::unite() is gone, the replacement insert() came late, so ask
the preprocessor for help.

Task-number: QTCREATORBUG-24098
Change-Id: I2f596f9a998fa795fe0df378a39c4f1267f4e6e7
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
hjk
2020-08-20 11:25:35 +02:00
parent 5d820b79e6
commit 919dc86c37
2 changed files with 10 additions and 0 deletions

View File

@@ -83,7 +83,13 @@ bool AbstractRemoteLinuxDeployStep::fromMap(const QVariantMap &map)
QVariantMap AbstractRemoteLinuxDeployStep::toMap() const QVariantMap AbstractRemoteLinuxDeployStep::toMap() const
{ {
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
QVariantMap map = BuildStep::toMap();
map.insert(d->deployService->exportDeployTimes());
return map;
#else
return BuildStep::toMap().unite(d->deployService->exportDeployTimes()); return BuildStep::toMap().unite(d->deployService->exportDeployTimes());
#endif
} }
bool AbstractRemoteLinuxDeployStep::init() bool AbstractRemoteLinuxDeployStep::init()

View File

@@ -376,7 +376,11 @@ bool TarPackageCreationStep::fromMap(const QVariantMap &map)
QVariantMap TarPackageCreationStep::toMap() const QVariantMap TarPackageCreationStep::toMap() const
{ {
QVariantMap map = AbstractPackagingStep::toMap(); QVariantMap map = AbstractPackagingStep::toMap();
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
map.insert(m_deployTimes.exportDeployTimes());
#else
map.unite(m_deployTimes.exportDeployTimes()); map.unite(m_deployTimes.exportDeployTimes());
#endif
return map; return map;
} }