centos7安装Python3.7,执行./configure时报错,configure: error: no acceptable C compiler found in $PATH

执行./configure时报错,configure: error: no acceptable C compiler found in $PATH

在安装python3.7,配置编译路径时会遇到以下问题:

copyconfigure: error: no acceptable C compiler found in $PATH
See `config.log' for more details

查看得知没有找到合适的编译器。

可以使用下面的命令安装编译器,解决./configure时报错。

copysudo yum install gcc-c++  # 使用sudo yum install gcc-c++时会自动安装/升级gcc及其他依赖的包

重新执行以下命令

copy./configure --prefix=/usr/local/python3
make
make install
posted @   Teddy_boy  阅读(7107)  评论(0编辑  收藏  举报
编辑推荐:
· 一个奇形怪状的面试题:Bean中的CHM要不要加volatile?
· [.NET]调用本地 Deepseek 模型
· 一个费力不讨好的项目,让我损失了近一半的绩效!
· .NET Core 托管堆内存泄露/CPU异常的常见思路
· PostgreSQL 和 SQL Server 在统计信息维护中的关键差异
阅读排行:
· DeepSeek “源神”启动!「GitHub 热点速览」
· 微软正式发布.NET 10 Preview 1:开启下一代开发框架新篇章
· 我与微信审核的“相爱相杀”看个人小程序副业
· C# 集成 DeepSeek 模型实现 AI 私有化(本地部署与 API 调用教程)
· DeepSeek R1 简明指南:架构、训练、本地部署及硬件要求
点击右上角即可分享
微信分享提示