On Wed, 6 Sept 2023 at 22:13, Richard Purdie
<[email protected]> wrote:
> Firstly, that recipe was a bit of a hack. In bygone times, we had a
> shared sysroot and this was effectively creating it for the places we
> hadn't converted to use recipe specific sysroots. There should only be
> a small number of places it is used where we haven't found a better
> way.
>
> When you use it, the calling code first has to ensure the things it
> wants in the sysroots have been built. The caller is therefore expected
> to build the right set of dependencies.
>
> Putting ordering constraints into the recipe is going to make people
> think it all happens by magic. It doesn't and the caller has to be
> careful.
>
> I'm reluctant to add any dependencies when it should be clear the
> caller is entirely responsible for this.

This commit was prompted by seeing these intermittent races with the
upgraded shadow:

https://autobuilder.yoctoproject.org/typhoon/#/builders/146/builds/468/steps/12/logs/stdio
https://autobuilder.yoctoproject.org/typhoon/#/builders/147/builds/467/steps/12/logs/stdio

What happens here is:
- target sysroot population relies on being able to run useradd
without errors. It will also skip the useradd execution if useradd is
not present.
- useradd comes from the native sysroot
- native sysroot is being populated at the same time as target sysroot
is because the build-sysroots recipe doesn't constrain that
- this can result in races where useradd executable is already there,
but the libraries it needs (libbsd, libattr, libmd) are not

How would the caller ensure this doesn't happen? I think it's
reasonable to assume 'bitbake build-sysroots' should complete without
intermittent failures.

Alex
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#187354): 
https://lists.openembedded.org/g/openembedded-core/message/187354
Mute This Topic: https://lists.openembedded.org/mt/101197363/21656
Group Owner: [email protected]
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[[email protected]]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to