* [gentoo-dev] [PATCH] meson.eclass: include riscv bitness in cpu_family
@ 2021-05-03 12:56 fedora.dm0
0 siblings, 0 replies; only message in thread
From: fedora.dm0 @ 2021-05-03 12:56 UTC (permalink / raw
To: gentoo-dev; +Cc: floppym
This makes cpu_family identify RISC-V systems as either "riscv64"
or "riscv32" to match the given tuple, or it will leave it as
"riscv" when the tuple has an unknown cpu field.
This fixes the expected values of cpu_family in meson projects:
https://mesonbuild.com/Reference-tables.html#cpu-families
Signed-off-by: David Michael <fedora.dm0@gmail.com>
---
eclass/meson.eclass | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/eclass/meson.eclass b/eclass/meson.eclass
index d0ce5adb355..e9c651fdeda 100644
--- a/eclass/meson.eclass
+++ b/eclass/meson.eclass
@@ -142,6 +142,11 @@ _meson_get_machine_info() {
case ${cpu_family} in
amd64) cpu_family=x86_64 ;;
arm64) cpu_family=aarch64 ;;
+ riscv)
+ case ${tuple} in
+ riscv32*) cpu_family=riscv32 ;;
+ riscv64*) cpu_family=riscv64 ;;
+ esac ;;
esac
# This may require adjustment based on CFLAGS
--
2.26.3
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2021-05-03 12:56 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-05-03 12:56 [gentoo-dev] [PATCH] meson.eclass: include riscv bitness in cpu_family fedora.dm0
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox