When building the project in QtCreator using the Debug configuration,
android deployment procedure pulls app_process from the device to
establish the debug environment. This operation litters the project
build directory with the libraries and executables that don't belong
to it. Instead of pulling the files to the root build directory, it's
better to isolate these files using subdirectory.
Fixes: QTCREATORBUG-29336
Fixes: QTBUG-113851
Fixes: QTBUG-111284
Change-Id: I32c3403dc5f79c42b1ff2bd676c2cf3ae8d43ec3
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
This reverts commit ffd0f7306b.
Reason for revert: Breaks build. Revert is temporary, will be reapplied
after I6eefe739b3aebcef1ece196ff8d70aa36738997b is in
Change-Id: I5029f710656fb89eeaf65b55742678938f249aeb
Reviewed-by: hjk <hjk@qt.io>
If the kit's detected abis list is empty for some reason,
avoid blocking the deployment process.
Fixes: QTCREATORBUG-27103
Change-Id: I9e7b01c123666f087c6d48e56af6e6637e147442
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Reviewed-by: hjk <hjk@qt.io>
The "false" default wasn't really useful.
This changes the default value to the following usages:
1. AndroidDeployQtStep
Introduced in 91f136ef3a
The synchronizer was used to cancel the running tasks inside
the doCancel(), so the similar behavior should be expected
when destructing the AndroidDeployQtStep.
2. GitClient
Introduced in f3106ebafe
Is used only inside the last line of
GitSubmitEditor::updateFileModel(). The running function
(CommitDataFetchResult::fetch) doesn't take QPromise<>,
so it can't detect if the future was canceled or not.
In this case this change is no-op.
3. ExtraCompiler
Introduced in c99ce1f455
The intention was to make it cancellable and finish
early on cancel.
4. PluginManager global future synchronizer
Introduced in 72bddf9f51
The intention was to make it cancellable and finish
early on cancel.
The relevant places in code are marked explicitly for
points: 1, 2 and 3.
Change-Id: I1a52deb8d1f81d355950c8772bbaa6d0a202fd7e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
In case a passed future interface is used only for checking for
cancel, use QFuture<void> instead. This will properly integrate
with QPromise API.
Change-Id: I33e5e9c62dbcfb1f7aa71eace6158e5b7c0a7098
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Fixes and consolidates into one common function the package path
retrieval for the eight combinations of:
(apk|aab)(debug|release)(signed|unsigned)
Fixes: QTCREATORBUG-28791
Change-Id: I6e8c54f555b95aca448032783938f9f7f89bc653
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Since we also license under GPL-3.0 WITH Qt-GPL-exception-1.0,
this applies only to a hypothetical newer version of GPL, that doesn't
exist yet. If such a version emerges, we can still decide to relicense...
While at it, replace (deprecated) GPL-3.0 with more explicit GPL-3.0-only
Change was done by running
find . -type f -exec perl -pi -e "s/LicenseRef-Qt-Commercial OR GPL-3.0\+ OR GPL-3.0 WITH Qt-GPL-exception-1.0/LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0/g" {} \;
Change-Id: I5097e6ce8d10233993ee30d7e25120e2659eb10b
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
And use QFutureInterface for it.
Change-Id: I1145b70b119d92af7316977c813f4f29b1f20b74
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: hjk <hjk@qt.io>
When using BuildStep::runImpl() it was possible for the async part
to still be running while the BuildStep is already deleted.
This change returns the Future so that users can wait for it to finish.
Change-Id: I27c0fc8741c59851c5ab8f5cb858fbcda923c14d
Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
info.cpuAbi in AndroidDeployQtStep::init can be empty, for example when
opening a configured project with a different Qt Creator version, and
the "No valid settings file could be found." message appears.
Check for !empty(), before accessing the first item.
Fixes: QTCREATORBUG-27795
Change-Id: Ife0bf495ed8ea7bfb342300ee2e457398c8ee8f2
Reviewed-by: hjk <hjk@qt.io>
...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>
Replace the current license disclaimer in files by
a SPDX-License-Identifier.
Task-number: QTBUG-67283
Change-Id: I708fd1f9f2b73d60f57cc3568646929117825813
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
- gatherFilesToPull depends on AndroidManager::setDeviceAbis
- use the same path for app_process. gatherFilesToPull pulls app_process
to AndroidManager::buildDirectory(target) which might be different than
activeRunConfig->buildTargetInfo().workingDirectory.
Change-Id: Id47c4380fed5a8b3ad922359e5f9f25e529bacff
Reviewed-by: hjk <hjk@qt.io>
There is no need to keep m_process as a class member,
since it's only used in just one function.
Change-Id: I156b978a18ab25a41b0e52d00fcb90c0f7f12ddd
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
If for some reason the device abi list is empty, don't stop the
deployment, let it continue and potentially fail later.
Amends c1512dce87.
Task-number: QTCREATORBUG-27103
Change-Id: I484fbd1ddb365d5e96686eebc3ba76032684e506
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
If for some reason we cannot get the list of kit's ABIs or it's not set,
don't stop the deployment because of that, let it continue and fail
later.
Fixes: QTCREATORBUG-27103
Change-Id: I973e5ffdca1e8fb6af3f6e6438969b38b8e375c8
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Introduce EventLoopMode enum and pass it to the
QtcProcess::runBlocking() instead. There is no need to
store this setting. By default this value is NoEventLoop.
Change-Id: Icad98b77bec5280b79039b7e5aa4ec408261521c
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
Add error messages for cases in the different steps (e.g. build, deploy,
etc.) for user. This makes it easier for the user to know what's wrong
instead of just failing with no explanation.
Change-Id: I96ea65f5c73edf14c2214b699503211b740d029c
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
The deploy step widget most useful aspect is the uninstall before
deploy checkbox, and having it expanded by default would improve the
UX a bit by avoiding one extra mouse click.
Change-Id: I23ebc90daf9290d229d93dca1b9b25629902e3f2
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
clean, rename and delete unused constants, we well as unify the
usage between qmake, cmake, and qbs.
Change-Id: I8827ac2f2f7660e337694fef17f744e727bd776a
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Currently, on deploy/debug steps on Android, an AndroidDeviceDialog
is popped up each time a deployement is done to select a device. This
can be avoidable by using Qt Creator DeviceKitAspect to have the list
of devices easily selectable from the project mini-menu.
This is better than the current way because it:
* reduces the time from deployment to running the app
* reduces the number of clicks
* avoids having to select the same device each time or
* if a default device is selected, this avoids having to go to project
settings to reset the default device to be able to deploy to a new
device.
* it looks cleaner and more compatible with Creator.
Task-number: QTCREATORBUG-23991
Change-Id: Ida4ab7245c1a3b0ca26c5ccdc9a21a072edf0725
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
With CMake, it seems that the abi was being empty string because
looking for ANDROID_ABIS is not defined and instead there's ANDROID_ABI.
Also make sure to handle the case of ANDROID_ABIS, which might be
declared in future versions like Qt 6.3 which can support multi-abi
builds.
Change-Id: I805c5c25409a4e20a237b8747082d256bd72e275
Reviewed-by: Alessandro Portale <alessandro.portale@qt.io>