Skip to content

arch: add support for building LoongArch

Nathan Chancellor requested to merge nathanchance/tuxmake:loongarch into master

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://mirrors.edge.kernel.org/pub/tools/crosstool/files/bin/x86_64/13.1.0/x86_64-gcc-13.1.0-nolibc-loongarch64-linux.tar.xz

Link: https://bugs.debian.org/1031850

Link: https://wiki.debian.org/Multiarch/Tuples

Link: https://reviews.llvm.org/D138135

Edited by Nathan Chancellor

Merge request reports

Loading