summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWANG Xuerui <git@xen0n.name>2023-06-29 14:58:43 +0200
committerHuacai Chen <chenhuacai@loongson.cn>2023-06-29 14:58:43 +0200
commit65eea6b44a5dd332c50390fdaeda7e197802c484 (patch)
tree75471e1dc3dd37ed3bfb3777802b411f9ddfe016
parentLoongArch: Mark Clang LTO as working (diff)
downloadlinux-65eea6b44a5dd332c50390fdaeda7e197802c484.tar.xz
linux-65eea6b44a5dd332c50390fdaeda7e197802c484.zip
Makefile: Add loongarch target flag for Clang compilation
The LoongArch kernel is 64-bit and built with the soft-float ABI, hence the loongarch64-linux-gnusf target. (The "libc" part can affect the codegen of libcalls: other arches do not use a bare-metal target, and currently the only fully supported libc on LoongArch is glibc anyway.) See: https://lore.kernel.org/loongarch/CAKwvOdnimxv8oJ4mVY74zqtt1x7KTMrWvn2_T9x22SFDbU6rHQ@mail.gmail.com/ Reviewed-by: Nick Desaulniers <ndesaulniers@google.com> Signed-off-by: WANG Xuerui <git@xen0n.name> Signed-off-by: Huacai Chen <chenhuacai@loongson.cn>
-rw-r--r--scripts/Makefile.clang1
1 files changed, 1 insertions, 0 deletions
diff --git a/scripts/Makefile.clang b/scripts/Makefile.clang
index 9076cc939e87..9a0aebf2ae60 100644
--- a/scripts/Makefile.clang
+++ b/scripts/Makefile.clang
@@ -4,6 +4,7 @@
CLANG_TARGET_FLAGS_arm := arm-linux-gnueabi
CLANG_TARGET_FLAGS_arm64 := aarch64-linux-gnu
CLANG_TARGET_FLAGS_hexagon := hexagon-linux-musl
+CLANG_TARGET_FLAGS_loongarch := loongarch64-linux-gnusf
CLANG_TARGET_FLAGS_m68k := m68k-linux-gnu
CLANG_TARGET_FLAGS_mips := mipsel-linux-gnu
CLANG_TARGET_FLAGS_powerpc := powerpc64le-linux-gnu