Closed
Description
Hello, when i run pip install mysqlclient
i get:
building '_mysql' extension creating build/temp.linux-x86_64-3.6 x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -g -fdebug-prefix-map=/build/python3.6-z9grDo/python3.6-3.6.4=. -specs=/usr/share/dpkg/no-pie-compile.specs -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -Dversion_info=(1,3,12,'final',0) -D__version__=1.3.12 -I/usr/include/mysql -I/home/ignacio/envs/leb/include -I/usr/include/python3.6m -c _mysql.c -o build/temp.linux-x86_64-3.6/_mysql.o In file included from /usr/include/mysql/mysql_com.h:995:0, from /usr/include/mysql/mysql.h:71, from _mysql.c:29: /usr/include/mysql/mysql/udf_registration_types.h:79:1: warning: function declaration isn’t a prototype [-Wstrict-prototypes] typedef void(*Udf_func_any)(); ^~~~~~~ _mysql.c: In function ‘_mysql_ConnectionObject_ping’: _mysql.c:1894:3: error: unknown type name ‘my_bool’; did you mean ‘_Bool’? my_bool recon = reconnect; ^~~~~~~ _Bool error: command 'x86_64-linux-gnu-gcc' failed with exit status 1 ----------------------------------------
I try to build by source and the same. I have debian, python3.6 and mysql-server 8.0.3-rc-1debian9. But, if i change this line by compiler recomendation, the compiler ends ok:
diff --git a/_mysql.c b/_mysql.c
index 49c8d9b..c6d2d5d 100644
--- a/_mysql.c
+++ b/_mysql.c
@@ -1891,7 +1891,8 @@ _mysql_ConnectionObject_ping(
if (!PyArg_ParseTuple(args, "|I", &reconnect)) return NULL;
check_connection(self);
if (reconnect != -1) {
- my_bool recon = reconnect;
+ //my_bool recon = reconnect;
+ _Bool recon = reconnect;
mysql_options(&self->connection, MYSQL_OPT_RECONNECT, &recon);
}
Py_BEGIN_ALLOW_THREADS
Metadata
Metadata
Assignees
Labels
No labels