View previous topic :: View next topic |
Author |
Message |
wowpetr n00b

Joined: 12 May 2018 Posts: 15
|
Posted: Fri Mar 07, 2025 12:04 pm Post subject: stage3-aarch64 file seems incompatible with apple silicon? |
|
|
When I'm trying to chroot I get this error "chroot: failed to run command ‘/bin/bash’: Exec format error". It means that the binary being executed is made for a different architecture than the environment currently booted. I booted from Minimal installation CD image for aarch64. When I do file /bin/bash and file /mnt/gentoo/bin/bash I get exact the same output except for the pie executable type:
Code: |
livecd /mnt/gentoo # file bin/bash
bin/bash: ELF 64-bit MSB pie executable, ARM aarch64 ...
livecd /mnt/gentoo # file /bin/bash
/bin/bash: ELF 64-bit LSB pie executable, ARM aarch64 ...
|
So what am I supposed to do? |
|
Back to top |
|
 |
pingtoo Veteran


Joined: 10 Sep 2021 Posts: 1666 Location: Richmond Hill, Canada
|
Posted: Fri Mar 07, 2025 2:01 pm Post subject: |
|
|
You most likely installed wrong stage3 file.
By default the arm64 kernel were compiled for little-endian (LSB) so it will not able to support your /mnt/gentoo/bin/bash which is big-endian (MSB)
I think all ARM core by design is bi-endian but most common usage is set to little-endian. |
|
Back to top |
|
 |
wowpetr n00b

Joined: 12 May 2018 Posts: 15
|
Posted: Fri Mar 07, 2025 4:34 pm Post subject: |
|
|
pingtoo wrote: | You most likely installed wrong stage3 file.
|
Yes, I realised that 'be' in the name of stage file I used stands for big-endian (current-stage3-aarch64_be-systemd). The problem is there's no other stage3 file with the same name but without `be`. So I'm not sure what to do about it. |
|
Back to top |
|
 |
pingtoo Veteran


Joined: 10 Sep 2021 Posts: 1666 Location: Richmond Hill, Canada
|
Posted: Fri Mar 07, 2025 4:44 pm Post subject: |
|
|
No sure where you are looking, but I can see at download page, there are openrc and systemd for current. |
|
Back to top |
|
 |
grknight Retired Dev

Joined: 20 Feb 2015 Posts: 2141
|
|
Back to top |
|
 |
wowpetr n00b

Joined: 12 May 2018 Posts: 15
|
Posted: Fri Mar 07, 2025 5:29 pm Post subject: |
|
|
TYVM guys I checked that the files you mentioned indeed have been compiled as LSB binaries. |
|
Back to top |
|
 |
|