日韩性视频-久久久蜜桃-www中文字幕-在线中文字幕av-亚洲欧美一区二区三区四区-撸久久-香蕉视频一区-久久无码精品丰满人妻-国产高潮av-激情福利社-日韩av网址大全-国产精品久久999-日本五十路在线-性欧美在线-久久99精品波多结衣一区-男女午夜免费视频-黑人极品ⅴideos精品欧美棵-人人妻人人澡人人爽精品欧美一区-日韩一区在线看-欧美a级在线免费观看

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 运维知识 > 数据库 >内容正文

数据库

python安装mysqlclient报错_Centos 6 – sudo在为Python 3.4安装mysqlclient时...

發布時間:2025/4/5 数据库 32 豆豆
生活随笔 收集整理的這篇文章主要介紹了 python安装mysqlclient报错_Centos 6 – sudo在为Python 3.4安装mysqlclient时... 小編覺得挺不錯的,現在分享給大家,幫大家做個參考.

我是Centos 6和Linux的新手.我需要安裝Python 3.4,但Centos 6默認使用Python 2.6.6.

我已經將Python 3.4安裝到/usr/local/lib/Python3.4.

但是,我在安裝mysqlclient時遇到問題.

我試過pip3.4安裝mysqlclient.

這是錯誤消息.

錯誤

_mysql.c:29:23: error: my_config.h: No such file or directory

_mysql.c:30:19: error: mysql.h: No such file or directory

_mysql.c:31:26: error: mysqld_error.h: No such file or directory

_mysql.c:51:20: error: errmsg.h: No such file or directory

_mysql.c:74: error: expected specifier-qualifier-list before ‘MYSQL

_mysql.c:88: error: expected specifier-qualifier-list before ‘MYSQL_RES’

_mysql.c: In function ‘_mysql_Exception’:

_mysql.c:128: warning: implicit declaration of function ‘mysql_errno’

_mysql.c:128: error: ‘_mysql_ConnectionObject’ has no member named ‘connection’

_mysql.c:131: error: ‘CR_MAX_ERROR’ undeclared (first use in this function)

_mysql.c:131: error: (Each undeclared identifier is reported only once

_mysql.c:131: error: for each function it appears in.)

_mysql.c:139: error: ‘CR_COMMANDS_OUT_OF_SYNC’ undeclared (first use in this function)

_mysql.c:140: error: ‘ER_DB_CREATE_EXISTS’ undeclared (first use in this function)

_mysql.c:141: error: ‘ER_SYNTAX_ERROR’ undeclared (first use in this function)

_mysql.c:142: error: ‘ER_PARSE_ERROR’ undeclared (first use in this function)

_mysql.c:143: error: ‘ER_NO_SUCH_TABLE’ undeclared (first use in this function)

_mysql.c:144: error: ‘ER_WRONG_DB_NAME’ undeclared (first use in this function)

_mysql.c:145: error: ‘ER_WRONG_TABLE_NAME’ undeclared (first use in this function)

_mysql.c:146: error: ‘ER_FIELD_SPECIFIED_TWICE’ undeclared (first use in this function)

_mysql.c:147: error: ‘ER_INVALID_GROUP_FUNC_USE’ undeclared (first use in this function)

_mysql.c:148: error: ‘ER_UNSUPPORTED_EXTENSION’ undeclared (first use in this function)

_mysql.c:149: error: ‘ER_TABLE_MUST_HAVE_COLUMNS’ undeclared (first use in this function)

_mysql.c:178: error: ‘ER_DUP_ENTRY’ undeclared (first use in this function)

_mysql.c:221: warning: implicit declaration of function ‘mysql_error’

_mysql.c:221: error: ‘_mysql_ConnectionObject’ has no member named ‘connection’

_mysql.c: In function ‘_mysql_server_init’:

_mysql.c:325: warning: label ‘finish’ defined but not use

_mysql.c:242: warning: unused variable ‘item’

_mysql.c:241: warning: unused variable ‘groupc'

_mysql.c:241: warning: unused variable ‘i’

...

error: command 'gcc' failed with exit status 1

----------------------------------------

Cleaning up...

Command /usr/local/bin/python3.4 -c "import setuptools, tokenize;__file__=

'/tmp/pip_build_username/mysqlclient/setup.py';

exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('

', '

'), __file__, 'exec'))"

install --record /tmp/pip-s1b9rgku-record/install-record.txt

--single-version-externally-managed --compile failed with error code 1

in /tmp/pip_build_username/mysqlclient

Storing debug log for failure in /home/username/.pip/pip.log

sudo /usr/local/bin/pip3.4 install mysqlclient

《新程序員》:云原生和全面數字化實踐50位技術專家共同創作,文字、視頻、音頻交互閱讀

總結

以上是生活随笔為你收集整理的python安装mysqlclient报错_Centos 6 – sudo在为Python 3.4安装mysqlclient时...的全部內容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網站內容還不錯,歡迎將生活随笔推薦給好友。