Yocto Programming with CodeBlocks

From Variscite Wiki
Revision as of 12:38, 16 January 2022 by Pierluigi (talk | contribs) (Created page with "<!-- Set release according to "release" parameter in URL and use RELEASE_DUNFELL_V1.7_DART-MX8M-MINI as default --> {{#vardefine:RELEASE_PARAM|{{#urlget:release}}}} <!-- --> {...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
DART-MX8M-MINI - Yocto Programming with Code::Blocks

Code::Blocks is a free C/C++ IDE built around a plugin framework, designed to be very extensible and fully configurable.

This guide demonstrates how to create and debug a C++ application using Code::Blocks on the DART-MX8M-MINI.


Create your rootfs with Code::Blocks debug support

Debugging with Code::Blocks requires your preferred SSH server (openssh, dropbear, etc), gdb, and gdbserver installed on the target device. Append the following to the conf/local.conf file in your Yocto build directory:

EXTRA_IMAGE_FEATURES = " \
    tools-debug \
    ssh-server-dropbear \
    "

Now bitbake your image.

Setup Host Computer Environment

Please follow the steps below to prepare a fresh Ubuntu 20.04 installation for Code::Blocks debugging:

Install Dependencies

$ sudo apt-get -y update
$ sudo apt-get -y install build-essential gdb gdb-multiarch git

Install Code::Blocks

$ sudo apt install codeblocks codeblocks-contrib

Install Yocto Toolchain

A toolchain is necessary for cross compiling applications. To install the toolchain, follow Variscite's Yocto Toolchain installation guide.

Configure Code::Blocks