From e0e64565ad5f046497cadc497a8985ea8cd74e31 Mon Sep 17 00:00:00 2001 From: Alessandro Portale Date: Tue, 17 Jun 2025 17:31:20 +0200 Subject: [PATCH] Android: Fix signing of apks The call of stepList() in AndroidDeployQtStep::init() returns a list of only one deploy step which is not even of the desired type AndroidBuildApkStep. Use buildConfiguration()->buildSteps() to get the build steps. Amends: 995f96f9994aff70db6965a98e6ad665daee78c9 Fixes: QTCREATORBUG-33077 Change-Id: I412e169dd5b620f9e72683f8a5c830baf2630bb7 Reviewed-by: hjk --- src/plugins/android/androiddeployqtstep.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/plugins/android/androiddeployqtstep.cpp b/src/plugins/android/androiddeployqtstep.cpp index 95af3c84651..cfca5335312 100644 --- a/src/plugins/android/androiddeployqtstep.cpp +++ b/src/plugins/android/androiddeployqtstep.cpp @@ -293,7 +293,8 @@ bool AndroidDeployQtStep::init() if (buildType() == BuildConfiguration::Release) m_androiddeployqtArgs.addArgs({"--release"}); - auto androidBuildApkStep = stepList()->firstOfType(); + const auto androidBuildApkStep = + buildConfiguration()->buildSteps()->firstOfType(); if (androidBuildApkStep && androidBuildApkStep->signPackage()) { // The androiddeployqt tool is not really written to do stand-alone installations. // This hack forces it to use the correct filename for the apk file when installing