This is the mail archive of the
newlib@sourceware.org
mailing list for the newlib project.
Re: building libc_nano and libg_nano
Thanks, this was very helpful.
I’ve made a lot of progress — though it was painful. I’d been trying to build GCC 8.2, but still has an issue with ARMv8 and picking up an “include_next <stdint.h>” during the bootstrap build. Found information about this issue here:
<https://bugs.launchpad.net/gcc-arm-embedded/+bug/1717502>
and basically realized I might not need to blaze this trail quite so aggressively.
I decided to retrench and build the GCC ARM tag from that build:
svn co svn:://gcc.gnu.org/svn/gcc/tags/ARM/embedded-7-branch-2018q2
I’m now part way through building the “full” GCC, and I’m hopeful it’ll make it through.
One thing I noticed from your recommendation — when I built newlib and newlib nano (which I was doing immediately after building the GCC bootstrap), I did not get libstdc++ or libsupc++. Reading your script, it looks like you do an ADDITIONAL GCC bootstrap build immediately after building newlib nano libraries, and I’m guessing that’s why I don’t have them.
Your script does indeed do pretty much everything I need to do and more although I was really trying to roll my own because I wanted to understand what was going on. Thanks for this valuable asset. I will see if I can give it a whirl on my Mac.
Rob
> On Nov 18, 2018, at 12:05 AM, Freddie Chopin <freddie_chopin@op.pl> wrote:
>
> On Sat, 2018-11-17 at 16:38 -0800, Robert Newberry wrote:
>> I looked at the launchpad logs (per the stackoverflow suggestion) and
>> can see a spot, just after "make install", in that does thew
>> following:
>>
>> cp -f /<<PKGBUILDDIR>>/build-native/target-libs/arm-none-
>> eabi/lib/./libc.a /<<PKGBUILDDIR>>/install-native/arm-none-
>> eabi/lib/./libc_nano.a
>>
>> but I don't find anything like this in the "newlib" sources.
>>
>> Is this magic available somewhere? If I try to replicate it by hand,
>> I'm afraid I'll goof it up...
>
> There's nothing in newlib sources that does the copying. You are
> supposed to do this by hand. This is also the same thing I'm doing in
> my bleeding-edge-toolchain script:
>
> https://github.com/FreddieChopin/bleeding-edge-toolchain
>
> around line 487 of the main script there's the copying. But please note
> that it is not only newlib's libc that has to be compiled differently,
> renamed and copied to proper places - this also affects 4 other .a
> archives.
>
> BTW - from what you wrote it seems that you try to accomplish the same
> goal as my bleeding-edge-toolchain script (; I never used it on Mac,
> but maybe you could give it a try if you find it interesting and then
> let me know whether it worked or not? (;
>
> Regards,
> FCh
>