deepin15.4使用pyenv安装python,编译出错
Tofloor
poster avatar
zonzely
deepin
2017-07-17 16:17
Author
本帖最后由 zonzely 于 2017-7-17 08:19 编辑

使用pyenv 安装python, 编译时出错, pyenv版本 1.1.0, 错误信息如下:
  1. ➜  ~ pyenv install 3.5.2
  2. Installing Python-3.5.2...
  3. patching file Lib/venv/scripts/posix/activate.fish
  4. ERROR: The Python ssl extension was not compiled. Missing the OpenSSL lib?

  5. Please consult to the Wiki page to fix the problem.
  6. https://github.com/pyenv/pyenv/wiki/Common-build-problems


  7. BUILD FAILED (Deepin 15.4 using python-build 20160602)

  8. Inspect or clean up the working tree at /tmp/python-build.20170717074120.10900
  9. Results logged to /tmp/python-build.20170717074120.10900.log

  10. Last 10 log lines:
  11. (cd /home/zonzely/.pyenv/versions/3.5.2/share/man/man1; ln -s python3.5.1 python3.1)
  12. if test "xupgrade" != "xno"  ; then \
  13.         case upgrade in \
  14.                 upgrade) ensurepip="--upgrade" ;; \
  15.                 install|*) ensurepip="" ;; \
  16.         esac; \
  17.          ./python -E -m ensurepip \
  18.                 $ensurepip --root=/ ; \
  19. fi
  20. Ignoring ensurepip failure: pip 8.1.1 requires SSL/TLS
Copy the Code


根据https://github.com/pyenv/pyenv/wiki/Common-build-problems#requirements, 我尝试
  1. sudo apt-get install -y make build-essential libssl-dev zlib1g-dev libbz2-dev \
  2. libreadline-dev libsqlite3-dev wget curl llvm libncurses5-dev libncursesw5-dev \
  3. xz-utils tk-dev
Copy the Code
,并没有起作用。

请问我该怎么做呢?
Reply Favorite View the author
All Replies
avatar
jingle
deepin
2017-07-17 18:30
#1
不是很懂  帮你提了一个 https://github.com/pyenv/pyenv/issues/950
Reply View the author
avatar
zonzely
deepin
2017-07-18 07:27
#2
https://bbs.deepin.org/post/142685
不是很懂  帮你提了一个 https://github.com/pyenv/pyenv/issues/950

谢谢啦~~~~~~~~~~
Reply View the author
avatar
jantacy
deepin
2017-07-18 08:51
#3
用virtualenv
Reply View the author
avatar
v6i6v
deepin
2017-11-11 22:19
#4
试过了都不行。
我的方法是:
cd ~/.pyenv/
mkdir cache
把要安装的python安装包扔进去,再次执行安装就好了
pyenv install 3.6.3 -v

Reply View the author
avatar
nocmt
deepin
2017-11-12 01:36
#5
编译个Python3,用自带的 venv
Reply View the author