编译安装Python3.11

1、安装依赖,下载安装包

yum -y install bzip2-devel openssl-devel libffi-devel
wget https://repo.huaweicloud.com/python/3.11.0/Python-3.11.0.tar.xz

2、编译安装

  1. SSL模块需要依赖openssl 1.1.1版本及以上,安装参考:https://www.luzhining.com/blog/article/detail?id=126
tar -xf Python-3.11.0.tar.xz
cd  Python-3.11.0
./configure  --prefix=/usr/local/python311  --enable-optimizations  --with-openssl=/usr/local/openssl --with-openssl-rpath=auto
讨论数量: 0

请勿发布不友善或者负能量的内容。与人为善,比聪明更重要!