[OE-core] [PATCH] wpa-supplicant: add virtual supplicant

Maxime Roussin-Bélanger maxime.roussinbelanger at gmail.com
Thu Feb 13 15:54:33 UTC 2020


On Thu, Feb 13, 2020 at 10:27 AM Richard Purdie <
richard.purdie at linuxfoundation.org> wrote:
>
> On Thu, 2020-02-13 at 10:22 -0500, Maxime Roussin-Bélanger wrote:
> > On Thu, Feb 13, 2020 at 9:24 AM Richard Purdie <
> > richard.purdie at linuxfoundation.org> wrote:
> > > I know its not easy to understand but we don't support virtual/*
> > > names in the runtime namespace, only the build time one
> > > (PROVIDES/DEPENDS).
> > > Grep for VIRTUAL-RUNTIME to see how we handle this (its ugly I
> > know).
> >
> > Hmm interesting!
> >
> > If I follow correctly that's mean I have to create:
> >
> > VIRTUAL-RUNTIME_wireless-daemon and then people can override it.
>
> Correct.
>
> > If the (R)DEPENDS on a recipe change depending on the wireless daemon
> > that
> > was chosen(i.e. connman), do you handle it with d.getVar and
> > d.setVar("DEPENDS... inside a
> > anonymous python function inside the recipe?
> >
> > The packageconfig would like this ?
> >
> > PACKAGECONFIG[wifi] = "--enable-wifi, --disable-wifi, ${VIRTUAL-
> > RUNTIME_wireless-daemon}, ${VIRTUAL-RUNTIME_wireless-daemon}"
> >
> > Example:
> >
> > if VIRTUAL-RUNTIME_wireless-daemon == "iwd":
> >     DEPENDS += "iwd"
> >     EXTRA_OECONF += "--enable-iwd"
> > elif VIRTUAL-RUNTIME_wireless-daemon == "wpa-supplicant":
> >     DEPENDS += "wpa-supplicant"
>
> At this point it suggests they're not interchangeable and therefore not
> simple runtime switchable dependencies.
>
> The closest analogy is the "ld-is-gold" DISTRO_FEATURE when you have
> something that isn't compatible like this.

I realize that my example isn't the proper one.. sorry about that! We can
probably
simplify with PACKAGECONFIG.

Maybe the right solution would be to provide two packageconfig?

PACKAGECONFIG[iwd] = "--enable-iwd, --disable-wifi, iwd, iwd"
PACKAGECONFIG[wpa-supplicant] = "--enable-wifi, --disable-wifi,
wpa-supplicant, wpa-supplicant"

They are mutually exclusive, is this something that can be done through
PACKAGECONFIG?

Maybe we don't deal with the conflicts that can occur if a user activates
both? It would probably
fail at configure time? What is good practice here?

At the same time, it is VERY weird for a system to have iwd and
wpa_supplicant. If I recall correctly,
iwd has an error message with another wireless daemon run concurrently.

I would like to be able to force the user to choose only one... because I
think having both is an error.


Thanks,
Max.

>
> Cheers,
>
> Richard
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20200213/79437ec9/attachment-0001.html>


More information about the Openembedded-core mailing list