安装Python-3.5.2过程中常见的几种错误

来源:互联网 发布:sql删除表数据 编辑:程序博客网 时间:2024/06/09 14:03

1.Ignoring ensurepip failure: pip-8.1.1 requires SSL/TLS

错误详细:

Last 10 log lines:
(cd /home/dabney/.pyenv/versions/3.5.2/share/man/man1; ln -s python3.5.2 python3.1)
if test "xupgrade" != "xno"  ; then \
                case upgrade in \
                        upgrade) ensurepip="--upgrade" ;; \
                        install|*) ensurepip="" ;; \
                 esac; \
                 ./python -E -m ensurepip \
                        $ensurepip --root=/ ; \
        fi
Ignoring ensurepip failure: pip-8.1.1 requires SSL/TLS


错误解决方案:

apt-get install libssl-dev


==========================================================================================


2.

错误描述

python-config: $(srcdir)/Misc/python-config.in Misc/python-config.sh
  sed -e "s,@EXENAME@,$(BINDIR)/python$(LDVERSION)$(EXE)," < $(srcdir)/Misc/python-config.in >python-config.py
  # Replace makefile compat. variable references with shell script compat. ones; $(VAR) -> ${VAR}
  sed -e 's,\$$(\([A-Za-z0-9_]*\)),\$$\{\1\},g' < Misc/python-config.sh >python-config
# On Darwin, always use the python version of the script, the shell
# version doesn't use the compiler customizations that are provided
# in python (_osx_support.py).
if test `uname -s` = Darwin; then \
cp python-config.py python-config; \
fi

错误解决方案

将系统里面原有系统里面的usr/bin/python给删掉,以及加上apt-get install libssl-dev,然后依次运行make clean 、make、make install即可。


==========================================================================================


3.Compression requires the (missing) zlib module

错误描述

  File "/usr/local/lib/python3.5.2/zipfile.py", line 681, in __init__
    "Compression requires the (missing) zlib module"
RuntimeError: Compression requires the (missing) zlib module

解决方案:

apt-get install zlib1g
apt-get install zlib1g.dev



0 0
原创粉丝点击