Hard dependency on libubootenv?

57 views
Skip to first unread message

Christian Eggers

unread,
Sep 27, 2024, 3:51:53 AM9/27/24
to swup...@googlegroups.com
The documentation of meta-swupdate [1] states the libubootenv is not required
if U-Boot is not used as bootloader. But the yocto recipe (swupdate.inc) has
a hard dependency on libubootenv (regardless of CONFIG_UBOOT).

I tried to remove this dependency in my setup, but it seems the libubootenv is
at least required in core/swupdate_vars.c, which is always compiled in.

I suspect that this part of code won't work on my system as I simply doesn't
use U-Boot as bootloader and so don't have an U-Boot environment.

Is there any use of libubootenv on a non U-Boot system? I am currently checking
my rootfs image licenses an trying to get rid of non required packages.

regards,
Christian

[1] https://sbabic.github.io/swupdate/building-with-yocto.html#what-about-libubootenv


Alexander Dahl

unread,
Mar 19, 2025, 7:50:39 AMMar 19
to swupdate
Hei hei,

currently working on packaging swupdate for ptxdist [1] and noticed this as well. This seems to have been introduced with the 2023.12 release. The buildroot package has a hard dependency to libubootenv already. The thing is, it contradicts HAVE_LIBUBOOTENV. Either that one can be removed or the code using libubootenv unconditionally should consider that flag?

Greets
Alex

Stefano Babic

unread,
Mar 20, 2025, 1:43:31 AMMar 20
to Alexander Dahl, swupdate
Hi,

On 19.03.25 12:49, Alexander Dahl wrote:
> Hei hei,
>
> currently working on packaging swupdate for ptxdist [1] and noticed this
> as well. This seems to have been introduced with the 2023.12 release.

The libubootenv is not just used together with U-Boot, but also to store
key / value database just reusing the U-Boot layout. This allows to
store application or specific SWUpdate vars that have nothing to do with
bootloader vars. Linking libubootenv in case of system without U-Boot is
then perfectly plausible.

> The buildroot package has a hard dependency to libubootenv already. The
> thing is, it contradicts HAVE_LIBUBOOTENV.

This is not useful anymore and the library is always linked.

> Either that one can be
> removed or the code using libubootenv unconditionally should consider
> that flag?

Best regards,
Stefano Babic

>
> Greets
> Alex
>
> [1] https://www.ptxdist.org/
>
> Christian Eggers schrieb am Freitag, 27. September 2024 um 09:51:53 UTC+2:
>
> The documentation of meta-swupdate [1] states the libubootenv is not
> required
> if U-Boot is not used as bootloader. But the yocto recipe
> (swupdate.inc) has
> a hard dependency on libubootenv (regardless of CONFIG_UBOOT).
>
> I tried to remove this dependency in my setup, but it seems the
> libubootenv is
> at least required in core/swupdate_vars.c, which is always compiled in.
>
> I suspect that this part of code won't work on my system as I simply
> doesn't
> use U-Boot as bootloader and so don't have an U-Boot environment.
>
> Is there any use of libubootenv on a non U-Boot system? I am
> currently checking
> my rootfs image licenses an trying to get rid of non required packages.
>
> regards,
> Christian
>
> [1] https://sbabic.github.io/swupdate/building-with-yocto.html#what-
> about-libubootenv <https://sbabic.github.io/swupdate/building-with-
> yocto.html#what-about-libubootenv>
>
>
> --
> You received this message because you are subscribed to the Google
> Groups "swupdate" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to swupdate+u...@googlegroups.com
> <mailto:swupdate+u...@googlegroups.com>.
> To view this discussion visit https://groups.google.com/d/msgid/
> swupdate/f929a8e2-91f0-40e0-861d-605392426be3n%40googlegroups.com
> <https://groups.google.com/d/msgid/swupdate/
> f929a8e2-91f0-40e0-861d-605392426be3n%40googlegroups.com?
> utm_medium=email&utm_source=footer>.

Reply all
Reply to author
Forward
0 new messages