1. Does arm-gcc-none-eabi and newlib is packed?
2. Why arm-gcc-none-eabi need glibc 2.14?
I have a problem when I use arm gcc none eabi cross compiler.
"version GLIBC_2.14 not found"
Then I install glibc 2.14 and add to LD_LIBRARY_PATH. It's perfect compile my code.
But I have not download newlib in my system.
I don't know what library is linked on arm-gcc-none-eabi.
Do I need add some option to use newlib when I Compile C code? Or default is linked to newlib.
This web site said arm-gcc-none-eabi is based on Free Software Foundation's (FSF) GNU Open source tools and newlib.
https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-rm/downloads?_ga=2.161423419.782641712.1568254978-323909128.1538373791
Dear sir,
Can you let us know which toolchain you've used what are the commands you were issuing (e.g. how you compiled your "hello world").
Glibc 2.14 is required by your host system so that host tollchain binary can work with it. Newlib is what you've gonna get compiled / linked with your target binary when you compile your target code.So there are two things here, host requirements for your Linux machine you are using to compiler (where you run arm-none-eabi binary). And what is going to be mixed in your target (destination) binary (which is going to be newlib).
Kind regards
/users/ben/Release/arm-gcc/gcc-arm-none-eabi/bin/arm-none-eabi-gcc --specs=nano.specs --specs=nosys.specs -fno-builtin -I . -I /users/ben/coresight/shared/validation/tests/cxdt -I /users/ben/coresight/shared/validation/tests/generic -I /users/ben/coresight/shared/validation/tests/partlib -I /users/ben/coresight/shared/validation/tests/src -DTESTNAME=helloworld -DCPUEXE=1 -DCPU=0 -DCXDT=0 -DCX_MSG_DBG=0 -DCX_MSG_LLDBG=0 -DCX_MSG_VERBOSE=1 -DCP14 -DTRACECODE_CORTEXR8 -g -c -O2 -DTESTIMAGE=0 -DTESTIMAGEARCH_v7r -DTESTIMAGETOOLCHAIN_gcc --verbose -march=armv7-r -std=gnu99 -falign-functions=16 -falign-jumps=8 -falign-loops=8 -fomit-frame-pointer -fno-inline-functions -fno-inline -I./ -o ../bin/helloworld-CXDT-0-CPU-0/IMAGE0_retarget.o gcc_retarget.c 2>&1 | tee ../bin/helloworld-CXDT-0-CPU-0/IMAGE0_retarget.o.log; exit ${PIPESTATUS[0]}
There is a part of GCC command in coresight soc 400 example makefile.
Error message is
/lib64/libc.so.6: version `GLIBC_2.14' not found (required by /users/ben/Release/arm-gcc/gcc-arm-none-eabi/bin/arm-none-eabi-gcc)
--------------
Can I understand like that
1. arm-none-eabi-gcc compiler need GLIB 2.14
2. Compile C code to my target using newlib
3. arm-none-eabi-gcc default library is newlib
Thanks for your help
1) yes2) yes3) please define default library ? default for your code in point (2)
3) I have not download newlib and I not sure what library be used in toolchain. But now I understand. Thank you~
I have last questions.
What case I need to use arm-none-eabi-gcc with newlib?
I see "AArch32/64 bare-metal target (arm-eabi)" toolchain in A profile processor and R , M profile processors toolchain is "arm-none-eabi-gcc"
https://developer.arm.com/tools-and-software/open-source-software/developer-tools/gnu-toolchain/gnu-a/downloads
What are differences between AArch32/64 bare-metal target (arm-eabi) and arm-none-eabi-gcc?
Thanks for your help!
If you download yourself gcc-arm-none-eabi-8-2019-q3-update-linux.tar.bz2 it should be enough to build your application for the specific target.Please note that Newlib is just a C standard library implementation intended for use on embedded systems (as embedded systems have more hardware / resource constrains). So if you use C standard library functions in your code, Newlib implementation of it will be compiled with your code. Please note Newlib does have some limitations in comparison with other implementation of it like glibc or musl.
kind regards
Thanks for your reply!
You are welcome.I've wrote you another reply where I've explained why we have two arm-eabi / arm-none-eabi toolchians. But this was for some reason filtered out by our moderators so it can't be seen.I will try to retrieve this answer so it can be in use for you and others reading this thread.
View all questions in Arm Compilers forum