RDEPENDS of something provided by ALTERNATIVE


Richard Purdie
 

On Wed, 2022-08-03 at 09:25 +0200, Martin Jansa wrote:
You can use VIRTUAL-RUNTIME_sed variable instead of 'sed'
_everywhere_ and then change the preferred runtime provider in your
DISTRO config.

Similar case for "stat" from busybox in webOS OSE:
https://github.com/webosose/meta-webosose/search?q=VIRTUAL-RUNTIME_stat

and much worse case (because too many places add runtime dependency
on bash) to replace bash:
https://github.com/webosose/meta-webosose/search?q=VIRTUAL-RUNTIME_bash
see
https://bugzilla.yoctoproject.org/show_bug.cgi?id=9217#c5
This is where we should perhaps think about the filter variable option
Joshua and I have talked about periodically as that could handle this
in a much neater and generic way, at the unfortunate cost of
complexity.

The multilib code already tries to do this kind of remapping.

Cheers,

Richard


Martin Jansa
 

You can use VIRTUAL-RUNTIME_sed variable instead of 'sed' _everywhere_ and then change the preferred runtime provider in your DISTRO config.

Similar case for "stat" from busybox in webOS OSE:

and much worse case (because too many places add runtime dependency on bash) to replace bash:
see

Regards,

On Wed, Aug 3, 2022 at 7:03 AM Craig McQueen <craig.mcqueen@...> wrote:
I have a recipe which contains a script that uses /bin/sed.

When I build it, I get an error:

ERROR: myrecipe-1.2.3-r0 do_package_qa: QA Issue: /lib/myrecipe/mycommand contained in package myrecipe requires /bin/sed, but no providers found in RDEPENDS:myrecipe? [file-rdeps]

My final image contains the BusyBox implementation of sed, so it will be fine at runtime.

If I add to my recipe RDEPENDS:${PN} += "sed", then when the image is built then it uses /bin/sed from the "sed" package, rather than being happy to use the BusyBox sed.

So, what is the correct way to specify a RDEPENDS to say that it depends on _any_ implementation of /bin/sed from any ALTERNATIVE provider?

--
Craig McQueen



 
 

 

Craig McQueen
Embedded Systems Engineer

t
e
w
:
:
:
+61 3 9780 4378
craig.mcqueen@...
innerrange.com
 Inner Range • 1 Millennium Court • Knoxfield • Victoria • 3180 • Australia 

 

 





Craig McQueen
 

I have a recipe which contains a script that uses /bin/sed.

When I build it, I get an error:

ERROR: myrecipe-1.2.3-r0 do_package_qa: QA Issue: /lib/myrecipe/mycommand contained in package myrecipe requires /bin/sed, but no providers found in RDEPENDS:myrecipe? [file-rdeps]

My final image contains the BusyBox implementation of sed, so it will be fine at runtime.

If I add to my recipe RDEPENDS:${PN} += "sed", then when the image is built then it uses /bin/sed from the "sed" package, rather than being happy to use the BusyBox sed.

So, what is the correct way to specify a RDEPENDS to say that it depends on _any_ implementation of /bin/sed from any ALTERNATIVE provider?

--
Craig McQueen



 
 

 

Craig McQueen
Embedded Systems Engineer

t
e
w
:
:
:
+61 3 9780 4378
craig.mcqueen@...
innerrange.com
 Inner Range • 1 Millennium Court • Knoxfield • Victoria • 3180 • Australia