Everyone great God, I in the source installation php5.6.23 when the following error occurred:
configure: error: Don't know how to define struct flock on this system, set --enable-opcache=no
The following methods (can not be resolved):
1
vim /etc/ld.so.conf.d/local.conf # 编辑库文件/usr/local/lib # 添加该行(64位系统改为lib64):wq # 保存退出ldconfig -v # 使之生效
2
yum groupinstall "Development tools"
3
echo /usr/local/mysql/lib >> /etc/ld.so.conf.d/mysql-x86_64.conf ldconfig -v
4
这个报错需要的大概是libmysqlclient.so。我的机器由于是测试用,之前mysql是xampp安装的,所以so文件是在/opt/lampp/lib下。于是编辑/etc/ld.so.conf加入这个路径,ldconfig。再重新./configure,顺利通过。。
5
删除--enable-opcache
The above method I have tried, but still can't oh, System is CENTOS7, which big God can help me ah ┭┮﹏┭┮
Reply content:
Everyone great God, I in the source installation php5.6.23 when the following error occurred:
configure: error: Don't know how to define struct flock on this system, set --enable-opcache=no
The following methods (can not be resolved):
1
vim /etc/ld.so.conf.d/local.conf # 编辑库文件/usr/local/lib # 添加该行(64位系统改为lib64):wq # 保存退出ldconfig -v # 使之生效
2
yum groupinstall "Development tools"
3
echo /usr/local/mysql/lib >> /etc/ld.so.conf.d/mysql-x86_64.conf ldconfig -v
4
这个报错需要的大概是libmysqlclient.so。我的机器由于是测试用,之前mysql是xampp安装的,所以so文件是在/opt/lampp/lib下。于是编辑/etc/ld.so.conf加入这个路径,ldconfig。再重新./configure,顺利通过。。
5
删除--enable-opcache
The above method I have tried, but still can't oh, System is CENTOS7, which big God can help me ah ┭┮﹏┭┮
Finally solved! It's so epic, I can't Hold back tears in my eyes at this time.
Here's how:
1. Add the following to/etc/ld.so.conf:
/usr/local/lib #不知道为什么我的ld.so.conf文件里面空空如也
2. When compiling PHP, add the following parameters:
--with-libdir=lib64
The following error was encountered when installing PHP:
configure: error: Sorry, I was not able to diagnose which libmcrypt version
The workaround is to:
Recompile the libmcrypt, but do not specify the path at compile time, but direct./configure
StackOverflow on the same issue as you, system:php 5.6.4 CentOS 7.1.503 (Core)
I hope it helps, please call me Lei Feng.
Http://stackoverflow.com/questions/30856418/compiling-php-5-6-with-ldap-error-solved
changed --with-ldap to --with-ldap=shared
Yum Install php5.6