On 30/08/2023 14:19, Richard Purdie wrote:
On Wed, 2023-08-30 at 12:39 +0000, Eilís 'pidge' Ní Fhlannagáin wrote:
[YOCTO #15023]

In this instance (do_populate_sdk with api-documentation turned on),
pseudo is going to end up finding the passwd/groups files in
recipe-sysroot-native which is incorrect and does not have man. The
solution here should be to ensure that pseudo points to the passwd/groups
files in recipe-sysroot (which does have man:man).

Signed-off-by: Eilís 'pidge' Ní Fhlannagáin <pi...@baylibre.com>
---
  scripts/postinst-intercepts/update_mandb | 2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/postinst-intercepts/update_mandb 
b/scripts/postinst-intercepts/update_mandb
index a061bb426a6..6bc073bfff5 100644
--- a/scripts/postinst-intercepts/update_mandb
+++ b/scripts/postinst-intercepts/update_mandb
@@ -13,4 +13,4 @@ PSEUDO_UNLOAD=1 ${binprefix}qemuwrapper -L $D 
$D${bindir}/mandb --config-file $C
rm -f $CONFIG -chown -R man:man $D${localstatedir}/cache/man/
+PSEUDO_PASSWD=$D chown -R man:man $D${localstatedir}/cache/man/

Is there a more general problem here? Wouldn't this issue apply to
other postinst scripts too?

Yes and No. The other postinst scripts if they do attempt to chown, are trying to do it for root:root (which recipe-native-sysroot's passwd and groups obviously have). We could add this to the others as well, just to maintain consistency.

This is all because in image.bbclass, we're setting PSEUDO_PASSWD to STAGING_DIR_NATIVE which I believe normally should be correct, except in an instance like this.

-e


Cheers,

Richard

--
Eilís 'pidge' Ní Fhlannagáin
BayLibre - At the Heart of Embedded Linux
www.baylibre.com

-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#186889): 
https://lists.openembedded.org/g/openembedded-core/message/186889
Mute This Topic: https://lists.openembedded.org/mt/101050953/21656
Group Owner: openembedded-core+ow...@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to