All of lore.kernel.org
 help / color / mirror / Atom feed
* preserving file owners in do_package
@ 2013-10-15 10:02 Davide Soldan
  2013-10-15 10:38 ` Paul Eggleton
  0 siblings, 1 reply; 9+ messages in thread
From: Davide Soldan @ 2013-10-15 10:02 UTC (permalink / raw)
  To: yocto@yoctoproject.org

[-- Attachment #1: Type: text/plain, Size: 1139 bytes --]

Hi to all,
in my recipe I want to change owner and permission of a file, so I wrote:

do_install() {
        ls -la ${D}/opt/user
        chown -R user ${D}/opt/user
        chgrp -R user ${D}/opt/user
        ls -la ${D}/opt/user
        chmod 754 ${D}/opt/user/user.sh
        ls -la ${D}/opt/user
}

the output of ls commands is: 

drwxr-xr-x 8 root root   4096 Oct 15 11:13 .
drwxr-xr-x 3 root root   4096 Oct 15 11:13 ..
-rw-r--r-- 1 *root root*  55753 Aug  2 08:48 user.sh

drwxr-xr-x 8 user user   4096 Oct 15 11:13 .
drwxr-xr-x 3 root     root       4096 Oct 15 11:13 ..
-rw-r--r-- 1 *user user*  55753 Aug  2 08:48 user.sh

drwxr-xr-x 8 user user   4096 Oct 15 11:13 .
drwxr-xr-x 3 root     root       4096 Oct 15 11:13 ..
*-rwxr-xr--* 1 user user  55753 Aug  2 08:48 user.sh

So the change of owner and permission works fine in do_install phase.
Opening the final rootfs tarball, however, the file user.sh has still 754 permission but root as owner...so do_package doesn't preserve owner change done in do_install? Or maybe I'm doing something wrong in changing file owner? Any ideas?
Thanks to all!

[-- Attachment #2: Type: text/html, Size: 5751 bytes --]

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2013-10-18 13:58 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-10-15 10:02 preserving file owners in do_package Davide Soldan
2013-10-15 10:38 ` Paul Eggleton
2013-10-15 10:50   ` Davide Soldan
2013-10-15 16:12   ` Davide Soldan
2013-10-15 16:18     ` Paul Eggleton
2013-10-15 21:54       ` Paul Eggleton
2013-10-18 13:31       ` Davide Soldan
2013-10-18 13:38         ` Paul Eggleton
2013-10-18 13:57           ` Davide Soldan

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.