arch: add support for building LoongArch
This has been tested with GCC 13.1.0 from kernel.org as well as an LLVM
toolchain with full LoongArch support, which is still a work in progress
due to missing ld.lld
support.
While the tuple for that toolchain is loongarch64-linux
, Fedora uses
loongarch64-linux-gnu
and other distributions like Debian are likely to
follow suit, so use that for the default CROSS_COMPILE
value.
Debian does not appear to have loongarch64-linux-gnu-gcc available in
the repos for amd64 or arm64 at the moment, so no runtime support is
enabled at the moment. Once ld.lld
support lands in LLVM main,
{clang,llvm}-nightly
support can be enabled.
Closes: #205 (closed)
Link: https://bugs.debian.org/1031850
Edited by Nathan Chancellor