如何解决在 macOS M1 上使用 pyenv 安装 python 的问题
我正在尝试使用 pyenv 准备多版本 python 开发环境。我已经成功安装了 pyenv。我通过自制软件 (https://github.com/pyenv/pyenv#homebrew-on-macos) 安装了 pyenv。但是当我尝试安装python版本时,我遇到了一个错误:
➜ live_xr_cms_api git:(dev) ✗ pyenv install 3.9.6
python-build: use openssl@1.1 from homebrew
python-build: use readline from homebrew
Downloading Python-3.9.6.tar.xz...
-> https://www.python.org/ftp/python/3.9.6/Python-3.9.6.tar.xz
Installing Python-3.9.6...
python-build: use readline from homebrew
python-build: use zlib from xcode sdk
WARNING: The Python readline extension was not compiled. Missing the GNU readline lib?
ERROR: The Python ssl extension was not compiled. Missing the OpenSSL lib?
Please consult to the Wiki page to fix the problem.
https://github.com/pyenv/pyenv/wiki/Common-build-problems
BUILD FAILED (OS X 11.4 using python-build 20180424)
Inspect or clean up the working tree at /var/folders/b_/4pdsw1_15bx8l23n5wbblflc0000gn/T/python-build.20210712183213.13974
Results logged to /var/folders/b_/4pdsw1_15bx8l23n5wbblflc0000gn/T/python-build.20210712183213.13974.log
Last 10 log lines:
$ensurepip --root=/ ; \
fi
Looking in links: /var/folders/b_/4pdsw1_15bx8l23n5wbblflc0000gn/T/tmp85zin3_g
Processing /private/var/folders/b_/4pdsw1_15bx8l23n5wbblflc0000gn/T/tmp85zin3_g/setuptools-56.0.0-py3-none-any.whl
Processing /private/var/folders/b_/4pdsw1_15bx8l23n5wbblflc0000gn/T/tmp85zin3_g/pip-21.1.3-py3-none-any.whl
Installing collected packages: setuptools,pip
WARNING: The scripts pip3 and pip3.9 are installed in '/Users/anzhari/.pyenv/versions/3.9.6/bin' which is not on PATH.
Consider adding this directory to PATH or,if you prefer to suppress this warning,use --no-warn-script-location.
NOTE: The current PATH contains path(s) starting with `~`,which may not be expanded by all applications.
Successfully installed pip-21.1.3 setuptools-56.0.0
版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。