Homebrew / brew

🍺 The missing package manager for macOS (or Linux)

Home Page:https://brew.sh

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

macOS 11 Big Sur compatibility on Apple Silicon

claui opened this issue · comments

Latest news on native ARM compatibility

  • (2020-12-26) We currently have 3168 formulas bottled for Apple Silicon in homebrew-core. At this point, the table below is probably not really relevant anymore (except for historical reference) and the best way to know if a formula is working is “does it have an ARM bottle” (a :arm64_big_sur line in the bottle block).
  • (2020-12-04) A fellow maintainer has been setting up ARM-based Macs as CI nodes for Homebrew.
    That means Apple Silicon bottles are coming soon. Bottle-building may start next week, which is a few weeks earlier than we thought. Expect bottling to drag along. It definitely won’t be finished in 2020.
    Homebrew remains unsupported on Apple Silicon, and will become supported once enough bottles are built and once everything feels stable enough.
  • (2020-11-18) Added Major blockers section for a quick overview.
  • (2020-11-18) Issue with mkmf in Ruby.framework resolved (FB7836181).
    All brew commands that depend on that gem, e. g. brew audit, seem to work now.
  • (2020-11-15) Issues with code signing now resolved thanks to @fxcoudert, @mistydemeo and others.
  • (2020-11-15) There won’t be any support for native ARM Homebrew installations for months to come. See both #7857 (comment) about CI infrastructure and #7857 (comment) about GCC for details.
  • (2020-11-15) Native ARM Homebrew installations are only going to be supported at /opt/homebrew (once support arrives). See #7857 (comment) for details.

A detailed description of the proposed feature

This is an overview of compatibility issues and work items related to native ARM Homebrew installations on macOS 11.0 (Big Sur). Homebrew doesn’t support it right now but we need to track and triage those items nonetheless.

The motivation for the feature

macOS 11.0 (Big Sur) has been released to the public, and our goal is for Homebrew to support it.

How the feature would be relevant to at least 90% of Homebrew users

In the long run, more than 90 % of Homebrew (macOS) users are going to run Apple Silicon hardware.

What alternatives to the feature have been considered

No alternatives.


