python3 提示sqlite模块不存在

首先
yum install sqlite-devel -y

然后重装下python3(一定要重装)
# cd Python-3.4.2
# ./configure --prefix=/usr/local/python3
# make && make install


测试sqlite3模块,没提示错误就说明成功了

<pre name="code" class="python">[root@mail Python-3.4.2]# python3
Python 3.4.2 (default, Jul 20 2016, 22:36:42)
[GCC 4.4.7 20120313 (Red Hat 4.4.7-16)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import sqlite3
>>>

————————————————
版权声明:本文为CSDN博主「爱代码也爱生活」的原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/nuli888/article/details/51973738

posted @ 2019-10-21 23:06  brady-wang  阅读(556)  评论(0编辑  收藏  举报