add dawrin-aarch64 (arm64) Host Arch

This commit is contained in:
Jeong Han Lee
2021-02-02 17:26:12 -08:00
parent cf3173b6f4
commit 34a0b387b0
4 changed files with 34 additions and 2 deletions

View File

@ -0,0 +1,14 @@
# CONFIG.Common.darwin-aarch64
#
# This file is maintained by the build community.
#
# Definitions for darwin-ppc target builds
# Sites may override these definitions in CONFIG_SITE.Common.darwin-ppc
#-------------------------------------------------------
#
# To build universal binaries, configure ARCH_CLASS
# in the file CONFIG_SITE.Common.darwin-aarch64
# Include definitions common to all Darwin targets
include $(CONFIG)/os/CONFIG.darwinCommon.darwinCommon

View File

@ -0,0 +1,8 @@
# CONFIG.darwin-aarch64.Common
#
# Definitions for darwin-aarch64 host builds
# Sites may override these definitions in CONFIG_SITE.darwin-aarch64.Common
#-------------------------------------------------------
#Include definitions common to unix hosts
include $(CONFIG)/os/CONFIG.UnixCommon.Common

View File

@ -0,0 +1,9 @@
# CONFIG_SITE.Common.darwin-aarch64
#
# Site override definitions for darwin-aarch64 target builds
#-------------------------------------------------------
#
# arm64 devices: Apple Silicon M1
ARCH_CLASS = arm64

View File

@ -48,6 +48,7 @@ sub HostArch {
for ($cpu) {
return 'darwin-x86' if m/^(i386|x86_64)/;
return 'darwin-ppc' if m/Power Macintosh/;
return 'darwin-aarch64' if m/arm64/;
}
die "$0: macOS CPU type '$cpu' not recognized\n";
}