[OE-core] [PATCH] ptest: fix file ownerships in ${PTEST_PATH}

Christopher Larson clarson at kergoth.com
Wed Sep 9 15:45:22 UTC 2015


On Wed, Sep 9, 2015 at 5:38 AM, Mike Looijmans <mike.looijmans at topic.nl>
wrote:

> Just posting a related idea here:
>
> There are quite a few recipes that just contain a bunch of (data) files,
> and use a simple "cp -r" in the install phase. Instead of peppering these
> with "chown" calls, it might be better to create a small utility that
> basically runs the "install" command recursively, and replace the "cp -r"
> with "install_recursive".
>

Something like that doesn't seem unreasonable, so the classes/recipes don't
have to worry about the particulars of the recursive copy tool being used.

That said, doesn't cp -r result in correct ownership, since the files are
created without preserving permissions or ownership? I'm pretty sure it's
the cp -a / cp -pPr that we need to be more concerned with.

Note that with gnu cp, it's possible to tell it to preserve permissions,
but not ownership. It's not portable to non-gnu cp, but I don't know what
we care about that anyway.

Ex.: `cp -a --no-preserve=ownership`
-- 
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openembedded.org/pipermail/openembedded-core/attachments/20150909/b6c1b3b6/attachment-0002.html>


More information about the Openembedded-core mailing list