[英]how to install python 2.6 on centos 8?
There is no python 2.6.x in centos 8. But I need python 2.6 to install a tool. centos 8 中没有 python 2.6.x。但我需要 python 2.6 来安装工具。 I download the python 2.6.7 source code and run
./configure
.我下载 python 2.6.7 源代码并运行
./configure
。 I got config successfully.我成功获得了配置。 Then I run
make
, I got an error *** ERROR: renaming "dbm" since importing it failed: build/lib.linux-x86_64-2.6/dbm.so: undefined symbol: dbm_nextkey
.然后我运行
make
,我得到一个错误*** ERROR: renaming "dbm" since importing it failed: build/lib.linux-x86_64-2.6/dbm.so: undefined symbol: dbm_nextkey
。 How to fix the error?如何修复错误?
I don't know how to fix your error.我不知道如何解决您的错误。 Because the python 2.6.x is too old to be installed.
因为 python 2.6.x 太旧,无法安装。 Python 2 had been abandoned on January.
Python 2 已于 1 月弃用。 I try to install python 2.6.x use
pyenv
on centos 7 and successfully.我尝试在 centos 7 上安装 python 2.6.x 使用
pyenv
并成功。 Maybe you can try it.也许你可以试试。
git clone https://github.com/pyenv/pyenv.git $HOME/.pyenv
vim $HOME/.bashrc
export PYENV_ROOT="$HOME/.pyenv"
export PATH="$PYENV_ROOT/bin:$PATH"
if command -v pyenv 1>/dev/null 2>&1; then
eval "$(pyenv init -)"
fi
source $HOME/.bashrc
pyenv install -l
yum -y install patch & pyenv install 2.6.7
pyenv versions
Hope this helps, sorry for the long link希望这会有所帮助,抱歉长链接
https://linuxconfig.org/install-python-2-on-redhat-8 https://linuxconfig.org/install-python-2-on-redhat-8
https://www.google.com/url?sa=t&source=web&rct=j&url=https://linuxize.com/post/how-to-install-python-on-centos-8/%23installing-python-2-on-centos-8&ved=2ahUKEwieoOi_r8LqAhUvyoUKHWcPCoIQygQwA3oECAIQBQ&usg=AOvVaw1B197tR-XZ0sMJDTF9p0Vr&cshid=1594373386822 https://www.google.com/url?sa=t&source=web&rct=j&url=https://linuxize.com/post/how-to-install-python-on-centos-8/%23installing-python-2 -on-centos-8&ved=2ahUKEwieoOi_r8LqAhUvyoUKHWcPCoIQygQwA3oECAIQBQ&usg=AOvVaw1B197tR-XZ0sMJDTF9p0Vr&cshid=1594373386822
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.