[yocto] [musl] CC option -mmusl in SDK env script but not in default do_compile task

Antoine MANACHE a.manache at gmail.com
Wed Nov 20 02:50:38 PST 2019


Hi all,

I've recently noticed a mismatch between CC options

- set by the SDK environment script

- set by the do_compile task for any 'target' class recipes when the
DISTRO is configured with TCLIBC = "musl"

The SDK env script adds "-mmusl" when exporting CC while do_compile doesn't.

We can see TARGET_CC_ARCH_append_libc-musl = " -mmusl" in file
meta/classes/toolchain-scripts.bbclass, this class is inherited when
building the meta-environment-<MACHINE> recipe (dependancy of the
populate_sdk task of core images).

Can anyone explain what is the aim of this -mmusl option and if required
why this option is not set on both sides ?

I fear this could lead to some situations where applications built from the
SDK and then built with the full Yocto stack don't behave exactly the same.

Thanks

Antoine
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.yoctoproject.org/pipermail/yocto/attachments/20191120/74592af3/attachment.html>


More information about the yocto mailing list