Bug #75612 [Opn->Fbk]: php-mysqli build fails with MariaDB-10.2

From: Date: Wed, 03 Feb 2021 12:44:43 +0000
Subject: Bug #75612 [Opn->Fbk]: php-mysqli build fails with MariaDB-10.2
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-231910@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=75612&edit=1

 ID:                 75612
 Updated by:         cmb@php.net
 Reported by:        dkasyanov at cloudlinux dot com
 Summary:            php-mysqli build fails with MariaDB-10.2
-Status:             Open
+Status:             Feedback
 Type:               Bug
 Package:            MySQLi related
 Operating System:   Centos 7
 PHP Version:        7.1.12
-Assigned To:        
+Assigned To:        cmb
 Block user comment: N
 Private report:     N

 New Comment:

Is this still an issue with any of the actively supported PHP
versions[1]?  If so, I suggest to submit a PR[2]?

[1] <https://www.php.net/supported-versions.php>
[2] <https://github.com/php/php-src/pulls>


Previous Comments:
------------------------------------------------------------------------
[2019-05-06 04:36:39] phpbugs dot ooglek at 0sg dot net

This is also failing on FreeBSD. I attempted to manually patch 7.3.5 with the changes in the
attached patch and compile from source without success.

I have MariaDB 10.2.22 installed.

Process:

1. Checkout git
2. git checkout php-7.3.5
3. ./buildconf --force
4. ./configure --prefix=/usr/local --with-layout=GNU --with-config-file-path=/usr/local/etc
--with-config-file-scan-dir=/usr/local/etc/php --mandir=/usr/local/man --infodir=/usr/local/info/
--localstatedir=/var --enable-bcmath --enable-exif --enable-fpm --enable-ftp --enable-intl
--enable-libxml --enable-mbstring --enable-mysqlnd --with-mysqli=/usr/local/bin/mysql_config
--enable-pcntl --enable-soap --enable-sockets --enable-zip --with-bz2 --with-curl
--with-fpm-user=www --with-fpm-group=www --with-freetype-dir=/usr/local --with-gd
--with-gettext=/usr/local --with-iconv --with-jpeg-dir=/usr/local --with-libxml-dir=/usr/local
--with-openssl --with-pdo-mysql=/usr/local --with-png-dir=/usr/local --with-sodium=/usr/local
--with-zlib-dir=/usr --with-zlib=/usr

I get stuff like this

--- ext/mysqli/mysqli_api.lo ---
In file included from /home/human/tmp/php-src/ext/mysqli/mysqli_api.c:32:
In file included from ext/mysqli/php_mysqli_structs.h:61:
/usr/local/include/mysql/my_global.h:3:2: warning: This file should not be included by clients,
include only <mysql.h> [-W#warnings]
#warning This file should not be included by clients, include only <mysql.h>
 ^
/home/human/tmp/php-src/ext/mysqli/mysqli_api.c:156:2: warning: format specifies type 'unsigned
long' but the argument has type 'my_ulonglong' (aka 'unsigne
d long long') [-Wformat]
        MYSQLI_RETURN_LONG_INT(rc);
        ^~~~~~~~~~~~~~~~~~~~~~~~~~
ext/mysqli/mysqli_priv.h:99:45: note: expanded from macro 'MYSQLI_RETURN_LONG_INT'

In file included from /home/human/tmp/php-src/ext/mysqli/mysqli_api.c:32:
In file included from ext/mysqli/php_mysqli_structs.h:77:
/usr/local/include/mysql/my_sys.h:3:2: warning: This file should not be included by clients, include
only <mysql.h> [-W#warnings]
#warning This file should not be included by clients, include only <mysql.h>
 ^

------------------------------------------------------------------------
[2018-11-28 10:00:12] m0r1arty dot nv at yandex dot ru

For temporary solution: after configure open Makefile in root php src directory,look
"-I/usr/include/mysql" and replace to "-I/usr/include/mysql/server".

------------------------------------------------------------------------
[2018-04-28 00:03:25] requinix@php.net

Related To: Bug #76282

------------------------------------------------------------------------
[2018-04-07 20:43:46] spam2 at rhsoft dot net

we use mysqlnd since 2010 everywhere and i don't get why it should be a problem for mysqli -
until you configure with shared both are directly in teh binary

[harry@srv-rhsoft:/lib64/php/modules]$ ls | grep mysql
-rwxr-xr-x 1 root root 131K 2018-04-07 19:33 mysqli.so
-rwxr-xr-x 1 root root 290K 2018-04-07 19:33 mysqlnd.so

------------------------------------------------------------------------
[2018-04-07 20:39:49] bero at lindev dot ch

One reason not to use mysqlnd is --enable-embedded-mysqli -- other than that, mysqlnd should do the
trick (but needs some testing on our side -- we know libmysql to work from years of using it).

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


The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at

    https://bugs.php.net/bug.php?id=75612


--
Edit this bug report at https://bugs.php.net/bug.php?id=75612&edit=1


Thread (9 messages)

« previous php.bugs (#231910) next »