1# 2# Copyright OpenEmbedded Contributors 3# 4# SPDX-License-Identifier: MIT 5# 6 7python mcextend_virtclass_handler () { 8 cls = e.data.getVar("BBEXTENDCURR") 9 variant = e.data.getVar("BBEXTENDVARIANT") 10 if cls != "mcextend" or not variant: 11 return 12 13 override = ":virtclass-mcextend-" + variant 14 15 e.data.setVar("PN", e.data.getVar("PN", False) + "-" + variant) 16 e.data.setVar("MCNAME", variant) 17 e.data.setVar("OVERRIDES", e.data.getVar("OVERRIDES", False) + override) 18} 19 20addhandler mcextend_virtclass_handler 21mcextend_virtclass_handler[eventmask] = "bb.event.RecipePreFinalise" 22 23