Since no CPU subtypes are defined for CPU_TYPE_ARM64, just report the type, same as for x86_64.
Sample uname(2) output: sysname: GNU release: 0.9 version: GNU-Mach 1.8/Hurd-0.9 machine: aarch64 --- proc/cpu-types.c | 3 +++ proc/host.c | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/proc/cpu-types.c b/proc/cpu-types.c index 3d89d5a7..41af0888 100644 --- a/proc/cpu-types.c +++ b/proc/cpu-types.c @@ -35,6 +35,9 @@ const char *const mach_cpu_types[] = #endif #ifdef CPU_TYPE_X86_64 [CPU_TYPE_X86_64] = "x86_64", +#endif +#ifdef CPU_TYPE_ARM64 + [CPU_TYPE_ARM64] = "aarch64", #endif }; diff --git a/proc/host.c b/proc/host.c index 0197fecf..e0aff20a 100644 --- a/proc/host.c +++ b/proc/host.c @@ -355,11 +355,11 @@ initialize_version_info (void) assert_backtrace (! err); snprintf (uname_info.machine, sizeof uname_info.machine, "%s" -#ifndef __x86_64__ +#if !defined (__x86_64__) && !defined (__aarch64__) "-%s" #endif , mach_cpu_types[info.cpu_type] -#ifndef __x86_64__ +#if !defined (__x86_64__) && !defined (__aarch64__) , mach_cpu_subtypes[info.cpu_type][info.cpu_subtype] #endif ); -- 2.44.0