Details
-
Suggestion
-
Resolution: Unresolved
-
P3: Somewhat important
-
None
-
Qt Creator 15.0.0
-
Qt Creator 15.0.0 In Ubuntu 24.0.
Description
I want to smooth the workflow when deploying/running an application in a remote Linux device using Qt Creator and CMake.
If I add CMake presets to my project Qt Creator creates a kit for each `configure` preset.
For example, I have a preset for cross-building an application. I need to set manually on the Qt Creator kit that this project runs in a `Remote Linux Device`. It will be nice to be able to set this from the preset so one can set
```
"toolchainFile": "toolchain.cmake",
"condition": {
"type": "equals",
"lhs": "${hostSystemName}",
"rhs": "Linux"
},
"vendor": {
"qt.io/QtCreator/1.0": {
"debugger":
,
"runDeviceType": "remoteLinux"
}
},
```
So Qt creator will use the default device for "Remote Linux".
Then Qt creator should show the different applications one can run on the left-bottom. By selecting the app and pressing run, Qt creator should deploy all the files defined by CMake Install command of the project(if is a CMake Project) to the remote filesystem by default.
By the presets/CMake, Qt creator can get the `CMAKE_INSTALL_PREFIX` to use on the remote file system.
The current behavior is that no file is deployed by default.
If I add a deploy step `CMake Install` with arguments `--component runtime --prefix install` it will install on the host file system(even when the kit is set to run on a remote device). Then I need to add a deploy step to copy the install directory to the remote file system but this is not working for me.
The only approach working is to use the`Override deployment data from build system` and set the files and the path by hand. This copies the files to the remote filesystem. I did not try the `Custom Process Step` copying the files with a command.
In the case of the run configuration on the remote Linux device, I need to set the `Alternate executable on the device` to run the app on the remote device.
If I set to run `application1` on Qt Creator and Qt Creator knows where it was deployed by using the suggestion of the `CMAKE_INSTALL_PREFIX` then `Alternate executable on the device` configuration should not be needed.
Please take all this as a suggestion, I understand this is complicated, and Qt Creator is trying to be as general as possible.