Chinaunix首页 | 论坛 | 博客
  • 博客访问: 1101071
  • 博文数量: 165
  • 博客积分: 5957
  • 博客等级: 大校
  • 技术积分: 2015
  • 用 户 组: 普通用户
  • 注册时间: 2010-11-24 15:04
文章分类

全部博文(165)

文章存档

2014年(10)

2013年(14)

2012年(9)

2011年(22)

2010年(17)

2009年(17)

2008年(26)

2007年(34)

2006年(16)

我的朋友

分类: LINUX

2011-03-17 16:36:21

MySQL-python-1.2.3安装过程:
  1. wget http://sourceforge.net/projects/mysql-python/files/mysql-python/1.2.3/MySQL-python-1.2.3.tar.gz/download
  2. tar -zxvf MySQL-python-1.2.3.tar.gz
  3. cd MySQL-python-1.2.3
  4. CFLAGS=-I/opt/include/python2.5 LDFLAGS=-L/opt/lib/python2.5 python setup.py build
  5. python setup.py install
import时报错:
  1. >>> import MySQLdb
  2. Traceback (most recent call last):
  3.   File "", line 1, in ?
  4.   File "MySQLdb/__init__.py", line 19, in ?
  5.     import _mysql
  6.   File "build/bdist.linux-x86_64/egg/_mysql.py", line 7, in ?
  7.   File "build/bdist.linux-x86_64/egg/_mysql.py", line 6, in __bootstrap__
  8. ImportError: /root/.python-eggs/MySQL_python-1.2.3-py2.4-linux-x86_64.egg-tmp/_mysql.so: undefined symbol: Py_InitModule4_64
阅读(8214) | 评论(0) | 转发(0) |
0

上一篇:python——IPy库

下一篇:30岁前应做好的事

给主人留下些什么吧!~~