From 6a3f18b0ae65806710c8d7d7a3b95bef81b05b11 Mon Sep 17 00:00:00 2001 From: Misty De Meo Date: Mon, 22 Jun 2020 11:50:49 -0700 Subject: [PATCH] OS::Mac::CPU: add Apple Silicon Co-authored-by: Shaun Jackman --- Library/Homebrew/extend/os/mac/hardware/cpu.rb | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Library/Homebrew/extend/os/mac/hardware/cpu.rb b/Library/Homebrew/extend/os/mac/hardware/cpu.rb index 1616a7aa67..fa8436d08d 100644 --- a/Library/Homebrew/extend/os/mac/hardware/cpu.rb +++ b/Library/Homebrew/extend/os/mac/hardware/cpu.rb @@ -11,12 +11,16 @@ module Hardware case sysctl_int("hw.cputype") when 7 :intel + when MachO::Headers::CPU_TYPE_ARM64 + :arm else :dunno end end def family + return :dunno if arm? + case sysctl_int("hw.cpufamily") when 0x73d67300 # Yonah: Core Solo/Duo :core