Get the App
SLTechnology News&Howtos  ›  Development  › 

How php7 installs mysqli extensions

Shulou Source: shulou.com Published: 2022-06-03 17:38:32 11月13日 Update

Php7 how to install mysqli extension, many novices are not very clear about this, in order to help you solve this problem, the following editor will explain in detail for you, people with this need can come to learn, I hope you can gain something.

I. installation steps

1. Find the mysqli under the php7.2 ext directory.

2. Enter / usr/local/php7.2/bin/phpize.

3. Execute the code under the mysqli folder.

. / configure-- with-php-config=/usr/local/php/bin/php-config--with-mysqli=/usr/bin/mysql_config

4 、 make .

5 、 make install .

Problem 1: if you can't find mysql_config, you may not have mysql-devel installed.

Resolution steps

1. The source where MySQL needs to be installed

2. The relevant repo of MySQL will appear in the / etc/yum.repos.d/ directory.

3 、 yum install mysql-devel

Problem 2: when installing mysqli, error: ext/mysqlnd/mysql_float_to_double.h: No such file or directory appears

Resolution steps

1. Vim / home/tmp/php-7.2.11/ext/mysqli/mysqli_api.c (find your installation directory here)

2. Modify the path of line 36 of the file

/ ext/mysqlnd/mysql_float_to_double.h

Modify to

/ home/tmp/php-7.2.11/ext/mysqlnd/mysql_float_to_double.h

Is it helpful for you to read the above content? If you want to know more about the relevant knowledge or read more related articles, please follow the industry information channel, thank you for your support.

Tags: Steps directories files questions help clarity code content this folders articles novice time more knowledge industry information channels paths puzzles Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Xiaomi NVidia vpn Shulou Information Apple