Major blockers

  • Set up ARM-based CI infrastructure
  • Have Homebrew’s CI build arm64_big_sur bottles
  • go (waiting for upstream version 1.16)
  • rust (waiting for upstream version 1.49 or backport to 1.47/1.48)
  • ghc (help wanted)
  • qt (help wanted)
  • openjdk (waiting for upstream version 16; work in progress to integrate OpenJDK 16 preview as stop-gap)
  • gcc (work in progress, see #7857 (comment))
  • Others (see #7857 (comment))

Status of core formulae

Formula Works1
on 11.0
Comments
ack 🥇
adns 🥇
adwaita-icon-theme
aircrack-ng
ansible
ant Re-check when openjdk works
aom 🥇 Patched for now
apache-spark
apr-util 🥇
apr 🥇
argon2 🥇
arpack
asciidoc 🥇
asdf
aspell 🥇
atk
augeas 🥇
autoconf 🥇
autojump
automake 🥇
aws-elasticbeanstalk 🥇
aws-iam-authenticator Re-check when go works
awscli ⚠️ Build fails with a distutils.errors.DistutilsClassError, see logs.
Possibly related to setuptools: pypa/setuptools#2231
azure-cli 🥇
bash-completion 🥇
bash ⚠️ make says, redefinition of 'sys_siglist' with a different type: 'char *[32]' vs 'const char *const [32]'. Logs
bat Re-check when rust works
bazel Re-check when openjdk@11 works
bdw-gc
berkeley-db 🥇
binutils 🥇
bison 🥇
blueutil 🥇
boost 🥇 Patched for now
brotli 🥇
c-ares 🥇
cabal-install Re-check when ghc works
cairo 🥇
cargo-c Builds in rust prereleases; will work when a stable Rust with Apple Silicon support ships
carthage 🥇 Patched for now
cask Re-check when emacs works
ccache 🥇

Used to work, no longer builds. Logs

Says:

invalid conversion between vector type '__m64' (vector of 1 'long long' value) and integer type 'int' of different size

ceres-solver
certbot 🥇
cfitsio 🥇
cgal Re-check when qt works
circleci Re-check when go works
clang-format 🥇
cloc 🥇
cmake 🥇
cocoapods ⚠️ Error Unrecognized Mach-O load command: 0x80000034 in ffi_c.bundle
colordiff 🥇
composer 🥇
consul Re-check when go works
coreutils 🥇
cscope 🥇
ctags 🥇
cunit 🥇
curl 🥇
curl-openssl 🥇
cython 🥇
dav1d 🥇
daemontools 🥇
deno Re-check when llvm and rust work
dep Re-check when go works
dialog 🥇 Patched for now
direnv Re-check when go works
dnsmasq 🥇
docbook-xsl 🥇
docbook 🥇
docker Re-check when go works
docker-completion 🥇
docker-machine Re-check when go works
doctl Re-check when go works
dos2unix 🥇
doxygen 🥇
duti 🥇 Patched for now. PR also submitted upstream.
eigen 🥇
elasticsearch Re-check when gradle and openjdk work
elixir Re-check when erlang works
emacs Re-check when gnutls works
epsilon 🥇
epstool Re-check when ghostscript works
erlang ⚠️ Either we need to backport erlang/otp#2700 or wait for upstream release 23.1.
Same with erlang/otp#2687.
exiftool 🥇
expat 🥇
fastlane 🥇
fd Re-check when rust works
ffmpeg Re-check when gnutls, libbluray and several other dependencies work
fftw Re-check when gcc and open-mpi work
fig2dev Re-check when ghostscript and netpbm work
figlet 🥇
findutils 🥇
fish 🥇
flac 🥇
fltk
fontconfig 🥇 Patched for now
fontforge
freetds 🥇
freetype 🥇
freexl ⚠️ Build error: implicitly declaring library function 'printf' Logs
frei0r 🥇
fribidi 🥇
fswatch
fzf
gawk 🥇
gcal 🥇
gcc ⚠️

@iains has some work in progress on https://github.com/iains/gcc-darwin-arm64 to port the GCC backend to Apple Silicon.

Mind that Apple Silicon support is going to require GCC 11 even in the best case. The first stable release of GCC 11 may come out in mid-2021 or later. If you absolutely require a stable GCC, or any formula that depends on it, you may want to hold off your Apple Silicon Mac purchase decisions until it’s clear if or when GCC will support it.

For limited testing on Apple Silicon, Homebrew may consider shipping an unstable GCC 11 but that’s yet to be decided.

gdal Re-check when expat, freexl, geos, hdf5 and a dozen of other dependencies work
gdbm 🥇
gdb
gdk-pixbuf
gd 🥇
geckodriver
geos ⚠️ Squeals about duplicate symbol BasicSegmentString in inlines.o vs. libnoding.a. Logs
gettext 🥇
gflags
ghc ⚠️ Re-check when Homebrew/homebrew-core#57892 is merged
ghc@8.8
ghostscript ⚠️ Re-check when Homebrew/homebrew-core#58493 is merged
giflib 🥇
git ⚠️ Lots of Undefined symbols for architecture arm64. Possibly related to libintl and pcre2. Logs
git-flow
git-gui
git-lfs
gitlab-runner
gl2ps
glew
glib-networking
glib 🥇
glog
glpk
gmp 🥇
gnu-getopt 🥇
gnu-sed 🥇
gnu-tar 🥇
gnupg Re-check when gnutls works
gnuplot
gnutls Re-check pending
gobject-introspection 🥇
go ⚠️

Bootstrapped go (x86_64) is killed at build time. Logs

Re-check when upstream 1.16 is released

gpatch 🥇
gpgme
gradle Re-check when openjdk works
grafana
graphicsmagick
graphite2 🥇
graphviz Re-check when gts works
grep 🥇
groonga 🥇
groovy
grpc
gsettings-desktop-schemas
gsl
gst-plugins-bad
gstreamer
gtk+3
gtk+
gtk-mac-integration
gts Re-check when netpbm works
guile 🥇 Fixed
harfbuzz 🥇
hdf5 Re-check when gcc works
helm Re-check when go works
helm@2 Re-check when glide and go work
hicolor-icon-theme
highlight 🥇
htop 🥇
httpd 🥇
httpie 🥇
hub Re-check when go works
hugo Re-check when go works
hwloc 🥇
icu4c 🥇
ideviceinstaller 🥇
ilmbase 🥇
imagemagick@6 🥇
imagemagick Re-check when ghostscript, libheif and libomp work
inetutils 🥇
ios-deploy 🥇
ios-webkit-debug-proxy 🥇
iperf3 🥇
ipython 🥇
isl 🥇
itstool 🥇
jansson 🥇
jasper 🥇
jemalloc 🥇
jenkins Re-check when openjdk@11 works
jenkins-lts Re-check when openjdk@11 works
jenv 🥇
jmeter
jpeg 🥇
jq 🥇
json-c 🥇
jupyterlab Re-check when pandoc works
kafka Re-check when openjdk (or some other form of Java) and zookeeper work
kops
kotlin Re-check when openjdk (or some other form of Java) works
krb5 🥇 Patched for now. Patch submitted to upstream issue tracker.
kubectx
kubernetes-cli Re-check when go works
kustomize
lame 🥇
ldns
leptonica 🥇
libarchive
libassuan 🥇
libass 🥇
libb2
libbluray Re-check when openjdk (or some other form of Java) works
libcbor
libcerf
libcroco
libdap
libde265 ⚠️ ARM assembly/macros/directives fail at build time. Re-check needed with the correct triple. Logs
libepoxy
libevent 🥇
libev 🥇
libexif
libffi 🥇 Patched for now, awaiting upstream patches: libffi/libffi#565
libfido2
libgcrypt 🥇
libgeotiff
libgit2 🥇
libgpg-error 🥇
libheif Re-check when libde265 works
libiconv 🥇
libidn2 🥇
libidn 🥇
libilbc 🥇
libimobiledevice 🥇
libksba 🥇
liblqr 🥇
libmagic 🥇
libmaxminddb 🥇
libmetalink 🥇
libmpc 🥇
libnet
libogg 🥇
libomp ⚠️ make install fails while trying to make sense of x86_64 assembly for Linux. Logs
libp11
libplist 🥇
libpng 🥇
libpq 🥇
libpsl
librdkafka
libressl
librsvg
libsamplerate 🥇
libscrypt 🥇
libsmi 🥇
libsndfile 🥇
libsodium 🥇
libsoup
libsoxr 🥇
libspatialite
libspiro
libssh 🥇
libssh2 🥇
libtasn1 🥇
libtermkey
libtiff 🥇
libtool 🥇
libuninameslist
libunistring 🥇
libusb-compat
libusbmuxd 🥇
libusb 🥇
libuv 🥇
libvidstab 🥇
libvirt
libvorbis 🥇
libvpx 🥇
libvterm
libwebsockets
libxml2 🥇
libxslt
libyaml 🥇
libzip 🥇
little-cms2 🥇
llvm 🥉 Builds if OpenMP is disabled. Stable builds don't work, but HEAD does and 11.0.0 will be compatible.
lua 🥇
lua@5.1 🥇
luajit ⚠️ Fails with 2.0.5 but should work when upstream 2.1.0 is released.
luarocks 🥇
lynx 🥇 Patched for now
lz4 🥇
lzo 🥇
macvim
mad ⚠️ Configure error: /bin/ksh ./config.sub -apple-darwin20.0.0 failed Logs
make
mariadb Re-check when groonga works
mas 🥇 Fixed
maven Re-check when openjdk works
mbedtls
mcrypt
mecab 🥇
mecab-ipadic 🥇
memcached
mercurial 🥇
meson 🥇
metis
midnight-commander
minikube
minizip 🥇
mitmproxy
mkcert
mkvtoolnix
mono
mosh
mpfr 🥇
mpv
msgpack 🥇
mtr
mujs
mutt
mysql ⚠️ The build proceeds to completion but mysqld_safe fails with syntax error near unexpected token 'then' in line 831.
mysql@5.6 ⚠️ make errors out after building the target event_extra. Logs
mysql@5.7 ⚠️ Builds but mysqld_safe fails: syntax error near unexpected token 'then' in line 804.
mysql-client 🥇
nano 🥇
nasm 🥇
ncdu
ncurses 🥇
neofetch
neovim ⚠️ Upstream PR in progress: neovim/neovim#12624
netcdf
netpbm Re-check when subversion works
nettle 🥇 Patched for now
nghttp2 🥇
nginx 🥇
ninja 🥇
nmap 🥇 Fixed
node 🥇

Patched for now.

See also nodejs/node#34043 and nodejs/TSC#886 for upstream progress.

node@10
node@12 🥇
node-build
nodebrew
npth 🥇
nspr 🥇
nss ⚠️ Build fails while loading softokn3. Logs
ntfs-3g
numpy
nvm
ocaml Upstream PR merged, see ocaml/ocaml#9699.
4.10 backport in progress, see ocaml/ocaml#10026.
4.10 formula-patches PR: Homebrew/formula-patches#318
octave
oniguruma 🥇
opam
open-mpi Re-check when gcc works
openblas
openconnect
opencore-amr
opencv
openexr 🥇
openjdk ⚠️ Needs to be ported (logs). See also related JEP draft: MacOS/AArch64 Port
openjdk@11
openjpeg 🥇
openldap 🥇
openssh
openssl aka openssl@1.1 🥇

Patched for now.

Works well enough until the upstream fix is released.

openvpn 🥇
opusfile 🥇
opus 🥇
orc
p11-kit 🥇
p7zip 🥇
packer Re-check when go works
pandoc Re-check when cabal-install and ghc work
pango 🥇 Patched for now
parallel 🥇
pcre2 🥇 Note: JIT disabled for now. See Homebrew/homebrew-core#57419
pcre 🥇 Note: JIT disabled for now. See Homebrew/homebrew-core#57410
perl 🥇 Patched for now
php@7.2 ⚠️ Seems more difficult to fix than php. Might want to triage as 🚫.
php@7.3 ⚠️ Seems more difficult to fix than php. Might want to triage as 🚫.
php 🥇 Fixed
pinentry 🥇
pipenv 🥇
pixman 🥇
pkcs11-helper 🥇
pkg-config 🥇
plantuml
poppler Re-check when nss and qt work
popt 🥇
portaudio 🥇
postgis Re-check when gdal, geos, gpp and sfcgal work
postgresql 🥇
postgresql@9.6
postgresql@10
postgresql@11
pre-commit 🥇
proj 🥇
protobuf 🥇
protobuf-c 🥇
pstoedit
pstree 🥇
pulumi
putty 🥇
py3cairo
pyenv ⚠️ Bash crashes due to code signature error when trying to load pyenv-realpath.dylib as a builtin. Log
pyenv-virtualenv
pygobject3
pyqt
python@3.7 ⚠️ Patch python/cpython#21249 fails. Re-check when upstream arm64 support stabilises.
python@3.8 🥉

Patched for now but brew test fails.

Re-check after Homebrew/homebrew-core#64872 is merged.

python aka python@3.9 🥉

brew test currently fails.

Re-check after Homebrew/homebrew-core#64869 is merged.

qemu
qhull
qrupdate
qt ⚠️ Fails running find_sdk.py late in the build. (logs, full make log)
rabbitmq Re-check when erlang works
rav1e Re-check when cargo-c and rust work
rbenv
rclone
readline 🥇
redis 🥇 Patched for now
rename
ripgrep
rsync
rtmpdump 🥇
rubberband
ruby-build
ruby@2.5
ruby 🥇
rust ⚠️ Upstream tracking issue: rust-lang/rust#73908
rustup-init
s-lang
s3cmd
sbcl
sbt
scala
scrcpy
screenresolution 🥇
sdl2
sdl 🥇
sfcgal Re-check when cgal works
shared-mime-info 🥇
shellcheck Re-check when cabal-install, ghc@8.8 and pandoc work
sip
skaffold
snappy 🥇
socat
source-highlight 🥇
sox Re-check when mad works
spandsp 🥇
speedtest-cli
speex 🥇
sphinx-doc 🥇
sqlite 🥇
sqlmap
srt ⚠️ Fails with 'GLES/gl.h' file not found during make install. Logs
ssh-copy-id
sshfs
sshpass
sshuttle
starship
stoken
subversion 🥉 Works but brew test fails. Logs.
suite-sparse
sundials
swagger-codegen
swiftformat
swiftlint 🥇
swig 🥇
szip 🥇
tbb 🥇 Patched for now
tcl-tk
telnetd 🥇
telnet 🥇
terraform Re-check when go works
terragrunt
tesseract 🥇
texinfo 🥇
tfenv
tflint
thefuck 🥇
theora 🥇
the_silver_searcher
tidy-html5 🥇
tig
tmux 🥇
tomcat
tor 🥇
tree 🥇
uchardet
unar 🥇
unbound 🥇
unibilium
unixodbc 🥇
unrar 🥇
utf8proc 🥇
v8
vala Re-check when graphviz works
valgrind
vapoursynth
vault
vde
vim 🥇
vips
watchman
watch
webp 🥇
wget 🥇
wimlib
winetricks
wireshark
wxmac
x264 🥇 Patched for now
x265 🥇
xcodegen ⚠️ Not compatible with Xcode 12.
Re-check with upstream version > 2.17.0 once released.
xerces-c
xmlto 🥇
xvid 🥇
xxhash 🥇
xz 🥇
yara 🥇
yarn 🥇
yasm 🥇 Note: doesn’t support ARM targets
youtube-dl 🥇
yq Re-check when go works
zeromq 🥇
zimg 🥇
zlib 🥇
zookeeper Re-check when ant works
zsh 🥇
zsh-autosuggestions 🥇
zsh-completions 🥇
zsh-syntax-highlighting 🥇
zstd 🥇
Source
curl -sLS \
  'https://formulae.brew.sh/api/analytics/install/90d.json' \
  | jq -r '.items
    | map(select (.formula | contains("/") | not) | .formula)[:512]
    | sort
    | [""] + map("`\(.)`")
    | map([., "", ""] | @csv)
    | .[]
    ' \
  | pandoc -f csv -t gfm \
  | sed -e 's/\\`/`/g'
___

1 For Works on 11.0, the key is:

  • 🥇brew install -s succeeds on Apple Silicon. The software works well enough natively.
  • 🥈 The formula has been updated with depends_on :arch => [:x86_64, :build]. The software works well enough on Rosetta.
  • 🥉 The formula has known issues on macOS 11, though most features work. The issues are described in the Comments field.
  • 🚫 The formula has been updated with depends_on :arch => :x86_64. The software has been deemed to work on Intel only (for now).
  • ⚠️ The formula has been found to need more analysis/work.

Homebrew’s linkage checker doesn’t support the shared dyld cache yet

It does as of 9c4aaa9.

  • install.sh downloads macOS 10.16 CLT

Fixed in Homebrew/install#317

libsodium formulae work fine on Apple Silicon.

Both the release and HEAD.

Thanks @jedisct1. Noted.

The fiddle issue is fixable by installing HEAD:

$ git clone https://github.com/ruby/fiddle
$ cd fiddle
$ bundle install --path vendor/bundle
$ bundle exec rake build
$ sudo gem install pkg/fiddle-1.0.1.gem

OpenSSL works with a workaround config change.

$ bundle install --vendor/bundle should be $ bundle install --path vendor/bundle, above.

@dmzimmerman thank you, fixed!

Updated issue description with @indirect’s workaround. Thanks!

htop seems to work fine, builds to native arm with no problems:

adam@Adams-Mac ~ % file /usr/local/bin/htop 
/usr/local/bin/htop: Mach-O 64-bit executable arm64

Telnet works but builds for x86_64. PR submitted to build for arm64 Homebrew/homebrew-core#57303

I'm getting the following error, any idea how to continue?

Error: Could not find an SDK that supports macOS 11.0.
You may have have an outdated or incompatible CLT.
Homebrew found the following SDKs in the CLT install:
  10.16
  10.15

Please update CLT or uninstall it if no updates are available.

@FigBug If you’re on macOS 11, you need Xcode 12 for macOS Universal Apps beta installed. Then run:

sudo xcode-select --switch /Applications/Xcode-beta.app/Contents/Developer

@claui I'm running macOS 11.0 Beta (20A5299w) with Xcode 12.0 beta (12A8158a) on the DTK. After running xcode-select as you suggested, I still get the above error.

@FigBug Please don't ask us for help while you're running an unsupported version of macOS.

I tried to make the error as clear as possible.

Please update CLT or uninstall it if no updates are available.

If it isn't, please open a pull request making it clearer.

First timer here: How can we help Big Sur compatibility on ARM Macs if we are indeed running an unsupported version of macOS?
I see in this list that cocoapods is unchecked yet. But I needed it, so I tried to install.
"Error: Failed to read Mach-O binary." on all the "ffi_c.bundle" files.

Should I create a new 'issue', or is this part of the 'Big Sur compatibility' list?

Should I create a new 'issue', or is this part of the 'Big Sur compatibility' list?

Thank you for reaching out, and welcome to the Homebrew community @axello.

Please don’t create an issue. Homebrew does not yet support Big Sur so issues aren’t helpful right now.
cocoapods being unchecked means we didn’t even get around to checking it yet for Big Sur compatibility.

Your options are to either wait until it’s cocoapods’s turn to be checked and fixed, or help us by filing a pull request.

I believe the Cocoapods issue is known by Apple themselves, as I think it is a system Ruby bug.

How can we help Big Sur compatibility on ARM Macs if we are indeed running an unsupported version of macOS?

Submit PRs to fix things. Almost every issue we have had so far has been already known. We know things aren't working. We need help fixing things not telling us what isn't working.

re: ilmbase - looks like this pull request straightens out arm64 macOS support. Once cmake build is fixed there shouldn't be a problem building openexr and ilmbase.

Is feedback on untested Formula in the above table useful? For example, I've installed and tested zlib on the DTK, and it appears to work correctly.

Is feedback on untested Formula in the above table useful? For example, I've installed and tested zlib on the DTK, and it appears to work correctly.

@HaydenPeake Feedback on formulae that work correctly is welcome.
It means we can update the table immediately, which benefits everyone.

commented

I've submitted a PR to get pcre working on arm64: Homebrew/homebrew-core#57410
This is only a surface level fix at this point; it just turns off JIT.
Edit: disabling JIT also fixes the crash in pcre2, I have yet to submit a PR for this. Again, it seems like a short term fix only.

brew install cmake --HEAD seems to work for me! (the big sur release notes say Workaround: Update to CMake 3.18rc1. so I'm not terribly surprised)

brew install cmake --HEAD seems to work for me! (the big sur release notes say Workaround: Update to CMake 3.18rc1. so I'm not terribly surprised)

Not sure how you did that unless python3.8 was patched a few hours ago... Unless you aren’t building on Apple Silicon.

sorry, should've been more specific -- python@3.8 only required the 3 linked PRs patched in: indirect/homebrew-core@273ca33

some of the stuff downstream from cmake works as well, such as tmux

commented

Created a PR for the pcre2 segfault -- again, just a workaround:
Homebrew/homebrew-core#57419

commented

For table update purposes, here's a list of formula with incomplete status which I happen to have tried on the DTK. I did an install and test and they seemed to function correctly:

  • apr
  • apr-util
  • coreutils
  • flac
  • liboff
  • libvorbis
  • lua
  • nginx
  • p7zip
  • speex
  • swig
  • telnet
  • theora
  • utf8proc
  • youtube-dl
  • zlib

Hello All,

This is a simple patch to fix Python@3.8 formula on arm64.

python.diff.txt

I think it would also be good to check whether formula are building arm64 or x86_64. Even though x86_64 will (mostly) work, the way forward is to get everything building natively 🙂

For example, telnet did build and work, but was x86_64 until my patch Homebrew/homebrew-core#57303

I think it would also be good to check whether formula are building arm64 or x86_64.

I absolutely agree. The wish is to have an audit which verifies if the output binaries are built natively - it's just that no one has done it yet.

The audit likely requires a way to make exceptions because I do think some formulae intentionally build non-native binaries for some cases, like parts of LLVM for iOS or something.

PSA: the preliminary fix for python@3.8 has been merged. Should work now except for Tk support.
Formula promoted to 🥉 for now.

I think it would also be good to check whether formula are building arm64 or x86_64.

I absolutely agree. The wish is to have an audit which verifies if the output binaries are built natively - it's just that no one has done it yet.

The audit likely requires a way to make exceptions because I do think some formulae intentionally build non-native binaries for some cases, like parts of LLVM for iOS or something.

I'd be happy to help with this! I've manually gone through some already and a fair number are building arm64 with no updates which is great. If we had an automated setup that would be even better 🙂

FWIW I have been trying to bootstrap go to avoid the x86_64 kill at startup, but with no joy. Just found the tracking issue for this golang/go#38485 Seems like we will be blocked for the moment

PSA: the preliminary fix for python@3.8 has been merged. Should work now except for Tk support.
Formula promoted to 🥉 for now.

Thank you! It is possible to build meson with ctype Python fix. Glib and midnight-commander is buildable after that by removing libffi dependency from glib.

After getting GMP to build using https://github.com/Homebrew/homebrew-core/pull/57315/files#diff-e16a29aaf7be91f5224126d4f764738b, nettle fails to build on Apple Silicon because it also uses lots of assembly code. Example:

clang -I.  -DHAVE_CONFIG_H -g -O2 -ggdb3 -Wall -W -Wno-sign-compare   -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes   -Wpointer-arith -Wbad-function-cast -Wnested-externs   -c aes128-set-encrypt-key.c \
	&& true
aes-decrypt-internal.s:67:2: error: unrecognized instruction mnemonic
 teq r3, #0
 ^aes-encrypt-internal.s
:75:2: error: unrecognized instruction mnemonic
 teq r3, #0
 ^

After getting GMP to build using https://github.com/Homebrew/homebrew-core/pull/57315/files#diff-e16a29aaf7be91f5224126d4f764738b, nettle fails to build on Apple Silicon because it also uses lots of assembly code. Example:

clang -I.  -DHAVE_CONFIG_H -g -O2 -ggdb3 -Wall -W -Wno-sign-compare   -Wmissing-prototypes -Wmissing-declarations -Wstrict-prototypes   -Wpointer-arith -Wbad-function-cast -Wnested-externs   -c aes128-set-encrypt-key.c \
	&& true
aes-decrypt-internal.s:67:2: error: unrecognized instruction mnemonic
 teq r3, #0
 ^aes-encrypt-internal.s
:75:2: error: unrecognized instruction mnemonic
 teq r3, #0
 ^

Created a PR with a temporary fix for this issue until arm64 support is available upstream Homebrew/homebrew-core#57455

OpenSSL 1.1.1 PR openssl/openssl/pull/12369 submitted

Reporting issue with cocoapods – building from source would fail due to a missing xcodeprojdependency:

Command:

brew install --build-from-source cocoapods

Error:

==> gem install cocoapods-1.9.3.gem
Error: An exception occurred within a child process:
  Errno::ENOENT: No such file or directory - /usr/local/Cellar/cocoapods/1.9.3/libexec/bin/xcodeproj

@adib Thank you. We’re really just getting started so reporting breakage isn’t helpful at this time.
Appreciate your report but marking it OT to keep the page focused.

Findings from today:

  • rust - currently not installing. The tracking issue for this is here: rust-lang/rust#73908 The tracking issue says that x86_64 should work fine with Rosetta, but I have been unable to get a successful build for this so far 😞
  • bash - Currently not installing successfully - tries to build for arm64 and fails, maybe x86_64 will work but have not tested yet
  • nettle - PR filed to disable assembly until available upstream Homebrew/homebrew-core#57455
  • gd - installs fine, passes tests and binaries are arm64
  • libplist - installs fine, passes tests and binaries are arm64
  • libimobiledevice - installs fine, passes tests and binaries are arm64

PSA: The pcre, pcre2 and gmp fixes have landed.
Special thanks to @BytesGuy and @DodgyTim who helped remove those roadblocks. 🎉

  • gd - installs fine, passes tests and binaries are arm64
  • libplist - installs fine, passes tests and binaries are arm64

@BytesGuy Noted, thanks for the heads up!

  • libimobiledevice - installs fine, passes tests and binaries are arm64

PR filed to make libimobiledevice (stable) pass brew audit: Homebrew/homebrew-core#57555
Update: Installs and works fine now, both stable and --HEAD.

carthage works with this patch and builds a native binary (also resolves issues on Intel): Homebrew/homebrew-core#57572

fish - Installs fine, passes tests, arm64 binary
perl - Currently doesn't work on Intel or Apple Silicon, PR opened: Homebrew/homebrew-core#57580 (with this fix it passes tests and the binary is arm64 native)

It has come to my attention that carthage has landed (thanks again @BytesGuy) and cmake, too.

I'm going to take a look at the JIT issues for pcre and pcre2 – I found the same issue with Boxer (DosBox) and resolved it in MaddTheSane/dosbox@794513d

  • gnupg is currently blocked by libffi
  • vim is currently blocked by perl
  • redis currently will not install and provides the following error:
                   ^
debug.c:1037:47: error: no member named '__gs' in 'struct __darwin_arm_thread_state64'
        (unsigned long) uc->uc_mcontext->__ss.__gs
                        ~~~~~~~~~~~~~~~~~~~~~ ^
debug.c:1039:51: error: no member named '__esp' in 'struct __darwin_arm_thread_state64'; did you mean '__sp'?
    logStackContent((void**)uc->uc_mcontext->__ss.__esp);
                                                  ^~~~~
                                                  __sp
/Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk/usr/include/mach/arm/_structs.h:139:13: note: '__sp' declared here
        __uint64_t __sp;    /* Stack pointer x31 */
                   ^
18 errors generated.
make[1]: *** [debug.o] Error 1
make[1]: *** Waiting for unfinished jobs....
make: *** [install] Error 2

@BytesGuy regarding redis, it just so happens I fixed a similar issue in iTerm2. I'll take a look at that.

Erlang is currently not compiling on macOS 11 because:

 error: static declaration of 'in6addr_any' follows non-static declaration

There are separate issues on Apple Silicon that likely require a more difficult fix.

Tracking here:

I can confirm, c-ares is working as well.

How come that, so far, no formulae has a 🥈?

Just checked mecab and mecab-ipadic: Installs fine, arm64 binary
Same goes for tmux.

How come that, so far, no formulae has a 🥈?

We have not added Rosetta 2 support to Homebrew yet. That however has resulted in some very good feedback.

The goal for Homebrew is native arm64 support, with Rosetta 2 being a last resort, so the priority has been fixing formulae to be able to meet that goal. I'll likely look more into Rosetta 2 in a week or two.

nmap: Installs fine, arm64 binary

How come that, so far, no formulae has a 🥈?

We have not added Rosetta 2 support to Homebrew yet. That however has resulted in some very good feedback.

The goal for Homebrew is native arm64 support, with Rosetta 2 being a last resort, so the priority has been fixing formulae to be able to meet that goal. I'll likely look more into Rosetta 2 in a week or two.

Will it be possible to fallback to existing bottles for formula that won't build on arm64? For example Rust should work fine under Rosetta 2, but currently we are unable to install it via Homebrew as it tries to build from source (even trying to force it to build x86_64 doesn't appear to work)

Yes, that's the plan.

We also have various DSLs which can play a part here.

Yes, that's the plan.

We also have various DSLs which can play a part here.

If there are various dependencies a developer will likely run into issues, as Rosetta-enabled and native-compiled libraries cannot be mixed. It should be a configuration option which defaults to disabled, and only is enabled on a case-by-case basis.

The following libraries/tools compile and can be used in most cases. I am trying to get Wireshark compiled on Apple Silicon, and need those natively, so far all functions needed by me work:

  • brotli
  • cunit
  • jansson
  • jemalloc
  • libev
  • libgpg-error
  • libssh
  • lua@5.1
  • lz4
  • minizip
  • nghttp2
  • opus
  • unrar

If there are various dependencies a developer will likely run into issues, as Rosetta-enabled and native-compiled libraries cannot be mixed.

Indeed - that's a good point.

It should be a configuration option which defaults to disabled, and only is enabled on a case-by-case basis.

Yeah, I don't see us allowing it unless something in the formula file says so.

And the last ones:

  • libilbc
  • libmaxminddb
  • libsmi
  • spandsp
  • zstd

Shared libraries should always be fat, by the way. Therefore Rosetta fallback can only be applied to executables or non-shared components.

I disagree. Shared libraries which are being downloaded may be fat, but I would not assume this being a necessity or the case in general. And especially if the libraries are being created on target it should never be the case. If you build qt5 from brew twice, it takes on the current Apple Silicon about 4 hours in a single run, 8 hours then with fat builds.

Compatibility: Xcode Beta 2 and Homebrew

@claui – you may with to add this to your issue.

homebrew won't compile native binaries with Xcode Beta 2. I tracked it down to the fact the homebrew is always passing -march=nehalem. Xcode Beta 1 ignored the argument.

Beta 2 test:

$ clang -march=nehalem test.c -o test
clang: error: the clang compiler does not support '-march=nehalem'

Update

This is a temporary hack that worked for me:

diff --git a/Library/Homebrew/hardware.rb b/Library/Homebrew/hardware.rb
index e056439d5..b1f746c41 100644
--- a/Library/Homebrew/hardware.rb
+++ b/Library/Homebrew/hardware.rb
@@ -13,7 +13,7 @@ module Hardware
       def optimization_flags
         @optimization_flags ||= {
           native:  arch_flag("native"),
-          nehalem: "-march=nehalem",
+          nehalem: "",
           core2:   "-march=core2",
           core:    "-march=prescott",
           armv6:   "-march=armv6",

you may with to add this to your issue.

@stuartcarnie Done, thanks!

Update: the Xcode 12 Beta 2 issue has been fixed.

I can report that brew install node@12 works on Apple Silicon with Xcode 12 beta 2.

commented

More positive test results (while working on some other things). These formula all install, test, and generate arm64 code for native code (I support the goal of have build-from-source generate fat binaries for shared libs, but nothing does at present):

  • argon2
  • aspell
  • cfitsio
  • composer
  • fastlane
  • freetds
  • giflib
  • hwloc
  • jansson
  • jemalloc
  • jq
  • libassuan
  • tree

Shared libraries should always be fat, by the way.

We're not going to do this.

@adib We don't have one yet. Our current plan is "get everything working on Apple Silicon/ARM". We're primarily a binary package manager so we're optimising for that use-case. I remember when universal binaries/libraries were all the rage on PPC/x86 and then x86/x86_64 and they caused us no end of pain. I'd rather we avoid that pain as long as possible.

What’s your plan on Rosetta fallback then?

We could have separate bottles wherever it’s necessary, with each bottle containing only a single architecture. We could then have Homebrew choose the architecture per-formula at brew install time.

We could have separate bottles wherever it’s necessary, with each bottle containing only a single architecture. We could then have Homebrew choose the architecture per-formula at brew install time.

@claui We are unlikely to take this approach because you wouldn't be able to have e.g. a x86_64 and ARM OpenSSL installed at the same time.

The best approach I can think of so far is allowing you to specify on ARM to use entirely x86_64 bottles through Rosetta and have one-homebrew-installation-per-architecture.

I can report that brew install node@12 works on Apple Silicon with Xcode 12 beta 2.

Thanks @daylen! Unexpected but really useful to know.

These formula all install, test, and generate arm64 code for native code […]:

Cool, thanks a lot @DodgyTim for the list! 🍻

libusb, libusbmuxd, libuv, libvpx, libzip, working, pass tests and are arm64 binaries

libvidstab fails to install - seems to be looking for hardware support for SSE instructions

tbb works with a patch: Homebrew/homebrew-core#57745

Does anybody have more info on gcc support? I imagine it might be quite a lift to add all the ARM64 MachO support etc. I was looking at OpenBLAS, which needs fortran, and the landscape looks a bit bleak there at the moment.

Someone mentioned it already in passing upthread but since it’s not in the list yet: tmux is available as arm64 and runs fine.

Does anybody have more info on gcc support? I imagine it might be quite a lift to add all the ARM64 MachO support etc. I was looking at OpenBLAS, which needs fortran, and the landscape looks a bit bleak there at the moment.

I haven't seen any chatter about it on the gcc mailing lists yet, might be a while out yet

nvm is not working

brew install nvm
Updating Homebrew...
Warning: You are using macOS 10.16.
We do not provide support for this pre-release version.
You will encounter build failures with some formulae.
Please create pull requests instead of asking for help on Homebrew's GitHub,
Discourse, Twitter or IRC. You are responsible for resolving any issues you
experience while you are running this pre-release version.

==> Downloading https://github.com/creationix/nvm/archive/v0.35.3.tar.gz
Already downloaded: /Users/user/Library/Caches/Homebrew/downloads/8da5209db2652dc1f8457ab0119381189e0d645ae407a27a3113297b502010f4--nvm-0.35.3.tar.gz
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
Error: An exception occurred within a child process:
  CompilerSelectionError: nvm cannot be built with any available compilers.
Install GNU's GCC:
  brew install gcc

@skhaz Looks like a general problem with the developer tool setup on your system:

xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun

Try xcode-select --install, or xcode-select --reset if that doesn't work.

@skhaz Looks like a general problem with the developer tool setup on your system:

xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun

Try xcode-select --install, or xcode-select --reset if that doesn't work.

this don't work, the screen keep "installing" forever

Screen Shot 2020-07-10 at 14 22 48

Screen Shot 2020-07-10 at 14 22 58

Apple claimed that the stuck installation issue was fixed in beta 2. If you are still having issues, you can download the command line tools from https://developer.apple.com/download/more/.

If this is on a DTK then ‘xcode-select --install’ doesn’t work as it tries to install the intel tools. I can’t recall if there is a workaround but worst case you’d have to restore using the image Apple provides.

Definitely not on the DTK because of

Warning: You are using macOS 10.16.

If this is on a DTK then xcode-select --install doesn’t work as it tries to install the intel tools. I can’t recall if there is a workaround but worst case you’d have to restore using the image Apple provides.

For those that ARE on the DTK, these steps worked for me: Homebrew/install#317 (comment). Credit to @Bo98.

terraform will not build with brew install -s terraform fails on building a dependency on Go v1.13

==> ./make.bash --no-clean
Building Go cmd/dist using /private/tmp/go@1.13-20200710-59142-1ghbgy1/go/gobootstrap.
./make.bash: line 180: 59172 Killed: 9               GOROOT="$GOROOT_BOOTSTRAP" GOOS="" GOARCH="" GO111MODULE=off "$GOROOT_BOOTSTRAP/bin/go" build -o cmd/dist/dist ./cmd/dist

==> Formula
Path: /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/go@1.13.rb
==> Configuration
HOMEBREW_VERSION: 2.4.5
ORIGIN: https://github.com/Homebrew/brew
HEAD: 6d2c39579e22d0ee9baccdccdd8a12efb8b00304
Last commit: 31 hours ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: 6ae8b26d3aa297c9fe2eea419a6f011aeeff7002
Core tap last commit: 33 minutes ago
HOMEBREW_PREFIX: /usr/local
HOMEBREW_MAKE_JOBS: 8
CPU: octa-core 64-bit arm_vortex_tempest
Homebrew Ruby: 2.6.3 => /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/bin/ruby
Clang: 12.0 build 1200
Git: 2.24.3 => /Applications/Xcode-beta.app/Contents/Developer/usr/bin/git
Curl: 7.64.1 => /usr/bin/curl
macOS: 11.0-arm64
CLT: N/A
Xcode: 12.0 => /Applications/Xcode-beta.app/Contents/Developer
==> ENV
HOMEBREW_CC: clang
HOMEBREW_CXX: clang++
MAKEFLAGS: -j8
CMAKE_PREFIX_PATH: /usr/local
CMAKE_INCLUDE_PATH: /Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk/usr/include/apache2:/Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk/System/Library/Frameworks/OpenGL.framework/Versions/Current/Headers
CMAKE_LIBRARY_PATH: /Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk/System/Library/Frameworks/OpenGL.framework/Versions/Current/Libraries
CMAKE_FRAMEWORK_PATH: /Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk/System/Library/Frameworks
PKG_CONFIG_LIBDIR: /usr/lib/pkgconfig:/usr/local/Homebrew/Library/Homebrew/os/mac/pkgconfig/11.0
HOMEBREW_GIT: git
HOMEBREW_SDKROOT: /Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk
ACLOCAL_PATH: /usr/local/share/aclocal
PATH: /usr/local/Homebrew/Library/Homebrew/shims/mac/super:/usr/bin:/bin:/usr/sbin:/sbin

Error: go@1.13 1.13.12 did not build
Logs:
     /Users/joe/Library/Logs/Homebrew/go@1.13/01.make.bash
     /Users/joe/Library/Logs/Homebrew/go@1.13/00.options.out
     /Users/joe/Library/Logs/Homebrew/go@1.13/01.make.bash.cc

helm fails to install with a dependency on Go v1.14.4

==> ./make.bash --no-clean
Building Go cmd/dist using /private/tmp/go-20200710-60649-a7wf2c/go/gobootstrap. ()
./make.bash: line 181: 60682 Killed: 9               GOROOT="$GOROOT_BOOTSTRAP" GOOS="" GOARCH="" GO111MODULE=off "$GOROOT_BOOTSTRAP/bin/go" build -o cmd/dist/dist ./cmd/dist

==> Formula
Path: /usr/local/Homebrew/Library/Taps/homebrew/homebrew-core/Formula/go.rb
==> Configuration
HOMEBREW_VERSION: 2.4.5
ORIGIN: https://github.com/Homebrew/brew
HEAD: 6d2c39579e22d0ee9baccdccdd8a12efb8b00304
Last commit: 31 hours ago
Core tap ORIGIN: https://github.com/Homebrew/homebrew-core
Core tap HEAD: 6ae8b26d3aa297c9fe2eea419a6f011aeeff7002
Core tap last commit: 37 minutes ago
HOMEBREW_PREFIX: /usr/local
HOMEBREW_MAKE_JOBS: 8
CPU: octa-core 64-bit arm_vortex_tempest
Homebrew Ruby: 2.6.3 => /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/bin/ruby
Clang: 12.0 build 1200
Git: 2.24.3 => /Applications/Xcode-beta.app/Contents/Developer/usr/bin/git
Curl: 7.64.1 => /usr/bin/curl
macOS: 11.0-arm64
CLT: N/A
Xcode: 12.0 => /Applications/Xcode-beta.app/Contents/Developer
==> ENV
HOMEBREW_CC: clang
HOMEBREW_CXX: clang++
MAKEFLAGS: -j8
CMAKE_PREFIX_PATH: /usr/local
CMAKE_INCLUDE_PATH: /Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk/usr/include/apache2:/Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk/System/Library/Frameworks/OpenGL.framework/Versions/Current/Headers
CMAKE_LIBRARY_PATH: /Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk/System/Library/Frameworks/OpenGL.framework/Versions/Current/Libraries
CMAKE_FRAMEWORK_PATH: /Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk/System/Library/Frameworks
PKG_CONFIG_LIBDIR: /usr/lib/pkgconfig:/usr/local/Homebrew/Library/Homebrew/os/mac/pkgconfig/11.0
HOMEBREW_GIT: git
HOMEBREW_SDKROOT: /Applications/Xcode-beta.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX11.0.sdk
ACLOCAL_PATH: /usr/local/share/aclocal
PATH: /usr/local/Homebrew/Library/Homebrew/shims/mac/super:/usr/bin:/bin:/usr/sbin:/sbin

Error: go 1.14.4 did not build
Logs:
     /Users/joe/Library/Logs/Homebrew/go/01.make.bash
     /Users/joe/Library/Logs/Homebrew/go/00.options.out
     /Users/joe/Library/Logs/Homebrew/go/01.make.bash.cc
Do not report this issue to Homebrew/brew or Homebrew/core!

subversion needs openjdk to compile on apple silicon. Not working at this point.

Does anybody have more info on gcc support?

@Keno I just noticed no one has done it yet so I submitted a bug against GCC:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96168

Update: The GCC team has triaged the bug as SUSPENDED, which basically confirms that a timely solution is not possible unless someone (not them) is going to volunteer to port the whole thing.

Update 2: According to a ball-park estimate made by a person very familiar with the process, adding Si support to GCC may take several months of full-time work.

@skhaz @gitizenme Thanks for your reports. As previously mentioned, we’re trying to keep this page focused on packages that work, or are being actively worked on.

Just checked mecab and mecab-ipadic: Installs fine, arm64 binary
Same goes for tmux.

Thanks @m4p! Noted.

nmap: Installs fine, arm64 binary

@m4p Thanks, nmap builds for me but errors out on brew test (or when I try to use it).

The output is:

Starting Nmap 7.80 ( https://nmap.org ) at 2020-07-12 00:45 CEST
Assertion failed: (res > 7), function nsock_library_initialize, file nsock_pool.c, line 307.
Abort trap: 6

Can you reproduce that?

@claui Looks like this happens on both Intel and Apple Silicon, found an issue reported earlier today here: nmap/nmap#2079

The following libraries/tools compile and can be used in most cases. I am trying to get Wireshark compiled on Apple Silicon, and need those natively, so far all functions needed by me work:

And the last ones:

@rknall Whoa, thanks a lot! Confirmed and noted.

redis

Thank you @stuartcarnie for the patch, much appreciated! 🍻

libusb, libusbmuxd, libuv, libvpx, libzip, working, pass tests and are arm64 binaries

Thanks @BytesGuy, noted.

Someone mentioned it already in passing upthread but since its not in the list yet: tmux is available as arm64 and runs fine.

You’re right @finestructure, thanks for noticing.

Added a second batch of formulae.
Now the list shows the top 512 installs, according to our 90-day analytics.

I’m so happy we’ve come that far already! Thanks everyone, and keep up the excellent work ❤️
With so many helping hands, I’m sure we’re going to make it by the end of the year. 🍺

Great work coordinating all this, @claui!

  • gawk, nano - installs, passes tests and is arm64
  • rabbitmq - blocked by openjdk
  • terraform - blocked by go
  • shellcheck - blocked by ghc
  • ghc - requires ghc to build, currently no binary distribution available for aarch64-apple-darwin to bootstrap with (maybe there is a way around this but I haven't found anything yet). Additionally the Formula builds gmp so we would need to port the gmp patch over too.
  • swiftlint, putty, xxhash, tor, pstree - installs, passes tests and is arm64
  • blueutil - install, passes tests and is a universal binary (arm64 + x86_64)
  • circleci - fails due to depending on go