的ARM处理器上的Homebrew中安装

的ARM处理器上的Homebrew中安装

本文介绍了错误:无法在Intel默认前缀(/usr/local)的ARM处理器上的Homebrew中安装的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用最新的 Apple M1 芯片处理器.而且在安装应用程序时,我总是出错.

I use the latest Apple M1 chip processor. And I keep getting errors while application installation.

说.

brew install openjdk@11
Error: Cannot install in Homebrew on ARM processor in Intel default prefix (/usr/local)!
Please create a new installation in /opt/homebrew using one of the
"Alternative Installs" from:
  https://docs.brew.sh/Installation
You can migrate your previously installed formula list with:
  brew bundle dump

需要帮助以遵循确切的步骤.

Need help with exact steps to follow.

推荐答案

对于它的价值,在安装Homebrew之前,您需要为新的ARM芯片(M1芯片)安装Rosetta2仿真器.我刚刚使用以下命令通过终端安装了Rosetta2:

For what it's worth, before installing Homebrew you will need to install Rosetta2 emulator for the new ARM silicon (M1 chip). I just installed Rosetta2 via terminal using:

/usr/sbin/softwareupdate --install-rosetta --agree-to-license

这将安装Rosetta2,而无需额外单击按钮.

This will install rosetta2 with no extra button clicks.

在上面安装完Rosetta2之后,您可以使用Homebrew cmd并为ARM M1芯片安装Homebrew: arch -x86_64/bin/bash -c" $(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"

After installing Rosetta2 above you can then use the Homebrew cmd and install Homebrew for ARM M1 chip: arch -x86_64 /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"

一旦安装了用于M1 ARM的Homebrew,请使用以下Homebrew命令安装软件包: arch -x86_64 brew install< package>

Once Homebrew for M1 ARM is installed use this Homebrew command to install packages: arch -x86_64 brew install <package>

这篇关于错误:无法在Intel默认前缀(/usr/local)的ARM处理器上的Homebrew中安装的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-11 00:44