如何解决在 M1 macOS 中安装 drake 时出现的问题
我按照webpage中的步骤,执行./setup/mac/install_prereqs.sh
时出现问题
drake % ./setup/mac/install_prereqs.sh
+ binary_distribution_args=()
+ source_distribution_args=()
+ '[' '' '!=' '' ']'
+ source ./setup/mac/binary_distribution/install_prereqs.sh ''
++ set -euxo pipefail
++ with_update=1
++ '[' '' '!=' '' ']'
++ [[ 501 -eq 0 ]]
++ command -v conda
++ command -v brew
++ [[ -z '' ]]
++ export HOMEBREW_NO_AUTO_UPDATE=1
++ HOMEBREW_NO_AUTO_UPDATE=1
++ export HOMEBREW_NO_INSTALL_CLEANUP=1
++ HOMEBREW_NO_INSTALL_CLEANUP=1
++ binary_distribution_called_update=0
++ [[ 1 -eq 1 ]]
++ brew update
Already up-to-date.
++ binary_distribution_called_update=1
++ brew tap robotlocomotion/director
+++ cat
++ brew uninstall --force robotlocomotion/director/scipy@1.5.4 robotlocomotion/director/numpy@1.19.4
++ brew bundle --file=./setup/mac/binary_distribution/Brewfile --no-lock
Using dreal-deps/ibex
Using robotlocomotion/director
Using adoptopenjdk
Using clp
Using cmake
Using double-conversion
==> Installing ibex@2.7.4 from dreal-deps/ibex
==> Downloading https://github.com/dreal-deps/ibex-lib/archive/ibex-2.7.4_10.tar.gz
Already downloaded: /Users/marui/Library/Caches/Homebrew/downloads/cf1b94f6783b4d23cc0bd34c10833f34cea5e7cff82ddfa24d7613f439a9d7f2--ibex-lib-ibex-2.7.4_10.tar.gz
==> ./waf configure --prefix=/opt/homebrew/Cellar/ibex@2.7.4/2.7.4_10 --enable-shared --with-optim --with-solver --with-affine-extended --interval-lib=filib --lp-lib=clp --clp-path=/opt/homebrew/opt/clp
Last 15 lines from /Users/marui/Library/Logs/Homebrew/ibex@2.7.4/01.waf:
Checking for program 'make' : /opt/homebrew/Library/Homebrew/shims/mac/super/make
Applying patch : filibsrc-3.0.2.2.all.all.patch
Calling configure : done
Calling make : done
Calling install : done
Checking for header interval/interval.hpp : yes
Checking for library prim : yes
Checking for compiler flags -frounding-math : yes
Checking for compiler flags -ffloat-store : yes
Checking for header interval/interval.hpp with -msse3 : yes
Configuration of the library for LP
Library for LP : clp
Checking for 'clp' : not found
The configuration failed
(complete log in /private/tmp/ibex-2.7.4-20210319-75719-hq0bkg/ibex-lib-ibex-2.7.4_10/__build__/config.log)
Do not report this issue to Homebrew/brew or Homebrew/core!
Installing dreal-deps/ibex/ibex@2.7.4 has failed!
Using eigen
Using gcc
Using fmt
Using gflags
Using glew
Using glib
Using graphviz
Using ipopt
Using libyaml
Using lz4
Using nlopt
Using numpy
Using openblas
Using pkg-config
Using python@3.9
Using scipy
Using spdlog
Using suite-sparse
Using tinyxml
Using tinyxml2
Using robotlocomotion/director/vtk@8.2.0
Using xz
Using yaml-cpp
Using zeromq
Homebrew Bundle failed! 1 Brewfile dependency failed to install.
我该如何解决这个问题?提前致谢。
解决方法
官方回答:“在 macOS 上,x86_64 是唯一支持的架构,不支持在 arm64 上的 Rosetta 2 仿真下运行 Drake。” -- https://drake.mit.edu/developers.html#supported-configurations 截至 2021-03 -18.
您可以订阅 https://github.com/RobotLocomotion/drake/issues/14555 以获取有关 M1 支持的任何更新。
但是,如果您想尝试在本地破解它,您可以尝试注释掉不成功的自制软件依赖项(例如,本例中的 IBEX)。
在禁用 IBEX 的情况下,您还必须 bazel build --define=NO_DREAL=ON
暂时禁用 dReal。很可能,其他依赖项也会失败,但我们还没有在 M1 上进行测试,所以我们不知道它离工作有多近。
我已提交 https://github.com/dreal/homebrew-dreal/issues/10 以防我们可以轻松解决 IBEX 问题。
另一种选择是启动 Ubuntu VM(基于 18.04 或 20.04)。
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。