mirror of
https://git.yoctoproject.org/poky
synced 2026-01-29 21:08:42 +01:00
mcextend: Add helper class useful for multiconfig
This class allows users to easily create multiconfig BBCLASSEXTEND recipes and is generally useful. It will be used by new tests so add as a general feature. (From OE-Core rev: 9ad19eb12c24d1ddc967215af0ebafd2cd2cb665) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
16
meta/classes/mcextend.bbclass
Normal file
16
meta/classes/mcextend.bbclass
Normal file
@@ -0,0 +1,16 @@
|
||||
python mcextend_virtclass_handler () {
|
||||
cls = e.data.getVar("BBEXTENDCURR")
|
||||
variant = e.data.getVar("BBEXTENDVARIANT")
|
||||
if cls != "mcextend" or not variant:
|
||||
return
|
||||
|
||||
override = ":virtclass-mcextend-" + variant
|
||||
|
||||
e.data.setVar("PN", e.data.getVar("PN", False) + "-" + variant)
|
||||
e.data.setVar("MCNAME", variant)
|
||||
e.data.setVar("OVERRIDES", e.data.getVar("OVERRIDES", False) + override)
|
||||
}
|
||||
|
||||
addhandler mcextend_virtclass_handler
|
||||
mcextend_virtclass_handler[eventmask] = "bb.event.RecipePreFinalise"
|
||||
|
||||
Reference in New Issue
Block a user