forked from qt-creator/qt-creator
Extend the information on testing Boot to Qt support
Change-Id: If272c564f96b563e207fcc267461937bfa44170d Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -1,6 +1,49 @@
|
|||||||
|
# Testing Boot2Qt with the Hardware Pool
|
||||||
|
|
||||||
|
## Installing the Requirements
|
||||||
|
|
||||||
### Testing Boot2Qt setup without hardware ###
|
On macOS, you need to have Docker Desktop installed, including the Docker CLI.
|
||||||
|
|
||||||
|
Install the Boot to Qt Software Stack for the Qt version and device hardware
|
||||||
|
that you want to test with the Qt Online Installer
|
||||||
|
|
||||||
|
On macOS, the installer might complain about not being able to run docker.
|
||||||
|
If that is the case, copy the command line from the dialog into a Terminal
|
||||||
|
with the Docker CLI in PATH and execute it manually. Choose `Ignore` in the
|
||||||
|
installer dialog when ready.
|
||||||
|
|
||||||
|
## Reserving a Device
|
||||||
|
|
||||||
|
Log into https://hw-controller.qt.io/ with your Qt Account. Choose the
|
||||||
|
appropriate device hardware, select the Qt version that matches what you
|
||||||
|
installed with the Qt Online Installer, state a reason for your device use,
|
||||||
|
choose a reservation duration, and select `Reserve`.
|
||||||
|
|
||||||
|
The device is then provisioned and booted. When ready, make note of the device
|
||||||
|
IP address.
|
||||||
|
|
||||||
|
## Configuring Qt Creator
|
||||||
|
|
||||||
|
Start Qt Creator, open the device options, and add a `Boot to Qt Device`.
|
||||||
|
Give it a name, and provide the IP that you noted when reserving the device.
|
||||||
|
The user is `root`.
|
||||||
|
|
||||||
|
Now you can open or create a project, select the corresponding Boot to Qt kit,
|
||||||
|
and build, run & debug.
|
||||||
|
|
||||||
|
While an application is running on the device, you can use a VNC[^vnc] viewer to
|
||||||
|
connect to the apps UI with the device's IP.
|
||||||
|
|
||||||
|
[^vnc]: The creation of the VNC connection depends on setting
|
||||||
|
`QT_QPA_PLATFORM=vnc` in `/etc/default/qt` on the device. That should
|
||||||
|
be enabled by default for devices created with the web interface.
|
||||||
|
|
||||||
|
## Releasing the Device
|
||||||
|
|
||||||
|
When you are finished with testing, release the reservation of the device
|
||||||
|
in the web interface.
|
||||||
|
|
||||||
|
# Testing Boot2Qt setup without hardware ###
|
||||||
|
|
||||||
It is possible to test Boot2Qt without hardware on a plain Linux host system.
|
It is possible to test Boot2Qt without hardware on a plain Linux host system.
|
||||||
|
|
||||||
@@ -8,12 +51,12 @@ Note: You need an ssh-accessible "root" user on the machine, open X access,
|
|||||||
and must be willing to use it. This is not meant for production environments!
|
and must be willing to use it. This is not meant for production environments!
|
||||||
|
|
||||||
|
|
||||||
# Prepare your machine
|
## Prepare your machine
|
||||||
|
|
||||||
ssh-copy-id -i ~/.ssh/id_??????.pub root@localhost
|
ssh-copy-id -i ~/.ssh/id_??????.pub root@localhost
|
||||||
xhost +
|
xhost +
|
||||||
|
|
||||||
# Get appcontroller source and build
|
## Get appcontroller source and build
|
||||||
|
|
||||||
git clone ssh://codereview.qt-project.org/qt-apps/boot2qt-appcontroller
|
git clone ssh://codereview.qt-project.org/qt-apps/boot2qt-appcontroller
|
||||||
|
|
||||||
@@ -21,12 +64,12 @@ cd boot2qt-appcontroller
|
|||||||
/path/to/qt-base/bin/qt-cmake ...
|
/path/to/qt-base/bin/qt-cmake ...
|
||||||
ninja ...
|
ninja ...
|
||||||
|
|
||||||
# Copy binary to "proper" location
|
## Copy binary to "proper" location
|
||||||
|
|
||||||
sudo ln -s `pwd`/appcontroller /usr/bin/appcontroller
|
sudo ln -s `pwd`/appcontroller /usr/bin/appcontroller
|
||||||
|
|
||||||
|
|
||||||
# Set up "Boot to Qt" Device in Creator
|
## Set up "Boot to Qt" Device in Creator
|
||||||
|
|
||||||
Ensure the "Boot to Qt" plugin is enabled
|
Ensure the "Boot to Qt" plugin is enabled
|
||||||
|
|
||||||
@@ -36,7 +79,7 @@ Device Address: 127.0.0.1
|
|||||||
|
|
||||||
Press "Apply"
|
Press "Apply"
|
||||||
|
|
||||||
# Create a suitable Kit
|
## Create a suitable Kit
|
||||||
|
|
||||||
Clone your standard kit for normal local work
|
Clone your standard kit for normal local work
|
||||||
Change the "Run Device" to LocalHostForBoot2Qt
|
Change the "Run Device" to LocalHostForBoot2Qt
|
||||||
@@ -46,11 +89,11 @@ Press "Apply"
|
|||||||
|
|
||||||
The kit will have a warning the "Device type is not supported by Qt version" - that's ok.
|
The kit will have a warning the "Device type is not supported by Qt version" - that's ok.
|
||||||
|
|
||||||
# Create a test project
|
## Create a test project
|
||||||
|
|
||||||
File -> New Project -> Qt Quick Application
|
File -> New Project -> Qt Quick Application
|
||||||
|
|
||||||
# Tweak project settings
|
## Tweak project settings
|
||||||
|
|
||||||
Deployment method: "Deploy to Boot to Qt Target"
|
Deployment method: "Deploy to Boot to Qt Target"
|
||||||
|
|
||||||
@@ -60,12 +103,12 @@ Run Environment: Add LD_LIBRARY_PATH=/path/to/qt-base/lib
|
|||||||
"Executable on Device" may be red at that stage, it shold get black after a successful build
|
"Executable on Device" may be red at that stage, it shold get black after a successful build
|
||||||
|
|
||||||
|
|
||||||
# Build
|
## Build
|
||||||
|
|
||||||
Ctrl-B
|
Ctrl-B
|
||||||
|
|
||||||
|
|
||||||
# Test
|
## Test
|
||||||
|
|
||||||
At that stage, the program should be runnable, debuggable (C++, QML, and combined QML/C++),
|
At that stage, the program should be runnable, debuggable (C++, QML, and combined QML/C++),
|
||||||
and Qml-Profilable
|
and Qml-Profilable
|
||||||
|
Reference in New Issue
Block a user