[OE-core] inherit allarch and use RDEPENDS

Richard Purdie richard.purdie at linuxfoundation.org
Tue Aug 23 15:32:29 UTC 2016


On Tue, 2016-08-23 at 15:15 +0000, Peter Kjellerstedt wrote:
> This is the first I heard about limits to recipes that inherit
> allarch 
> and also use RDEPENDS. So after I read the above, I went and read the
> documentation for the allarch class, which unfortunately did not make
> my understanding much clearer.
> 
> Am I to understand that a recipe that inherits allarch cannot have 
> runtime dependencies on packages that are built differently per 
> architecture or MACHINE? If so, what can it have runtime dependencies
> on? Only other allarch recipes? What are the design limitations 
> behind this and is there anything that could be done to change the
> situation?

It can depend on them, only if you add it to the list of dependencies
in layer.conf, either SIGGEN_EXCLUDERECIPES_ABISAFE or
 SIGGEN_EXCLUDE_SAFE_RECIPE_DEPS. The implication of that is that if
one of these recipes changes, the dependency will not be rebuilt, so
you have to be careful about things like these packages getting
renamed.

Its basically a choice, we can have allarch packages and accept we
can't always rebuild them through the sstate hash changes, or we don't
have allarch packages at all (or have packages that can't have non
-allarch dependencies).


> As an example, say that I have a recipe that only installs a static 
> script, so inheriting allarch is a natural thing to do. However, for 
> this script to work it must call a binary built by another recipe so 
> it of course RDEPENDS on that other package. Are you saying this is 
> wrong? Because that sounds odd to me as it severely limits the 
> usefulness of the allarch class.

You can do this if and only if you list it in layer.conf.

> Another example would be a recipe that installs a static Perl script.
> Can it not inherit allarch while also have a runtime dependency on
> perl?
> 
> If the above is true, why are there no QA tests or similar that catch
> these kind of problems?

We do have sstate hash tests in oe-selftest which would highlight such
a problem.

There are various open bugs complaining about this situation however
I've yet to come up with a way which solves the problem perfectly, much
as I'd like to.

Cheers,

Richard



More information about the Openembedded-core mailing list