Skip to main content

Yocto 6.0 (Wrynose) Build Guide for Advantech NXP BSP

Overview​

This document provides the required steps to build the Yocto 6.0 (Wrynose) BSP for Advantech NXP platforms using the NXP Yocto release 6.18.20-2.0.0 and the Advantech meta layer.

The guide covers environment preparation, repository initialization, BSP layer integration, supported machine configuration, image building, output verification, and deployment to SD cards.


Scope​

This procedure is intended for Advantech NXP boards supported by the Yocto 6.0 (Wrynose) release. It is applicable to the following supported machine configurations:

  • i.MX 8M Plus
  • i.MX 93
  • i.MX 8ULP
  • i.MX 95

Prerequisites​

  • Ubuntu 22.04 or 24.04 host system
  • 16 GB RAM minimum; 32 GB recommended
  • 500 GB free disk space recommended
  • Git, Docker, Python, and standard Yocto build dependencies
  • Access to the NXP Yocto manifest repository
  • Access to the Advantech Azure DevOps repository for meta-advantech-nxp

Build Environment​

The recommended build environment is a Docker-based setup on an Ubuntu host system:

$ sudo sysctl -w kernel.apparmor_restrict_unprivileged_userns=0
$ docker run --privileged -it --name wrynose-6.18.20-2.0.0 \
-v <workspace_path>:/home/adv:rw \
-v /dev:/dev \
advrisc/u22.04-imx9lbv1:latest /bin/bash

Replace <workspace_path> with the actual path on the host machine where the Yocto workspace is stored.


Step 1: Initialize the Yocto Environment​

Configure Git and create the working directory:

$ git config --global user.name "Your Name"
$ git config --global user.email "Your Email"
$ git config --list

$ mkdir imx-yocto-bsp
$ cd imx-yocto-bsp

Git SSL and Protocol Notes​

If a certificate verification error or Git protocol warning occurs, run the following commands:

$ export GIT_SSL_NO_VERIFY=1
$ git config --global http.sslverify false
$ git config --global url."https://".insteadOf git://

Initialize the Yocto manifest and synchronize the source tree:

$ repo init -u https://github.com/nxp-imx/imx-manifest -b imx-linux-wrynose -m imx-6.18.20-2.0.0.xml
$ repo sync -j$(nproc)

Step 2: Add the Advantech Meta Layer​

Clone the Advantech BSP layer into the sources directory:

$ cd sources
$ git clone https://AIM-Linux@dev.azure.com/AIM-Linux/meta-advantech-nxp/_git/meta-advantech-nxp -b wrynose-6.18.20-2.0.0
$ cd ..

If the clone operation fails, confirm that the Azure DevOps account has the required access permissions for the repository.


Step 3: Build the Yocto Image​

The following example demonstrates the XWayland build flow for the RSB-3720 board (imx8mprsb3720a2):

$ MACHINE=imx8mprsb3720a2 DISTRO=fsl-imx-xwayland EULA=1 source ./imx-setup-release.sh -b build_rsb3720

Add the Advantech BSP layer:

$ bitbake-layers add-layer ../sources/meta-advantech-nxp

Start the build:

$ bitbake imx-image-full

Supported Machine Configurations​

BoardSoCMachine nameBuild command
RSB-3720i.MX 8M Plusimx8mprsb3720a2MACHINE=imx8mprsb3720a2 DISTRO=fsl-imx-xwayland EULA=1 source ./imx-setup-release.sh -b build_rsb3720
ROM-5722i.MX 8M Plusimx8mprom5722a1MACHINE=imx8mprom5722a1 DISTRO=fsl-imx-xwayland EULA=1 source ./imx-setup-release.sh -b build_rom5722
ROM-2820i.MX 93imx93rom2820a1MACHINE=imx93rom2820a1 DISTRO=fsl-imx-xwayland EULA=1 source ./imx-setup-release.sh -b build_rom2820
AFE-E420i.MX 93imx93afee420a1MACHINE=imx93afee420a1 DISTRO=fsl-imx-xwayland EULA=1 source ./imx-setup-release.sh -b build_afee420
ROM-2620i.MX 8ULPimx8ulprom2620a1MACHINE=imx8ulprom2620a1 DISTRO=fsl-imx-xwayland EULA=1 source ./imx-setup-release.sh -b build_rom2620
AOM-5521i.MX 95imx95aom5521a2MACHINE=imx95aom5521a2 DISTRO=fsl-imx-xwayland EULA=1 source ./imx-setup-release.sh -b build_aom5521
AOM-2521i.MX 95imx95aom2521b0MACHINE=imx95aom2521b0 DISTRO=fsl-imx-xwayland EULA=1 source ./imx-setup-release.sh -b build_aom2521

Verify Output​

After a successful build, verify the generated image in the build output directory:

$ ls build_<board>/tmp/deploy/images/<machine>/

The build output should include a .wic or .wic.zst image, depending on the selected image type and compression configuration.

Example output path:

$ ls build_rsb3720/tmp/deploy/images/imx8mprsb3720a2/

Flash to SD Card​

The generated image can be written to an SD card with the following command:

$ zstd -d imx-image-full-<machine>.wic.zst
$ sudo dd if=imx-image-full-<machine>.wic of=/dev/sdX bs=4M status=progress conv=fsync

Warning: Verify the target device path before running dd. Writing to the wrong disk may overwrite critical data.


Troubleshooting​

  • repo sync fails: verify network connectivity, the correct manifest branch, and sufficient disk space
  • git clone fails: confirm Azure DevOps access and the correct repository branch name
  • bitbake-layers add-layer fails: confirm that ../sources/meta-advantech-nxp exists in the expected location
  • Build fails: verify that the Yocto environment was sourced correctly and that the Docker container contains the required packages

  • NXP Yocto release notes
  • Advantech BSP documentation
  • Board-specific deployment instructions for each supported platform