[yocto] [OE-core] [PATCH v2 1/2] package.bbclass: add prohibited-path qa test

Alexander Kanavin alexander.kanavin at linux.intel.com
Tue Nov 14 04:47:45 PST 2017


On 11/13/2017 09:19 PM, Martyn Welch wrote:
> Sometimes we wish to ensure that packages don't install files or
> directories somewhere that may prove detrimental to the operation of the
> system. For example, this may be the case if files are placed in a
> directory that is utilised as a mount point at run time, thus making them
> inaccessible once when the mount point is being utilised.
> 
> Implement the prohibited-path QA test, which enables such locations to be
> specified in a "PROHIBITED_PATH" variable. This implementation allows for
> exact matches and simple wildcards (paths ending with an asterisk. An
> error will be raised should a match be found, or in the case of a
> wildcard, for any files added below the specificed location(s).

I think this situation is an image configuration problem, not a package 
qa problem. If a package wants to install something in a location that 
is deemed inappropriate by the local config, there's a reason behind it, 
the fix may not be easy to develop, and will likely be useless or even 
unacceptable to other users of the recipe. It's better to reconfigure 
the mount points.

Can you perform this check using IMAGE_QA_COMMANDS please?

On a broader note, we've had an open issue to improve image qa testing 
for a long time, so maybe this could be a first step :)
https://bugzilla.yoctoproject.org/show_bug.cgi?id=10636

Alex



More information about the yocto mailing list