Closed dosisod closed 3 years ago
The error you encountered is just the first hurdle of a long marathon. Porting to aarch64 would also mean we'd need to rewrite files like syscalls.sh and possibly consts.sh too. Plus rewriting all the assembly code that exists in this codebase. Also all the data structures like struct stat
would need to be thunked differently for each architecture.
I'm reluctant to support ARM because it would increase the dimensionality of our support vector, and I'm not even convinced that portable binaries is what ARM users want. ARM users value resource efficiency and they're unlikely to be happy with binaries that aren't cross-compiled for the specific superset of the ISA that they're using.
What I want to see happen is for our qemu-user-x86_64
shim in the APE bootloader to work better.
I am trying to compile Cosmopolitan on Android (via Termux), and am getting the following output:
compile.com
is an x86_64 ELF binary, not ARM, hence the errors. To fix this, we could have an option to re-buildcompile.com
from scratch so that it is in the right architecture, or provide multiple pre-compiled versions for different architectures (for all the bootstrapped binaries). This also means that we will need to provide alternate versions forthrid_party/gcc/x86_64-linux-musl/*
.