centos6 安装php7.0.15,解决没有mysqli模块

本文档详细介绍了如何在CentOS6上安装PHP7.0.15,并着重解决了在安装过程中mysqli模块缺失的问题。通过正确配置编译参数,以及确保已安装mysql-devel依赖,最终成功启用mysqli模块。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

安装依赖

yum install -y gcc gcc-c++  make zlib zlib-devel pcre pcre-devel  libjpeg libjpeg-devel libpng libpng-devel freetype freetype-devel libxml2 libxml2-devel glibc glibc-devel glib2 glib2-devel bzip2 bzip2-devel ncurses ncurses-devel curl curl-devel e2fsprogs e2fsprogs-devel krb5 krb5-devel openssl openssl-devel openldap openldap-devel nss_ldap openldap-clients openldap-servers

下载tar包

wget https://www.php.net/distributions/php-7.0.15.tar.gz

解压

tar -zxf php-7.0.15

检查环境

./configure --prefix=/usr/local/php7 --with-openssl --with-pcre-regex --with-kerberos --with-libdir=lib --with-libxml-dir --with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config --with-pdo-mysql=shared,mysqlnd --with-pdo-sqlite --with-gd --with-iconv --with-zlib --with-xmlrpc --with-xsl --with-pear --with-gettext --with-curl --with-png-dir --with-jpeg-dir --with-freetype-dir --with-
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值