Yocto Linux build system (bitbake) adopts highly sophisticated override syntax using : or _ to efficiently describe what we want to do. This significantly reduce the amount of bb/bbappend code because we do not have to write explicit branching scripts at all in many cases. However, the problem is that key operator character had been changed from _ to : since a version of Yocto distribution. The conversion is available for forward distribution upgrade. But backward one is still not available in official distribution as far as I observed.

The conversion method is too simple to wait or search formal conversion tools. I wrote simple script below to skip boring manual backward conversion tasks, when I was working on porting tasks from newer recipes syntax to old one.

#!/usr/bin/env bash

[[ -f $1 ]] || exit
sed -i "s=^\([A-Z]*\)\:=\1_=g" "$1"
sed -i "s=\:\(append\)=_\1=g" "$1"
sed -i "s=\:\(prepend\)=_\1=g" "$1"

This script can be used with wrapping one liner like

find meta* -name "*.bb*" | xargs -n1 dunfellize.sh

dunfellize.sh contains above script. There are many room to update and improve but it just works now !!!