0

I have downloaded CodeSourcery Toolchain tools located to the following path:

root@ab-pc:~/arm-2009q1/bin#

arm-none-linux-gnueabi-ar
arm-none-linux-gnueabi-ld arm-none-linux-gnueabi-as
arm-none-linux-gnueabi-c++
arm-none-linux-gnueabi-c++filt
arm-none-linux-gnueabi-cpp
arm-none-linux-gnueabi-g++
arm-none-linux-gnueabi-gcc
arm-none-linux-gnueabi-gcc-4.3.3
arm-none-linux-gnueabi-gcov
arm-none-linux-gnueabi-gdb

and I have exported this path to my PATH variable:

root@ab-pc:~# echo $PATH /root/arm-2009q1/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin

but when I execute the command: root@ab-pc:~# arm-none-linux-gnueabi-gcc -v

-bash: /root/arm-2009q1/bin/arm-none-linux-gnueabi-gcc: No such file or directory

However Which command shows: root@ab-pc:~# which arm-none-linux-gnueabi-gcc /root/arm-2009q1/bin/arm-none-linux-gnueabi-gcc

Can someone explain to me what I am doing wrong and why I take this error?

Many thanks!

  • At a guess the arm-none-linux-gnueabi-xxx tools are 32-bit ELF binaries and you have a 64-bit OS – steeldriver Jan 23 '18 at 16:17
  • Hi steeldriver, yes you are right. Thats true, but I am trying to cross-compile for a 32-bit ARM arch. So, how I can fix this? Need a 32-bit OS? – Ab Abrams Jan 23 '18 at 16:21
  • Try adding the libc6-x32 package to get the 32 bit loader. – ubfan1 Jan 23 '18 at 16:36
  • You may be able to install the necessary 32-bit libraries to make it work - if you see How to install the ARM toolchain? and scroll down to GNU/Linux for example it suggests lib32z1 lib32ncurses5 lib32bz2-1.0 – steeldriver Jan 23 '18 at 16:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.