1

I have tried installing aarch64-none-elf on my raspberry pi 3B+ from the arm website when I extract it, I can't run the executable files in it.

Here's the error: bash: ./aarch64-none-elf-gcc: cannot execute binary file: Exec format error

Is there any way to fix that error, or download it from another source.

file aarch64-none-elf-gcc returns aarch64-none-elf-gcc: cannot open `aarch64-none-elf-gcc' (No such file or directory)

2
  • Please edit in the output from file aarch64-none-elf-gcc and file $(which file) (the last one is to demonstrate that you are, or are not, running a 64-bit OS).
    – goldilocks
    Jul 28, 2022 at 18:19
  • I've just realised it's 32 bit instead of 64 bit
    – Ben
    Jul 30, 2022 at 13:33

1 Answer 1

0

I've just realised it's 32 bit instead of 64 bit

You can't run 64-bit software on a 32-bit system, obviously. The 64-bit version of RpiOS should run fine on a 3B+, since while I'm not sure if you can compile 64-bit binaries on a 32-bit platform (I'd think so, but could not find discussion of such in a quick online search), that compiler does not have a 32-bit host version for linux.

1
  • Thanks for this. I need to install the 64 bit version of the os, and then I will try it. I didn't realise that it was the 32 bit version
    – Ben
    Jul 30, 2022 at 15:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.