What is the best approach for maintaining image versions in Yocto.
I mean suppose we build an image and given it to customer, in future we provided bug fixes to the customer..
How can we know which version of yocto image customer is using.. Is there any standard way to achieve this..
Thanks for your time. Appreciate your efforts..
For example, we build the Yocto image dr-yocto:18.04 by calling in the directory /public/Work/dr-yocto. I use the Ubuntu version for the tag and the directory path, because the same Ubuntu version works for several Yocto versions.
Check the Yocto Project documentation for more information. Toradex provides some reference images which can be built on their own or then directly be installed with the Toradex Easy Installer. But these images are considered reference images and should not be used in products directly, instead one should derive a custom image from them.
For example, Yocto 2.4 Rocko was released in October 2017. If we use Ubuntu 18.04 or newer for Rocko builds, the builds will fail with strange errors. The same build will work without any problems, if we use Ubuntu 17.04 or older. In the Docker container, we can run the Ubuntu version that best matches the Yocto version.
Is this page helpful? "The Yocto Project is an open source collaboration project that provides templates, tools and methods to help you create custom Linux-based systems for embedded and IOT products, regardless of the hardware architecture." (quoted from: About the Yocto Project ).
You are interested in os-release recipe. This gives provision to add version details to the image. This recipe installs a file /etc/os-release
in the target.
If you are interested in adding custom fields based on your application or purpose of the image, you can add extra fields in OS_RELEASE_FIELDS
variable in os-release.bbappend
in your custom layer. For example,
OS_RELEASE_FIELDS += "BUILD_VERSION"
BUG_FIXED_VERSION = "1.0.0-B1"
BUILD_VERSION = "${BUG_FIXED_VERSION}"
This adds the build id into /etc/os-release
and you can increment the versions based on bug fix or new delivery.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With