* [PATCH] staging: allow special handling of initial-recipes also for native @ 2026-11-19 5:59 Joerg Vehlow 2026-11-23 11:39 ` [OE-core] " Richard Purdie 0 siblings, 1 reply; 6+ messages in thread From: Joerg Vehlow @ 2026-11-19 5:59 UTC (permalink / raw) To: openembedded-core; +Cc: Joerg Vehlow Sometimes a native recipe also needs bootstrapping (e.g. for ada, rust or go) -inital-native recipes are already handled different in bitbake.conf (both suffixes are stripped). During staging for the esdk these packages should also not be staged in the sysroot as they might conflict like libgcc-initial does. Signed-off-by: Joerg Vehlow <joerg.vehlow@emlix.com> --- meta/classes-global/staging.bbclass | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta/classes-global/staging.bbclass b/meta/classes-global/staging.bbclass index 20340a16e1..6438f6bddd 100644 --- a/meta/classes-global/staging.bbclass +++ b/meta/classes-global/staging.bbclass @@ -453,7 +453,7 @@ python extend_recipe_sysroot() { installed = [] for dep in configuredeps: c = setscenedeps[dep][0] - if mytaskname in ["do_sdk_depends", "do_populate_sdk_ext"] and c.endswith("-initial"): + if mytaskname in ["do_sdk_depends", "do_populate_sdk_ext"] and (c.endswith("-initial") or c.endswith("-initial-native")): bb.note("Skipping initial setscene dependency %s for installation into the sysroot" % c) continue installed.append(c) ^ permalink raw reply related [flat|nested] 6+ messages in thread
* Re: [OE-core] [PATCH] staging: allow special handling of initial-recipes also for native 2026-11-19 5:59 [PATCH] staging: allow special handling of initial-recipes also for native Joerg Vehlow @ 2026-11-23 11:39 ` Richard Purdie 2026-11-23 11:46 ` Jörg Vehlow 0 siblings, 1 reply; 6+ messages in thread From: Richard Purdie @ 2026-11-23 11:39 UTC (permalink / raw) To: joerg.vehlow, openembedded-core On Thu, 2026-11-19 at 06:59 +0100, Joerg Vehlow via openembedded-core wrote: > Sometimes a native recipe also needs bootstrapping (e.g. for ada, > rust or go) > -inital-native recipes are already handled different in bitbake.conf > (both suffixes are stripped). > During staging for the esdk these packages should also not be staged > in the sysroot as they might conflict like libgcc-initial does. initial recipes are target/nativesdk only as far as I know. Where are you seeing these -initial-native recipes? Our rust build process doesn't have them, nor does go as far as I can tell? Cheers, Richard ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [OE-core] [PATCH] staging: allow special handling of initial-recipes also for native 2026-11-23 11:39 ` [OE-core] " Richard Purdie @ 2026-11-23 11:46 ` Jörg Vehlow 2026-11-23 11:52 ` Richard Purdie 0 siblings, 1 reply; 6+ messages in thread From: Jörg Vehlow @ 2026-11-23 11:46 UTC (permalink / raw) To: Richard Purdie, openembedded-core Hi Richard On 23.11.2026 12:39, Richard Purdie wrote: > On Thu, 2026-11-19 at 06:59 +0100, Joerg Vehlow via openembedded-core wrote: >> Sometimes a native recipe also needs bootstrapping (e.g. for ada, >> rust or go) >> -inital-native recipes are already handled different in bitbake.conf >> (both suffixes are stripped). >> During staging for the esdk these packages should also not be staged >> in the sysroot as they might conflict like libgcc-initial does. > > initial recipes are target/nativesdk only as far as I know. Where are > you seeing these -initial-native recipes? Our rust build process > doesn't have them, nor does go as far as I can tell? You are right, there is no recipe that currently produces initial-native packages. But we implemented ada and gprbuild support, which is a bit tricky, because like go and rust it uses ada and gprbuild to bootstrap. Ada is even more tricky, because it is not possible (at least not simple) to build a cross gcc with ada support using a different gcc version as the host compiler. For that reason we have a recipe, that fetches a prebuilt gcc with ada support (from alire) and uses that to build gcc-cross. By definition the recipe that fetches the prebuilt gcc is a native package, but also an inital package, hence initial-native. Fro gprbuild something similar applies, an initial version is build using the prebuilt gcc and that initial version then build the real gprbuild used for cross compilation. So we also have a gprbuild-initial-native recipe. For the esdk these native packages are not required and shouldn't be staged, just like other initial-packages. I hope that clarifies the use case, even if it does not apply to what openembedded is currently delivering. > > Cheers, > > Richard ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [OE-core] [PATCH] staging: allow special handling of initial-recipes also for native 2026-11-23 11:46 ` Jörg Vehlow @ 2026-11-23 11:52 ` Richard Purdie 2026-11-23 12:08 ` Jörg Vehlow 0 siblings, 1 reply; 6+ messages in thread From: Richard Purdie @ 2026-11-23 11:52 UTC (permalink / raw) To: Jörg Vehlow, openembedded-core On Mon, 2026-11-23 at 12:46 +0100, Jörg Vehlow wrote: > On 23.11.2026 12:39, Richard Purdie wrote: > > On Thu, 2026-11-19 at 06:59 +0100, Joerg Vehlow via openembedded-core wrote: > > > Sometimes a native recipe also needs bootstrapping (e.g. for ada, > > > rust or go) > > > -inital-native recipes are already handled different in bitbake.conf > > > (both suffixes are stripped). > > > During staging for the esdk these packages should also not be staged > > > in the sysroot as they might conflict like libgcc-initial does. > > > > initial recipes are target/nativesdk only as far as I know. Where are > > you seeing these -initial-native recipes? Our rust build process > > doesn't have them, nor does go as far as I can tell? > > You are right, there is no recipe that currently produces initial-native > packages. But we implemented ada and gprbuild support, which is a bit > tricky, because like go and rust it uses ada and gprbuild to bootstrap. > Ada is even more tricky, because it is not possible (at least not > simple) to build a cross gcc with ada support using a different gcc > version as the host compiler. > For that reason we have a recipe, that fetches a prebuilt gcc with ada > support (from alire) and uses that to build gcc-cross. By definition the > recipe that fetches the prebuilt gcc is a native package, but also an > inital package, hence initial-native. > Fro gprbuild something similar applies, an initial version is build > using the prebuilt gcc and that initial version then build the real > gprbuild used for cross compilation. So we also have a > gprbuild-initial-native recipe. > > For the esdk these native packages are not required and shouldn't be > staged, just like other initial-packages. > > I hope that clarifies the use case, even if it does not apply to what > openembedded is currently delivering. Can you fix the commit message please and perhaps put more of this detail in there? It is a bit of a red flag when the commit message doesn't really match what the code does, it also can cause problems in the future when people look back at why something was done. The other question this leads to, is whether this is a complete fix or are there other changes needed to make "initial" support work better? I really want to see the complete picture of how this is working before we commit to supporting it. Cheers, Richard ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [OE-core] [PATCH] staging: allow special handling of initial-recipes also for native 2026-11-23 11:52 ` Richard Purdie @ 2026-11-23 12:08 ` Jörg Vehlow 2026-11-23 15:17 ` Richard Purdie 0 siblings, 1 reply; 6+ messages in thread From: Jörg Vehlow @ 2026-11-23 12:08 UTC (permalink / raw) To: Richard Purdie, openembedded-core On 23.11.2026 12:52, Richard Purdie wrote: > On Mon, 2026-11-23 at 12:46 +0100, Jörg Vehlow wrote: >> On 23.11.2026 12:39, Richard Purdie wrote: >>> On Thu, 2026-11-19 at 06:59 +0100, Joerg Vehlow via openembedded-core wrote: >>>> Sometimes a native recipe also needs bootstrapping (e.g. for ada, >>>> rust or go) >>>> -inital-native recipes are already handled different in bitbake.conf >>>> (both suffixes are stripped). >>>> During staging for the esdk these packages should also not be staged >>>> in the sysroot as they might conflict like libgcc-initial does. >>> >>> initial recipes are target/nativesdk only as far as I know. Where are >>> you seeing these -initial-native recipes? Our rust build process >>> doesn't have them, nor does go as far as I can tell? >> >> You are right, there is no recipe that currently produces initial-native >> packages. But we implemented ada and gprbuild support, which is a bit >> tricky, because like go and rust it uses ada and gprbuild to bootstrap. >> Ada is even more tricky, because it is not possible (at least not >> simple) to build a cross gcc with ada support using a different gcc >> version as the host compiler. >> For that reason we have a recipe, that fetches a prebuilt gcc with ada >> support (from alire) and uses that to build gcc-cross. By definition the >> recipe that fetches the prebuilt gcc is a native package, but also an >> inital package, hence initial-native. >> Fro gprbuild something similar applies, an initial version is build >> using the prebuilt gcc and that initial version then build the real >> gprbuild used for cross compilation. So we also have a >> gprbuild-initial-native recipe. >> >> For the esdk these native packages are not required and shouldn't be >> staged, just like other initial-packages. >> >> I hope that clarifies the use case, even if it does not apply to what >> openembedded is currently delivering. > > Can you fix the commit message please and perhaps put more of this > detail in there? > > It is a bit of a red flag when the commit message doesn't really match > what the code does, it also can cause problems in the future when > people look back at why something was done. I totally agree with you here, but fail to see where the mismatch is. The commit message states that the special handling for initial is also applied to initial-native. (ok maybe the verb allow is not the right one) > > The other question this leads to, is whether this is a complete fix or > are there other changes needed to make "initial" support work better? This is the only fix that was required to oe-core that was required to make bitbake exclude these initial packages from the esdk.> > I really want to see the complete picture of how this is working before > we commit to supporting it. I get that, but currently I cannot provide the recipes, they are loosely based in meta-adacore, but instead of using a prebuilt gprbuild they build gprbuild in a two step process. Maybe that is what we can focus on and I could try to upload a version of meta-adacore with these recipes for you if you'd like to understand the use case. But essentially: gprbuild is built in a two step process, first it is build using gnat only (gprbuild-initial-native) and then it is built again using the first version as the build tool. Since gprbuild is a build tool (comparable to cmake), it must be a native recipe. The nativesdk variant and the target variant can then be built from the "normal" gprbuild-native. But gprbuild-initial-native is never needed in the esdk and it uses the same paths as gprbuild-native (just for simplicity) and so it has collisions, if both are installed at the same time. Similar collisions would happen, if libgcc-initial and libgcc were installed at the same time - I guess that is the reason why the initial recipes were excluded from the esdk. Since the mechanism already exists and is simply not applied for initial-native, I figured this is a "bug" in oe, that could be fixed without too much background or explaining: Currently target and nativesdk packages, that end in -initial are not installed into the esdk, but native packages are, that feels like an inconsistency, that is fixed by this patch. There is not really a lot more to it. > > Cheers, > > Richard -- emlix GmbH Headquarters: Berliner Str. 12, 37073 Göttingen, Germany Phone +49 (0)551 30664-0, e-mail info@emlix.com District Court of Göttingen, Registry Number HR B 3160 Managing Directors: Heike Jordan, Dr. Uwe Kracke VAT ID No. DE 205 198 055 Office Berlin: Panoramastr. 1, 10178 Berlin, Germany Office Bonn: Bachstr. 6, 53115 Bonn, Germany Office München: Am Knie 16, 81241 München, Germany http://www.emlix.com emlix - your embedded Linux partner ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [OE-core] [PATCH] staging: allow special handling of initial-recipes also for native 2026-11-23 12:08 ` Jörg Vehlow @ 2026-11-23 15:17 ` Richard Purdie 0 siblings, 0 replies; 6+ messages in thread From: Richard Purdie @ 2026-11-23 15:17 UTC (permalink / raw) To: Jörg Vehlow, openembedded-core On Mon, 2026-11-23 at 13:08 +0100, Jörg Vehlow wrote: > On 23.11.2026 12:52, Richard Purdie wrote: > > Can you fix the commit message please and perhaps put more of this > > detail in there? > > > > It is a bit of a red flag when the commit message doesn't really match > > what the code does, it also can cause problems in the future when > > people look back at why something was done. > I totally agree with you here, but fail to see where the mismatch is. > The commit message states that the special handling for initial is also > applied to initial-native. (ok maybe the verb allow is not the right one) Firstly, remove the go and rust mentions as those are in core and don't need this. Secondly, mention you have an external ada implementation and that needs a native initial. Saying what is unique about ada to need this might also help. I don't need to have seen it, I just want it clear this is something external to core and relatively unavoidable. > > The other question this leads to, is whether this is a complete fix or > > are there other changes needed to make "initial" support work better? > This is the only fix that was required to oe-core that was required to > make bitbake exclude these initial packages from the esdk. Ok, you could also mention that in the commit message since it stop me worrying there were more patches coming once this was accepted. > > I really want to see the complete picture of how this is working before > > we commit to supporting it. > > I get that, but currently I cannot provide the recipes, they are loosely > based in meta-adacore, but instead of using a prebuilt gprbuild they > build gprbuild in a two step process. Maybe that is what we can focus on > and I could try to upload a version of meta-adacore with these recipes > for you if you'd like to understand the use case. > > But essentially: gprbuild is built in a two step process, first it is > build using gnat only (gprbuild-initial-native) and then it is built > again using the first version as the build tool. Since gprbuild is a > build tool (comparable to cmake), it must be a native recipe. The > nativesdk variant and the target variant can then be built from the > "normal" gprbuild-native. > But gprbuild-initial-native is never needed in the esdk and it uses the > same paths as gprbuild-native (just for simplicity) and so it has > collisions, if both are installed at the same time. > Similar collisions would happen, if libgcc-initial and libgcc were > installed at the same time - I guess that is the reason why the initial > recipes were excluded from the esdk. > Since the mechanism already exists and is simply not applied for > initial-native, I figured this is a "bug" in oe, that could be fixed > without too much background or explaining: > > Currently target and nativesdk packages, that end in -initial are not > installed into the esdk, but native packages are, that feels like an > inconsistency, that is fixed by this patch. There is not really a lot > more to it. That is fine, by "complete picture", I really just need to know if there are more changes needed and rough idea of why we've not needed this anywhere else. Thanks! Cheers, Richard ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2026-11-23 15:17 UTC | newest] Thread overview: 6+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2026-11-19 5:59 [PATCH] staging: allow special handling of initial-recipes also for native Joerg Vehlow 2026-11-23 11:39 ` [OE-core] " Richard Purdie 2026-11-23 11:46 ` Jörg Vehlow 2026-11-23 11:52 ` Richard Purdie 2026-11-23 12:08 ` Jörg Vehlow 2026-11-23 15:17 ` Richard Purdie
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.