Pyenv builds Python versions from source and therefore requires all the necessary build dependencies.
sudo yum install gcc zlib-devel bzip2 bzip2-devel patch readline-devel sqlite sqlite-devel openssl-devel tk-devel libffi-develYou'll need git installed to be able to clone the repositories
sudo yum install gitgit clone https://github.com/pyenv/pyenv.git ~/.pyenvecho ' ' >> ~/.bash_profile
echo '# Pyenv Configuration' >> ~/.bash_profile
echo 'export PYENV_ROOT="$HOME/.pyenv"' >> ~/.bash_profile
echo 'export PATH="$PYENV_ROOT/bin:$PATH"' >> ~/.bash_profile
echo 'eval "$(pyenv init -)"' >> ~/.bash_profilesource ~/.bash_profilepyenvTo prevent any existing system dependencies from breaking, it's a good idea to setup pyenv with versions of the current existing python installations.
Make a note of the version numbers currently installed for python2 and python3.
$ python -V
Python 2.7.5
$ python3 -V
Python 3.6.8pyenv install 2.7.5pyenv install 3.6.8pyenv global 3.6.8 2.7.5Check that the versions are associated correctly
$ pyenv versions
system
* 2.7.5 (set by /home/norsey/.pyenv/version)
* 3.6.8 (set by /home/norsey/.pyenv/version)pip install --upgrade pippip install --user pipenv
Hi,
Thank you for this guide.. I needed to install some other packages for this to work:
pyenv install 3.10new yum install command:
Errors I got:
solution:
solution:
success: