forked from qt-creator/qt-creator
Android: Make Bundle Qt Deployment the default deployment method.
Debug Deployment broke with Android 5. Also show Android 5 devices as incompatible in the device dialog if we are using debug deployment. Task-number: QTCREATORBUG-13419 Change-Id: Ic321cfa46eb724f87f338af9c4b50face06c7c06 Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com> Reviewed-by: BogDan Vatra <bogdan@kde.org> Reviewed-by: Daniel Teske <daniel.teske@theqtcompany.com>
This commit is contained in:
@@ -176,8 +176,19 @@ bool AndroidDeployQtStep::init()
|
||||
emit addOutput(tr("No Android arch set by the .pro file."), ErrorOutput);
|
||||
return false;
|
||||
}
|
||||
|
||||
AndroidBuildApkStep *androidBuildApkStep
|
||||
= AndroidGlobal::buildStep<AndroidBuildApkStep>(target()->activeBuildConfiguration());
|
||||
if (!androidBuildApkStep) {
|
||||
emit addOutput(tr("Cannot find the android build step."), ErrorOutput);
|
||||
return false;
|
||||
}
|
||||
|
||||
m_deviceAPILevel = AndroidManager::minimumSDK(target());
|
||||
AndroidDeviceInfo info = AndroidConfigurations::showDeviceDialog(project(), m_deviceAPILevel, m_targetArch);
|
||||
AndroidConfigurations::Options options = AndroidConfigurations::None;
|
||||
if (androidBuildApkStep->deployAction() == AndroidBuildApkStep::DebugDeployment)
|
||||
options = AndroidConfigurations::FilterAndroid5;
|
||||
AndroidDeviceInfo info = AndroidConfigurations::showDeviceDialog(project(), m_deviceAPILevel, m_targetArch, options);
|
||||
if (info.serialNumber.isEmpty()) // aborted
|
||||
return false;
|
||||
|
||||
@@ -205,12 +216,6 @@ bool AndroidDeployQtStep::init()
|
||||
ProjectExplorer::ProcessParameters *pp = processParameters();
|
||||
m_useAndroiddeployqt = version->qtVersion() >= QtSupport::QtVersionNumber(5, 4, 0);
|
||||
if (m_useAndroiddeployqt) {
|
||||
AndroidBuildApkStep *androidBuildApkStep
|
||||
= AndroidGlobal::buildStep<AndroidBuildApkStep>(target()->activeBuildConfiguration());
|
||||
if (!androidBuildApkStep) {
|
||||
emit addOutput(tr("Cannot find the android build step."), ErrorOutput);
|
||||
return false;
|
||||
}
|
||||
Utils::FileName tmp = AndroidManager::androidQtSupport(target())->androiddeployqtPath(target());
|
||||
if (tmp.isEmpty()) {
|
||||
emit addOutput(tr("Cannot find the androiddeployqt tool."), ErrorOutput);
|
||||
|
||||
Reference in New Issue
Block a user