Problems with installing python-mysqldb in CentOS

Source: Internet
Author: User
The python-mysqldb Installation Process in CentOS took three hours. The strange problem was that pythonsetup. pybuild had a lot of garbled characters. Seeing friends online

The installation of python-mysqldb in CentOS took three hours. The strange problem was that python setup. py build had a lot of garbled characters. Seeing friends online

The installation of python-mysqldb in CentOS took three hours. The strange problem was that python setup. py build had a lot of garbled characters. If you see a friend who has encountered the same problem on the internet, post it and share it, hoping to save your time.

_ Mysql. c: At top level:
_ Mysql. c: 647: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: In function ???? _ Mysql_ConnectionObject_clear ???? :
_ Mysql. c: 679: error :???? _ Mysql_ConnectionObject ???? Has no member named ???? Converter ????
_ Mysql. c: 680: error :???? _ Mysql_ConnectionObject ???? Has no member named ???? Converter ????
_ Mysql. c: 680: error :???? NULL ???? Undeclared (first use in this function)
_ Mysql. c: 680: warning: statement with no effect
_ Mysql. c: At top level:
_ Mysql. c: 687: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 715: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 731: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 749: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 768: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 794: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 816: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 848: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 874: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 901: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 916: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 933: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 949: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 967: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1002: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1033: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1035: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1065: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1095: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1129: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1161: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1197: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1221: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1246: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1271: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1310: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1349: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1354: error: expected declaration specifiers or ????...???? Before ???? PyObject ????
_ Mysql. c: 1357: error: expected declaration specifiers or ????...???? Before ???? _ PYFUNC ????
_ Mysql. c: In function ???? _ Mysql _ fetch_row ???? :
_ Mysql. c: 1363: error :???? PyObject ???? Undeclared (first use in this function)
_ Mysql. c: 1363: error :???? V ???? Undeclared (first use in this function)
_ Mysql. c: 1363: error: invalid operands to binary *
_ Mysql. c: 1363: warning: statement with no effect
_ Mysql. c: 1364: error :???? _ Mysql_ResultObject ???? Has no member named ???? Use ????
_ Mysql. c: 1365: error :???? _ Mysql_ResultObject ???? Has no member named ???? Result ????
_ Mysql. c: 1365: warning: passing argument 1 ???? Mysql_fetch_row ???? From incompatible pointer type
_ Mysql. c: 1367: error :???? Py_BEGIN_ALLOW_THREADS ???? Undeclared (first use in this function)
_ Mysql. c: 1367: warning: statement with no effect
_ Mysql. c: 1368: error :???? _ Mysql_ResultObject ???? Has no member named ???? Result ????
_ Mysql. c: 1368: warning: passing argument 1 ???? Mysql_fetch_row ???? From incompatible pointer type
_ Mysql. c: 1369: error :???? Py_END_ALLOW_THREADS ???? Undeclared (first use in this function)
_ Mysql. c: 1369: warning: statement with no effect
_ Mysql. c: 1371: error :???? _ Mysql_ResultObject ???? Has no member named ???? Conn ????
_ Mysql. c: 1371: error :???? _ Mysql_ConnectionObject ???? Has no member named ???? Connection ????
_ Mysql. c: 1371: warning: passing argument 1 ???? Mysql_errno ???? From incompatible pointer type
_ Mysql. c: 1372: error :???? _ Mysql_ResultObject ???? Has no member named ???? Conn ????
_ Mysql. c: 1376: warning: implicit declaration of function ???? _ PyTuple_Resize ????
_ Mysql. c: 1376: error :???? R ???? Undeclared (first use in this function)
_ Mysql. c: 1379: warning: implicit declaration of function ???? Convert_row ????
_ Mysql. c: 1379: warning: statement with no effect
_ Mysql. c: At top level:
_ Mysql. c: 1397: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1476: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1504: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1526: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1566: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1595: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1610: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1625: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1640: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1656: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1691: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1709: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1732: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1749: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1765: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1794: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1817: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1847: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1869: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1896: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1917: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1958: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 1978: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: In function ???? _ Mysql_ConnectionObject_dealloc ???? :
_ Mysql. c: 2012: error :???? PyObject ???? Undeclared (first use in this function)
_ Mysql. c: 2012: error :???? O ???? Undeclared (first use in this function)
_ Mysql. c: 2012: error: invalid operands to binary *
_ Mysql. c: 2012: warning: statement with no effect
_ Mysql. c: 2015: error :???? _ Mysql_ConnectionObject ???? Has no member named ???? Open ????
_ Mysql. c: 2016: warning: implicit declaration of function ???? _ Mysql_ConnectionObject_close ????
_ Mysql. c: 2016: error :???? NULL ???? Undeclared (first use in this function)
_ Mysql. c: 2016: warning: statement with no effect
_ Mysql. c: 2019: warning: implicit declaration of function ???? PyMem_Free ????
_ Mysql. c: At top level:
_ Mysql. c: 2022: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 2039: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 2054: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 2076: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: In function ???? _ Mysql_ResultObject_dealloc ???? :
_ Mysql. c: 2098: error :???? _ Mysql_ResultObject ???? Has no member named ???? Result ????
_ Mysql. c: 2098: warning: passing argument 1 ???? Mysql_free_result ???? From incompatible pointer type
_ Mysql. c: At top level:
_ Mysql. c: 2103: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 2113: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? _ Mysql_ConnectionObject_methods ????
_ Mysql. c: 2328: error: array type has incomplete element type
_ Mysql. c: 2329: error :???? T_INT ???? Undeclared here (not in a function)
_ Mysql. c: 2329: warning: implicit declaration of function ???? Offsetof ????
_ Mysql. c: 2329: error: expected expression before ???? _ Mysql_ConnectionObject ????
_ Mysql. c: 2329: error :???? RO ???? Undeclared here (not in a function)
_ Mysql. c: 2336: error :???? T_OBJECT ???? Undeclared here (not in a function)
_ Mysql. c: 2336: error: expected expression before ???? _ Mysql_ConnectionObject ????
_ Mysql. c: 2343: error :???? T_UINT ???? Undeclared here (not in a function)
_ Mysql. c: 2343: error: expected expression before ???? _ Mysql_ConnectionObject ????
_ Mysql. c: 2350: error: expected expression before ???? _ Mysql_ConnectionObject ????
_ Mysql. c: 2357: error: expected expression before ???? _ Mysql_ConnectionObject ????
_ Mysql. c: 2364: error :???? NULL ???? Undeclared here (not in a function)
_ Mysql. c: 2367: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? _ Mysql_ResultObject_methods ????
_ Mysql. c: 2419: error: array type has incomplete element type
_ Mysql. c: 2420: error: expected expression before ???? _ Mysql_ResultObject ????
_ Mysql. c: 2430: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 2458: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 2488: error: expected declaration specifiers or ????...???? Before ???? PyObject ????
_ Mysql. c: In function ???? _ Mysql_ConnectionObject_setattr ???? :
_ Mysql. c: 2490: error :???? V ???? Undeclared (first use in this function)
_ Mysql. c: 2491: warning: implicit declaration of function ???? PyErr_SetString ????
_ Mysql. c: 2491: error :???? PyExc_AttributeError ???? Undeclared (first use in this function)
_ Mysql. c: 2496: warning: implicit declaration of function ???? PyMember_Set ????
_ Mysql. c: At top level:
_ Mysql. c: 2513: error: expected declaration specifiers or ????...???? Before ???? PyObject ????
_ Mysql. c: In function ???? _ Mysql_ResultObject_setattr ???? :
_ Mysql. c: 2515: error :???? V ???? Undeclared (first use in this function)
_ Mysql. c: 2516: error :???? PyExc_AttributeError ???? Undeclared (first use in this function)
_ Mysql. c: At top level:
_ Mysql. c: 2534: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? _ Mysql_ConnectionObject_Type ????
_ Mysql. c: 2618: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? _ Mysql_ResultObject_Type ????
_ Mysql. c: 2704: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? _ Mysql_methods ????
_ Mysql. c: 2776: error: expected ???? = ????, ????,????, ????;????, ???? Asm ???? Or ???? _ Attribute __???? Before ???? *???? Token
_ Mysql. c: 2808: warning: return type defaults ???? Int ????
_ Mysql. c: In function ???? DL_EXPORT ???? :
_ Mysql. c: 2808: error: expected declaration specifiers before ???? Init_mysql ????
_ Mysql. c: 2886: error: expected ???? {???? At end of input
Error: command 'gcc 'failed with exit status 1

The headers are all big.

Solution:

Yum install python-devel mysql-devel zlib-devel openssl-devel

Then build and install

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.