How to include uEnv.txt in Yocto image

From KoanSoftware Wiki
Jump to: navigation, search

How to include uEnv.txt in Yocto image

If you need to include a custom u-boot environment configuration file for a BeagleBone board, follow these instructions.

Create a new recipe in your custom layer

recipes-bsp/ 
└── u-boot
    ├── files
    │   └── uEnv.txt
    └── u-boot-ti-staging_%.bbappend

Edit the file u-boot-ti-staging_%.bbappend

FILESEXTRAPATHS_prepend := "${THISDIR}/files:"

SRC_URI_append_beaglebone = " file://uEnv.txt"

UBOOT_ENV_beaglebone = "uEnv"


Add your uEnv.txt file into the files directory.

Rebuild

bitbake virtual/bootloader

Now you will have a uEnv.txt in the image directory

Finally add this in local.conf (do not use +=)

IMAGE_BOOT_FILES_append_beaglebone = " uEnv.txt"

And rebuild the image to get a fresh wic containing the uEnv.txt file

bitbake core-image-minimal -C rootfs