安装python的时候遇到的问题,无法安装bz2modules等

使用官网的源码包下载的python:
http://www.python.org/getit/
解压之后,进行安装操作:
./configure
make
make报错信息:
Python build finished, but the necessary bits to build these modules were not found:
_bz2               _curses            _curses_panel  
_dbm               _gdbm              _lzma          
_sqlite3           _tkinter           readline 

此类问题是由于缺少一些devel包造成的,以bz2为例:
yum install bzip2-devel
安装完成之后,重新make便可
可以对生成的python文件进行测试:
./python -c "import bz2; print bz2.__doc__"
输出信息如下:
The python bz2 module provides a comprehensive interface for
the bz2 compression library. It implements a complete file
interface, one shot (de)compression functions, and types for
sequential (de)compression.
便可确定该包成功安装。其他需要的包都是类似的readline-devel,openssl-devel等等
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 1
    评论
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值