Closed codernavi18 closed 2 years ago
Strange, I tried to reproduce the error but couldn't. I moved the directory to the same location and it still worked. What modification did you do to fix this? Just curious to know what could have caused this.
Hi, I just got the same error. And I did a little digging....
$ file ../cross_compiler/bin/arm-none-eabi-gcc ../cross_compiler/bin/arm-none-eabi-gcc: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux.so.2, for GNU/Linux 2.6.16, stripped
$ uname -mo x86_64 GNU/Linux
Err... my OS is a 64-bit Linux Mint
@rfrankla @codernavi18 What steps did you do? Here are the commands I did from my ~/Downloads directory at: /home/jaime/Downloads
git clone git@github.com:jarrocha/XinuBBB.git
cd XinuBBB/compile
make
@jarrocha Yeah the problem is that we are including a cross_compiler that expects a 32-bit host and hence it fails on 64-bit host. Either we should explicitly mention it or add support for 64-bit host as development environment. Majority of users use 64-bit machines these days, so maybe we can make 64-bit host as default, and add corresponding cross_compiler? Or maybe we can remove it all together from the source code and add steps for developers to get their own toolchain downloaded from ARM/Linaro.
naveen@workstation:/tmp/XinuBBB/cross_compiler/arm-none-eabi/bin$ file gcc
gcc: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked, interpreter /lib/ld-linux.so.2, for GNU/Linux 2.6.16, stripped
naveen@workstation:/tmp/XinuBBB/cross_compiler/arm-none-eabi/bin$ uname -a
Linux workstation 5.11.0-40-generic #44~20.04.2-Ubuntu SMP Tue Oct 26 18:07:44 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
So, yes after a bit of research this is the issue that can arise if your 64-bit system does not have the necessary libraries to run 32-bit applications. For apt
based Linux systems (Debian, Ubuntu, Mint) you can do:
sudo dpkg --add-architecture i386
sudo apt-get update
This will install the required libraries. But if you are running in a system without privileges then you will have problems. I'll see about adding updated compilers to the repo.
@rfrankla , were your able to fix this issue on your side? Let me know. Here's an article with more details: https://www.unixmen.com/enable-32-bit-support-64-bit-ubuntu-13-10-greater/
I'll add this issue as a milestone.
In my Ubuntu 22.04 I also had to do sudo apt-get install libc6-i386
to get it to work.
The
make
throws the following error :I could finish the build by editing the makefile easily, but we may want to address these minor errors.