mirror of
https://git.yoctoproject.org/git/poky
synced 2026-01-01 13:58:04 +00:00
Drop our custom LAYER_CONF_VERSION (since the OE-Core version is now the same) and ensure that poky-sanity's update function runs first so that anyone still using version 5 with poky gets the meta-yocto / meta-yocto-bsp split handled instead of OE-Core's no-op upgrade. Also fix the version check so that the poky 5->6 upgrade is still performed if the latest version is greater than 6. NOTE: this of course relies on the corresponding version bump patch in OE-Core. Fixes [YOCTO #6139]. (From meta-yocto rev: 3e4404c73602e8cb9efca0f6f2ec788ff68046eb) Signed-off-by: Paul Eggleton <paul.eggleton@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
29 lines
1.1 KiB
Plaintext
29 lines
1.1 KiB
Plaintext
# Provide some extensions to sanity.bbclass to handle poky-specific conf file upgrades
|
|
|
|
python poky_update_bblayersconf() {
|
|
current_version = int(d.getVar('LCONF_VERSION', True) or -1)
|
|
latest_version = int(d.getVar('LAYER_CONF_VERSION', True) or -1)
|
|
|
|
bblayers_fn = bblayers_conf_file(d)
|
|
lines = sanity_conf_read(bblayers_fn)
|
|
|
|
if current_version == 5 and latest_version > 5:
|
|
# Handle split out of meta-yocto-bsp from meta-yocto
|
|
if '/meta-yocto-bsp' not in d.getVar('BBLAYERS', True):
|
|
index, meta_yocto_line = sanity_conf_find_line('meta-yocto\s*\\\\\\n', lines)
|
|
if meta_yocto_line:
|
|
lines.insert(index + 1, meta_yocto_line.replace('meta-yocto',
|
|
'meta-yocto-bsp'))
|
|
else:
|
|
sys.exit()
|
|
|
|
current_version += 1
|
|
sanity_conf_update(bblayers_fn, lines, 'LCONF_VERSION', current_version)
|
|
return
|
|
|
|
sys.exit()
|
|
}
|
|
|
|
# Prepend to ensure our function runs before the OE-Core one
|
|
BBLAYERS_CONF_UPDATE_FUNCS =+ "poky_update_bblayersconf"
|