forked from qt-creator/qt-creator
Android: Don't add contains(ANDROID_TARGET_ARCH,..) scope for Qt 5.14
Starting with Qt 5.14 we don't need "contains(ANDROID_TARGET_ARCH" scope as we are doing multi abi builds in one go, therefore contains(ANDROID_TARGET_ARCH,...) won't work anymore. Fixes: QTBUG-79948 Change-Id: Icc989e4dfd48c765340569dcb547e8d0d2b1e8f1 Reviewed-by: Cristian Adam <cristian.adam@qt.io>
This commit is contained in:
committed by
BogDan Vatra
parent
23de4630fc
commit
6954e51174
@@ -32,6 +32,9 @@
|
||||
#include <projectexplorer/runconfiguration.h>
|
||||
#include <projectexplorer/target.h>
|
||||
|
||||
#include <qtsupport/baseqtversion.h>
|
||||
#include <qtsupport/qtkitinformation.h>
|
||||
|
||||
#include <resourceeditor/resourcenode.h>
|
||||
|
||||
#include <utils/qtcassert.h>
|
||||
@@ -358,11 +361,16 @@ bool QmakeProFileNode::setData(Core::Id role, const QVariant &value) const
|
||||
QmakeProFile *pro = proFile();
|
||||
if (!pro)
|
||||
return false;
|
||||
|
||||
QString scope;
|
||||
int flags = QmakeProjectManager::Internal::ProWriter::ReplaceValues;
|
||||
if (Target *target = m_project->activeTarget()) {
|
||||
QtSupport::BaseQtVersion *version = QtSupport::QtKitAspect::qtVersion(target->kit());
|
||||
if (version && version->qtVersion() < QtSupport::QtVersionNumber(5, 14, 0)) {
|
||||
const QString arch = pro->singleVariableValue(Variable::AndroidArch);
|
||||
const QString scope = "contains(ANDROID_TARGET_ARCH," + arch + ')';
|
||||
auto flags = QmakeProjectManager::Internal::ProWriter::ReplaceValues
|
||||
| QmakeProjectManager::Internal::ProWriter::MultiLine;
|
||||
scope = "contains(ANDROID_TARGET_ARCH," + arch + ')';
|
||||
flags |= QmakeProjectManager::Internal::ProWriter::MultiLine;
|
||||
}
|
||||
}
|
||||
|
||||
if (role == Android::Constants::AndroidExtraLibs)
|
||||
return pro->setProVariable("ANDROID_EXTRA_LIBS", value.toStringList(), scope, flags);
|
||||
|
Reference in New Issue
Block a user