After 9efaf8bae9 commit there was no
possibility to create release package for cmake based builds.
The new cmake variable (QT_ANDROID_DEPLOY_RELEASE) was already added to
allow turning on release build manually
This commit sets the --release flag automatically for androiddeployqt
tool for Release, RelWithDebInfo and MinSizeRel build types.
The --release flag is not set automatically if QT_BUILD_TESTS variable
is set. This is the workaround for tests. Release package need to be
signed. Signing is currently not supported by CI. What is more, also
androidtestrunner is not working on release APKs.
Fixes: QTBUG-112921
Fixes: QTBUG-108132
Task-number: COIN-882
Pick-to: 6.5
Change-Id: Ia81465f4a0f0e5b8dfa50c44028658f7a2346c1a
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>