DistroKit - A Playground BSP for PTXdist

At Pengutronix we are using PTXdist to automatically integrate many
industrial embedded Linux projects. Some time ago I started DistroKit: This example BSP shall
be able to demonstrate PTXdist features.

For DistroKit, I had these design criteria in mind:

Small BSP, but not opimized for minimum size: Modern Embedded
Linux systems have enough ressources for a certain set of comfort
features; however, DistroKit leaves out anything that does not qualify
as base features.

Modern Linux Userspace: DistroKit makes use of glib, D-Bus,
systemd and NetworkManager.

Multi Platform Support: We support several target devices, such as
Raspberry Pi 1+2, BeagleBone white and black, the RIoT Board,
Udoo Neo and a QEmu supported Versatile Express platform.

During this tutorial I'd like to show you, how to set up DistroKit.

Setting Up a Development Environment

If you like to start playing with DistroKit, the Versatile Express
supported in QEmu is probably a good target device, as you don't need
any hardware. To build the BSP, a cross compiler toolchain is needed;
although you can build it yourself from the sources, we also provide
OSELAS.Toolchain as debian packages, which can easily be installed with:

Ok, in this example, we need ptxdist-2017.07.0, which can be downloaded from
the PTXdist archive server.
Installing PTXdist is a separate step, which can be done with the usual
configure/make/make install. Make sure that you have the ptxdist command in
your path.

Now everything is prepared to build DistroKit from sources.

Building DistroKit

To build DistroKit with ptxdist, you need to select a "platform" first. In
ptxdist terminology, a platform is something you need a dedicated compiler for:
in our case, we can start with the ARM v7a platform:

The "ptxdist images" command instructs ptxdist to build the firmware images for
the selected v7a platform. In order to do so, ptxdist executes many rules that
specify how to fetch, configure and build the involved source packages and does
all necessary steps to build a firmware image.