Help us understand the problem. What is going on with this article?

HighSierraにしてpyenvからpython入れようとしたら失敗した”The Python ssl extension was not compiled. Missing the OpenSSL lib?”

More than 3 years have passed since last update.

High Sierraにしてpyenvからpython入れようとしたら失敗した

pyenvは普通にhomebrewで入れた

$ pyenv install 3.6.3
Downloading Python-3.6.3.tar.xz...
-> https://www.python.org/ftp/python/3.6.3/Python-3.6.3.tar.xz
Installing Python-3.6.3...
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 10.13 using python-build 20160602)

Inspect or clean up the working tree at /var/folders/j5/7gjxgk7n6cx681n7_0hx6ylw0000gn/T/python-build.20171006102601.12194
Results logged to /var/folders/j5/7gjxgk7n6cx681n7_0hx6ylw0000gn/T/python-build.20171006102601.12194.log

Last 10 log lines:
            upgrade) ensurepip="--upgrade" ;; \
            install|*) ensurepip="" ;; \
        esac; \
         ./python.exe -E -m ensurepip \
            $ensurepip --root=/ ; \
    fi
Collecting setuptools
Collecting pip
Installing collected packages: setuptools, pip
Successfully installed pip-9.0.1 setuptools-28.8.0

エラーメッセージに
https://github.com/pyenv/pyenv/wiki/Common-build-problems

ここを見ろとあったので,言われたようにやったら入った

$ CFLAGS="-I$(brew --prefix openssl)/include" LDFLAGS="-L$(brew --prefix openssl)/lib" pyenv install -v 3.6.3

はい

$ pyenv versions
* system (set by /Users/so/.pyenv/version)
  3.6.3
ayihis@github
超絶見習い情報系学生. 僕みたいなLinuxと出会ったばっかりのような初心者がつまずく内容を備忘録的な感じで情報共有したいです
Why not register and get more from Qiita?
  1. We will deliver articles that match you
    By following users and tags, you can catch up information on technical fields that you are interested in as a whole
  2. you can read useful information later efficiently
    By "stocking" the articles you like, you can search right away