diff mbox series

[v2,2/7] selftests/nolibc: allow use mips64 toolchain for mips

Message ID 954c9c14ddd37f8612db256ccde0efc26a300a2e.1691783604.git.falcon@tinylab.org
State New
Headers show
Series selftests/nolibc: customize CROSS_COMPILE for all supported architectures | expand

Commit Message

Zhangjin Wu Aug. 11, 2023, 8:29 p.m. UTC
This allows to share the same mips64 toolchain for mips architecture.

Pass '-mabi=32' CFLAGS to tell mips64 toolchains to generate 32-bit mips
executable.

Signed-off-by: Zhangjin Wu <falcon@tinylab.org>
---
 tools/testing/selftests/nolibc/Makefile | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/tools/testing/selftests/nolibc/Makefile b/tools/testing/selftests/nolibc/Makefile
index 98d0a619d49d..d1012f006405 100644
--- a/tools/testing/selftests/nolibc/Makefile
+++ b/tools/testing/selftests/nolibc/Makefile
@@ -130,7 +130,7 @@  CFLAGS_ppc = -m32 -mbig-endian -mno-vsx $(call cc-option,-mmultiple)
 CFLAGS_ppc64 = -m64 -mbig-endian -mno-vsx $(call cc-option,-mmultiple)
 CFLAGS_ppc64le = -m64 -mlittle-endian -mno-vsx $(call cc-option,-mabi=elfv2)
 CFLAGS_s390 = -m64
-CFLAGS_mips = -EL
+CFLAGS_mips = -mabi=32 -EL
 CFLAGS_STACKPROTECTOR ?= $(call cc-option,-mstack-protector-guard=global $(call cc-option,-fstack-protector-all))
 CFLAGS  ?= -Os -fno-ident -fno-asynchronous-unwind-tables -std=c89 -W -Wall -Wextra \
 		$(call cc-option,-fno-stack-protector) \