We let kernel recipes name their packages something unique: kernel.bbclasss: KERNEL_PACKAGE_NAME ??= "kernel" But if the name isn't "kernel" then they don't provide virtual/kernel, so can't be really be used if all of the valid kernels have a name set: kernel.bbclasss: PROVIDES += "${@ "virtual/kernel" if (d.getVar("KERNEL_PACKAGE_NAME") == "kernel") else "" }" I believe that line should just be PROVIDES += "virtual/kernel".
This is to allow multiple kernels to be built reusing the class code. We don't want two kernels to PROVIDE virtual/kernel so I'd say this is not a bug...
We should decide on this in 2.8. Is it a bug or not. Having just been through all this code myself, I'm also inclined to say not a bug.
Will start running tests with the simplest of changes and see if anything breaks.
merged to oe-core (now we wait to see if some unaccounted for case fails).