forked from qt-creator/qt-creator
Android: set release flag when building and deploying apk
...in Release builds Signed Release builds are now deployed correctly by giving androiddeployqt the --release flag during the Deployment step for Release builds. Unsigned Release apks are now correctly built under the release directory by giving androiddeployqt the --release flag during the Build step for Release builds instead of determining build type from whether or not the package is signed. Fixes: QTCREATORBUG-28163 Change-Id: I319bc95325c88fb84a5997c9237df65eb7983c0e Reviewed-by: Alessandro Portale <alessandro.portale@qt.io> Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
This commit is contained in:
@@ -261,6 +261,9 @@ bool AndroidDeployQtStep::init()
|
||||
|
||||
m_androiddeployqtArgs.addArg("--gradle");
|
||||
|
||||
if (buildType() == BuildConfiguration::Release)
|
||||
m_androiddeployqtArgs.addArgs({"--release"});
|
||||
|
||||
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
|
||||
|
||||
Reference in New Issue
Block a user