[Buildroot] [PATCH v8 01/10] package/binutils-bare-metal: new package

Frager, Neal neal.frager at amd.com
Thu Dec 14 07:51:03 UTC 2023


Hi Thomas,

> Thank you for your research.  I had not looked into how to fix newlib, 
> so that it installs to the correct place to begin with.
> 
> From my side, I think patching newlib is clearly better because we can 
> try to upstream the patch to newlib.  Once upstream, no patch or fix 
> up hack will be needed anymore when we bump to a newer newlib version.
> 
> I will test this patch with your branch as well to verify that we can 
> remove my fix up post installation hack.  If this patch works, I 
> propose going with the patch.

> Well, the thing is that there is probably a reason why upstream does not install headers/libs in the standard location and decides to go with this custom tooldir thing. So I'm really not sure changing this will be upstreamable. Or perhaps by making it configurable, so that it can be overridden using a ./configure option?

> Thomas

Since we are not sure about this, I will go ahead and try to upstream the patch to the newlib community, and see what they say.

If there is a reason, perhaps they can help us with implementing a configurable solution, as you suggest.  In any case, I think working to upstream a proper solution is still better than my fixup solution.  I only implemented the fixup solution as it was quicker than spending many hours learning the newlib configure script.  Now that you have found the root of the problem, I think patching it upstream is the best option.

By the way, since the bare-metal toolchain no longer has a default architecture, all of the config files in patches 7 and 9 need the following line added:
BR2_TOOLCHAIN_BARE_METAL_BUILDROOT_ARCH="microblazeel-xilinx-elf"

Will I need to submit a v9 for this, or could you just add this config for me to each of the zynqmp and versal config files?

Best regards,
Neal Frager
AMD



More information about the buildroot mailing list