Sign up for the KDAB Newsletter
Stay on top of the latest news, publications, events and more.
Go to Sign-up
Find what you need - explore our website and developer resources
27 March 2024
When developing for embedded devices, turnaround times are often long and slow down the development experience. GammaRay - an open-source tool developed by KDAB - might help finding issues without even recompiling. In this video, I explain how to install GammaRay and its -probe on an embedded target.
1. Get GammaRay from https://github.com/KDAB/GammaRay/ check out the right version by either building Host(UI) + (Crosscompile-)Probe or check on host: gammaray --version and use the same githash for the probe.
2. Use your SDK to build:
2.1 For a buildroot SDK, the line is -DCMAKE_TOOLCHAIN_FILE=<()path to buildroot sdk host>/host/share/buildroot/toolchainfile.cmake 2.2 For a Yocto SDK, the line (after sourcing the environment file) is -DCMAKE_TOOLCHAIN_FILE=../gammaray/cmake/Toolchain-Yocto.cmake
3. Cmake-configure your whole GammaRay with -DGAMMARAY_PROBE_ONLY_BUILD=true ##We only want the probe -DGAMMARAY_BUILD_UI=false ##We dont want the UI for the target -DCMAKE_INSTALL_PREFIX=$(pwd) ##We want GammaRay to install itself into our build folder -DCMAKE_BUILD_TYPE=Release ##We want GammaRay to be built in Release-Mode to work as efficient and fast as possible
4. Deploy your build result from lib/gammaray/* to /usr/lib on target. scp -r lib/gammaray/* <()yourtarget>:/usr/lib
5. You can now start your app with the GammaRayProbe inside with LD_PRELOAD=/usr/lib/gammaray/3.0/qt5_15-arm/gammaray_probe.so /path/to/<()yourapp>
6. Done: Connect to <()IP of target> with your Host Gammaray, and you are good! Link to the Install- for Platform-Builders(yocto):https://docs.kdab.com/gammaray-manual/latest/gammaray-install.html#yocto
Links:
* Link to the Install- for Platform-Builders(buildroot): https://docs.kdab.com/gammaray-manual/latest/gammaray-install.html#buildroot
* Link to Gammaray Series: https://www.youtube.com/playlist?list=PL6CJYn40gN6itybeSJb5FvRWOxVW5PCUX
* Link to the Install- for Platform-Builders(yocto):https://docs.kdab.com/gammaray-manual/latest/gammaray-install.html#yocto
All 'Reducing your Qt Embedded development cycle time' videos: https://www.youtube.com/playlist?list=PL6CJYn40gN6gUTZ9kAW7ocyjIVe5QbOUB
All 'Embedded with Qt' videos: https://www.youtube.com/playlist?list=PL6CJYn40gN6iVG059HBoLQZ1CMTyXCGpw