# (c) 2005--2012 Martin Mares <mj@ucw.cz>
# (c) 2006 Robert Spalek <robert@ucw.cz>
# (c) 2008 Michal Vaner <vorner@ucw.cz>
+# (c) 2023 Milan Rusek <milan.rusek@economia.cz>
### OS ###
return "amd64";
} elsif ($mach eq 'powerpc') {
return $mach;
+ } elsif ($mach eq 'aarch64') {
+ return $mach;
} else {
return "unknown ($mach)";
}
UnSet("CPU_BIG_ENDIAN");
UnSet("CPU_ALLOW_UNALIGNED");
Set("CPU_STRUCT_ALIGN" => 4);
+} elsif ($arch eq "aarch64") {
+ Set("CPU_ARM");
+ Set("CPU_64BIT_POINTERS");
+ Set("CPU_LITTLE_ENDIAN");
+ UnSet("CPU_BIG_ENDIAN");
+ UnSet("CPU_ALLOW_UNALIGNED");
+ Set("CPU_STRUCT_ALIGN" => 8);
} elsif (!Get("CPU_LITTLE_ENDIAN") && !Get("CPU_BIG_ENDIAN")) {
Fail "Architecture not recognized, please set CPU_xxx variables manually.";
}