天天看点

ubuntu12.04桌面版安装python模块常见问题

1、致命错误:Python.h:没有那个文件或目录

        解决方法是安装python-dev,这是Python的头文件和静态库包。执行sudo apt-get install python-dev即可。

2、EnvironmentError: mysql_config not found

        很明显错误是指没有mysql_config这个文件。执行sudo find / -name mysql_config,没有任何数据,表明系统中没有mysql_config这个文件。有人解释说使用apt-get安装的MySQL是没有mysql_config这个文件的。解决办法:执行sudo apt-get install libmysqld-dev即可。

3、致命错误: libxml/xmlversion.h:没有那个文件或目录

        解决办法: 执行sudo apt-get install libxml2 libxml2-dev libxslt-dev即可。

4、The required version of distribute (>=0.6.28) is not available, and can't be installed while this script is running. Please install a more recent version first, using 'easy_install -U distribute'.

        解决办法:执行sudo easy_install -U distribute即可。