使用官网的源码包下载的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等等
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等等