Bug 5810

Summary: Host Binaries found in native-sdk target sysroot
Product: [Build System, Metadata & Runtime] OE-Core Reporter: Henning Heinold <henning>
Component: coreAssignee: Richard Purdie <richard.purdie>
Status: RESOLVED NOTABUG QA Contact:
Severity: minor    
Priority: Medium CC: david.nystrom, holger, meta.mr.watcher, meta.watcher
Version: 1.5.1   
Target Milestone: 1.6   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description Henning Heinold 2014-02-11 08:00:50 UTC
When build a native-sdk on dora/poky/yocoto for an armv5 device the fowllowing host files are ending up in the arm sysroot


./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin/chsh
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin/newgrp
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin/passwd
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin/opkg
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin/chfn
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin/groups
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/sbin
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/sbin/chpasswd
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/bin
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/bin/su
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/bin/login
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/etc
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/etc/rcS.d
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/etc/rcS.d/S98run-postinsts
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/sbin
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/sbin/vigr
./opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/sbin/vipw
Comment 1 David Nyström 2014-02-11 10:00:38 UTC
How/Why is this a problem ?

Size constraints ?
Comment 2 David Nyström 2014-02-11 10:16:23 UTC
Your ARM5 sysroot should be at location:
./opt/poky/1.5.1/sysroots/*.arm.*-poky-linux/...

What you are referencing above is the "nativesdk" sysroot, 
which should contain only x86_64 binaries. i.e. the cross-compiler and friends.
Comment 3 Henning Heinold 2014-02-13 17:33:48 UTC
Hi,

sorry I cut and pasted from my email to the mailinglist and omitted the parent dir this gives a better view whats wrong

/opt/poky/1.5.1/sysroots# find | grep x86 | less
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin/chsh
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin/newgrp
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin/passwd
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin/opkg
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin/chfn
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/bin/groups
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/sbin
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/sbin/chpasswd
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/bin
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/bin/su
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/bin/login
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/etc
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/etc/rcS.d
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/etc/rcS.d/S98run-postinsts
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/sbin
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/sbin/vigr
./armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/sbin/vipw
Comment 4 Richard Purdie 2014-03-27 17:04:57 UTC
This is by design:

meta/recipes-core/packagegroups$ cat nativesdk-packagegroup-sdk-host.bb | grep shadow
    nativesdk-shadow \

The nativesdk-shadow utils are included so the SDK can be used for running image postinstalls.

If you don't watch this, you can remove that item from the packagegroup.
Comment 5 Holger Freyther 2014-07-29 14:23:42 UTC
(In reply to comment #4)

> The nativesdk-shadow utils are included so the SDK can be used for running
> image postinstalls.
> 
> If you don't watch this, you can remove that item from the packagegroup.

The issue is not that nativesdk-shadow is present but the way it is packaged.

/opt/poky/1.5.1/sysroots/armv5te-poky-linux-gnueabi/opt/poky/1.5.1/sysroots/x86_64-pokysdk-linux/usr/sbin/chpasswd

the path is really odd. Is that really by design? Who will use/consume these binaries?