", line 1, in 发布时间:2019-09-02 07:39:22编辑:auto阅读(1609) 报错如下错误: >>> import sqlite3 Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/usr/local/lib/python2.7/sqlite3/__init__.py", line 24, in <module> from dbapi2 import * File "/usr/local/lib/python2.7/sqlite3/dbapi2.py", line 27, in <module> from _sqlite3 import * ImportError: /usr/local/lib/python2.7/lib-dynload/_sqlite3.so: wrong ELF class: ELFCLASS32 >>> exit() 系统上已经安装了Python-2.7.4,由于要升级nltk模块,升级后出现上述错误,后来发现_SQLite3出现问题,百度、搜狗都找遍了,就是没找到解决办法,后来听一个哥们说直接yum安装SQLite和SQLite-devel,然后重新编译Python,正好手头上有Python-2.7.10,说动手就动手,开始干起来,具体流程如下: 下载python-2.17.10.tar.gz,pip-9.0.1.tar.gz,setuptools-32.1.0.zip 依次安装如下: yum -y install sqlite selite-devel tar xf python-2.17.10.tar.gz cd python-2.17.10 python setup.py install ################## tar xf setuptools-32.1.0.zip cd setuptools-32.1.0 python setup.py install #################### tar xf pip-9.0.1.tar.gz cd pip-9.0.1 python setup.py install
上一篇:
JSP学习笔记(3)——域对象的属性操作 下一篇:
sqlite3_exec函数的使用 47868 46434 37321 34767 29337 25999 24952 19970 19568 18056 5811° 6436° 5953° 5979° 7083° 5929° 5970° 6462° 6426° 7804° ImportError: No mod