public inbox for gentoo-dev@lists.gentoo.org
 help / color / mirror / Atom feed
From: WANG Xuerui <i.gentoo@xen0n.name>
To: gentoo-dev@lists.gentoo.org
Cc: WANG Xuerui <git@xen0n.name>
Subject: [gentoo-dev] [PATCH] toolchain-funcs.eclass: add detection for loongarch
Date: Mon, 30 Aug 2021 11:25:25 +0800	[thread overview]
Message-ID: <20210830032525.2636781-1-i.gentoo@xen0n.name> (raw)

From: WANG Xuerui <git@xen0n.name>

The Linux port currently under review has arch/loongarch, and should
almost certainly remain that way till merge; meanwhile it's ARCH=loong
on the Gentoo side, per mailing list discussion[1] and eselect
adaptation[2]. This architecture is little-endian-only according to the
manual[3].

[1]: https://archives.gentoo.org/gentoo-dev/message/388a4b7428461660e89c8eae8c292f32
[2]: https://gitweb.gentoo.org/proj/eselect.git/commit/?id=a49477f39d3f000cc2ca57f18aafbd66656aba05
[3]: https://github.com/loongson/LoongArch-Documentation/blob/2021.08.17/docs/LoongArch-Vol1-EN/basic-integer-instructions/programming-model-of-basic-integer-instructions/endian.adoc

Signed-off-by: WANG Xuerui <git@xen0n.name>
---
 eclass/toolchain-funcs.eclass | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/eclass/toolchain-funcs.eclass b/eclass/toolchain-funcs.eclass
index 563d9deef40..77fb304940b 100644
--- a/eclass/toolchain-funcs.eclass
+++ b/eclass/toolchain-funcs.eclass
@@ -675,6 +675,7 @@ ninj() { [[ ${type} == "kern" ]] && echo $1 || echo $2 ; }
 			fi
 			;;
 		ia64*)		echo ia64;;
+		loongarch*)	ninj loongarch loong;;
 		m68*)		echo m68k;;
 		metag*)		echo metag;;
 		microblaze*)	echo microblaze;;
@@ -752,6 +753,7 @@ tc-endian() {
 		hppa*)		echo big;;
 		i?86*)		echo little;;
 		ia64*)		echo little;;
+		loongarch*)	echo little;;
 		m68*)		echo big;;
 		mips*l*)	echo little;;
 		mips*)		echo big;;
-- 
2.33.0



             reply	other threads:[~2021-08-30  3:25 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-30  3:25 WANG Xuerui [this message]
2021-12-14  3:36 ` [gentoo-dev] [PATCH] toolchain-funcs.eclass: add detection for loongarch Sam James

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210830032525.2636781-1-i.gentoo@xen0n.name \
    --to=i.gentoo@xen0n.name \
    --cc=gentoo-dev@lists.gentoo.org \
    --cc=git@xen0n.name \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox