~~ Es tut mir leid. Es ist immer noch ungelöst. Wenn Sie es in der Vergangenheit gelöst haben, würde ich es begrüßen, wenn Sie mir einen Rat geben könnten. ~~
Es scheint, dass es sich irgendwie bewegt hat.
Jetzt funktioniert es! https://github.com/yyuu/pyenv/issues/448#issuecomment-220652296
export CFLAGS="-I$(brew --prefix openssl)/include"
export LDFLAGS="-L$(brew --prefix openssl)/lib -L$(brew --prefix sqlite3)/lib"
export CPPFLAGS="-I$(brew --prefix sqlite3)/include"
Aber ich weiß nicht, warum es nicht funktioniert hat und warum es behoben wurde. .. ..
$ pyenv install 3.5.2
Installing Python-3.5.2...
BUILD FAILED (OS X 10.12.1 using python-build 20160602)
Inspect or clean up the working tree at /var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103191050.41922
Results logged to /var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103191050.41922.log
Last 10 log lines:
import pip
File "/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/tmp3hlbqezp/pip-8.1.1-py2.py3-none-any.whl/pip/__init__.py", line 14, in <module>
File "/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/tmp3hlbqezp/pip-8.1.1-py2.py3-none-any.whl/pip/utils/__init__.py", line 27, in <module>
File "/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/tmp3hlbqezp/pip-8.1.1-py2.py3-none-any.whl/pip/_vendor/pkg_resources/__init__.py", line 36, in <module>
File "/private/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103191050.41922/Python-3.5.2/Lib/plistlib.py", line 65, in <module>
from xml.parsers.expat import ParserCreate
File "/private/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103191050.41922/Python-3.5.2/Lib/xml/parsers/expat.py", line 4, in <module>
from pyexpat import *
ImportError: No module named 'pyexpat'
make: *** [install] Error 1
Sogar auf Github wurde mir gesagt "Weil es kaputt ist ('-`) Shiranano"
ImportError: No module named pyexpat · Issue #544 · yyuu/pyenv
Ich möchte etwas tun, das kein einziges Mal da war.
$ echo $PYENV_ROOT
/usr/local/var/pyenv
$ rm -r /usr/local/var/pyenv
$ brew uninstall pyenv python
$ brew install pyenv
$ pyenv install 3.5.2
Nein, es ist nicht gut!
Downloading Python-3.5.2.tar.xz...
-> https://www.python.org/ftp/python/3.5.2/Python-3.5.2.tar.xz
Installing Python-3.5.2...
BUILD FAILED (OS X 10.12.1 using python-build 20160602)
Inspect or clean up the working tree at /var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103193542.66147
Results logged to /var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103193542.66147.log
Last 10 log lines:
import pip
File "/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/tmpsbqryzv7/pip-8.1.1-py2.py3-none-any.whl/pip/__init__.py", line 14, in <module>
File "/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/tmpsbqryzv7/pip-8.1.1-py2.py3-none-any.whl/pip/utils/__init__.py", line 27, in <module>
File "/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/tmpsbqryzv7/pip-8.1.1-py2.py3-none-any.whl/pip/_vendor/pkg_resources/__init__.py", line 36, in <module>
File "/private/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103193542.66147/Python-3.5.2/Lib/plistlib.py", line 65, in <module>
from xml.parsers.expat import ParserCreate
File "/private/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103193542.66147/Python-3.5.2/Lib/xml/parsers/expat.py", line 4, in <module>
from pyexpat import *
ImportError: No module named 'pyexpat'
make: *** [install] Error 1
Siehe hier ...
Python 3.4.2 doesn't build on OS X 10.10 Yosemite · Issue #298 · yyuu/pyenv
$ CFLAGS="-I$(xcrun --show-sdk-path)/usr/include" pyenv install 3.5.2
Downloading Python-3.5.2.tar.xz...
-> https://www.python.org/ftp/python/3.5.2/Python-3.5.2.tar.xz
Installing Python-3.5.2...
BUILD FAILED (OS X 10.12.1 using python-build 20160602)
Inspect or clean up the working tree at /var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103193925.80736
Results logged to /var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103193925.80736.log
Last 10 log lines:
import pip
File "/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/tmp7cp6pxz_/pip-8.1.1-py2.py3-none-any.whl/pip/__init__.py", line 14, in <module>
File "/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/tmp7cp6pxz_/pip-8.1.1-py2.py3-none-any.whl/pip/utils/__init__.py", line 27, in <module>
File "/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/tmp7cp6pxz_/pip-8.1.1-py2.py3-none-any.whl/pip/_vendor/pkg_resources/__init__.py", line 36, in <module>
File "/private/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103193925.80736/Python-3.5.2/Lib/plistlib.py", line 65, in <module>
from xml.parsers.expat import ParserCreate
File "/private/var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103193925.80736/Python-3.5.2/Lib/xml/parsers/expat.py", line 4, in <module>
from pyexpat import *
ImportError: No module named 'pyexpat'
make: *** [install] Error 1
Wird es sich ändern ...
$ pyenv install 2.7.12
Downloading Python-2.7.12.tar.xz...
-> https://www.python.org/ftp/python/2.7.12/Python-2.7.12.tar.xz
Installing Python-2.7.12...
WARNING: The Python readline extension was not compiled. Missing the GNU readline lib?
Installing pip from https://bootstrap.pypa.io/get-pip.py...
error: failed to install pip via get-pip.py
BUILD FAILED (OS X 10.12.1 using python-build 20160602)
Inspect or clean up the working tree at /var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103194730.10697
Results logged to /var/folders/g5/b_nhsv5546g9pf7_k7xynpxw0000gn/T/python-build.20161103194730.10697.log
Last 10 log lines:
info = _mac_ver_xml()
File "/usr/local/var/pyenv/versions/2.7.12/lib/python2.7/platform.py", line 739, in _mac_ver_xml
pl = plistlib.readPlist(fn)
File "/usr/local/var/pyenv/versions/2.7.12/lib/python2.7/plistlib.py", line 78, in readPlist
rootObject = p.parse(pathOrFile)
File "/usr/local/var/pyenv/versions/2.7.12/lib/python2.7/plistlib.py", line 401, in parse
from xml.parsers.expat import ParserCreate
File "/usr/local/var/pyenv/versions/2.7.12/lib/python2.7/xml/parsers/expat.py", line 4, in <module>
from pyexpat import *
ImportError: No module named pyexpat
Recommended Posts