Skip to content

Buildroot System Customization

The following motherboards are currently supported with Buildroot:

Motherboard SoC Platform System
K4B T113 Allwinner Buildroot

T113

Mount /dev/mmcblk0p1 and replace the bootlogo.bmp file inside.

Auto-Start Configuration

Disabling the QT Application on Boot

On the board, delete S90deviceTest_QT or rename it so it no longer starts with S:

etc/init.d/S90deviceTest_QT
mv etc/init.d/S90deviceTest_QT etc/init.d/D90deviceTest_QT

SDK path:

buildroot/config/buildroot/allwinner/system/busybox-init-base-files/etc/init.d/S90deviceTest_QT

Adding Programs to Run at Boot

On the board, refer to the scripts in etc/init.d/ as a template for writing your own startup scripts.

SDK path:

buildroot/config/buildroot/allwinner/system/busybox-init-base-files/etc/init.d/

Adding Applications

Buildroot does not support package installation via apt. To add or remove tools, you must configure Buildroot through the SDK.

Adding or Removing Buildroot Packages

./build.sh buildroot_menuconfig
# After making changes in the graphical configuration menu, save and exit
./build.sh buildroot_saveconfig
# The configuration is automatically saved to sun8iw20p1_t113_defconfig
# Recompile and repackage
./build.sh && ./build.sh pack

If package removal does not take effect:

rm -rf out/t113/evb1_auto/buildroot/buildroot/target -rf
find out/t113/evb1_auto/buildroot/buildroot -name ".stamp_target_installed" | xargs rm -rf
./build.sh lunch
./build.sh && ./build.sh pack

Adding Custom Applications or Tools

Method 1: Modify the target directory directly after compilation.

t113-linux/out/t113/evb1_auto/buildroot/buildroot/target

Place your files there, then recompile and repackage: ./build.sh && ./build.sh pack.

Method 2: Modify the skeleton directory.

t113-linux/buildroot/buildroot-201902/system/skeleton

Place your files there, then recompile and repackage: ./build.sh && ./build.sh pack.

If the changes do not take effect, clear the cache:

rm -rf out/t113/evb1_auto/buildroot/buildroot/target -rf
find out/t113/evb1_auto/buildroot/buildroot -name ".stamp_target_installed" | xargs rm -rf
./build.sh lunch
./build.sh && ./build.sh pack

Buildroot QT

Configuration Menu

./build.sh buildroot_menuconfig

The QT5 configuration path in Buildroot is as follows:

Target packages
  -> Libraries
    -> Graphics
      -> libdrm
      -> mesa3d
  -> Graphic libraries and applications
    -> Qt5
      -> qt5base
      -> qt5charts
      -> qt5declarative
      -> qt5quickcontrols / qt5quickcontrols2
      -> qt5svg / qt5virtualkeyboard

After configuration, save and exit:

./build.sh buildroot_saveconfig

Compilation

After recompiling, the QT5 libraries will be generated in the out directory. You can use qmake to build QT projects:

out/t113/evb1_auto/buildroot/buildroot/host/bin/qmake

Running on the Board

Set the following environment variables before running a QT application:

export QT_QPA_PLATFORM=linuxfb:tty=/dev/fb0
export QT_QPA_FB_DISABLE_INPUT=1

Q&A

  1. Chinese font display issue: The wqy-zenhei.ttc font package is missing. Download it and place it in /usr/share/fonts/.
  2. Installing the font on Ubuntu: sudo apt install fonts-wqy-zenhei