php编译安装报错

Posted 天宇星空

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了php编译安装报错相关的知识,希望对你有一定的参考价值。

Cannot find OpenSSL‘s <evp.h>

解决方法:

下载openssl-1.1.0h.tar  包

[[email protected] ~]# cd openssl-1.1.0h  &&  ./config  && make  && makeinstall 

 

configure: error: Cannot find OpenSSL‘s libraries

报错:configure: error: Cannot find OpenSSL‘s libraries

解决方法:

[[email protected] php-5.6.36]# find / -name libssl.so

[[email protected] php-5.6.36]# ln -s /usr/local/lib64/libssl.so /usr/lib/

 

 

 

 

 

关于timezone报错: It is not safe to rely on the system‘s timezone settings

报错:It is not safe to rely on the system‘s timezone settings

[[email protected] local]# php -i|grep pdo
PHP Warning: Unknown: It is not safe to rely on the system‘s timezone settings. You are *required* to use the date.timezone setting or the date_default_timezone_set() function. In case you used any of those methods and you are still getting this warning, you most likely misspelled the timezone identifier. We selected the timezone ‘UTC‘ for now, but please set date.timezone to select your timezone. in Unknown on line 0

 

解决方法:

[[email protected] local]# vim /etc/php.ini 

找到date.timezone,修改为 date.timezone = PRC,后保存。

 [Date]

; Defines the default timezone used by the date functions

; http://php.net/date.timezone

date.timezone = PRC           #注释取消掉,date.timezone = PRC。PRC,People’s Republic of China,中华人民共和国,也就是日期使用中国的时区。

 

 

 

[[email protected] pdo_mysql]# /usr/bin/phpize 
Can‘t find PHP headers in /usr/include/php
The php-devel package is required for use of this command.

 

解决方法:

yum install php-devel  -y 

 





以上是关于php编译安装报错的主要内容,如果未能解决你的问题,请参考以下文章

php编译安装报错

编译安装php-5.3.27报错:make: *** [sapi/fpm/php-fpm] 错误 1

PHP编译安装报错: mcrypt.h not found. Please reinstall libmcrypt.

编译安装php服务报错问题:configure: error: Cannot find libmysqlclient under /usr.

PHP编译安装报错:configure: error: mcrypt.h not found. Please reinstall libmcrypt

php 编译安装插件提示PHP Warning: PHP Startup: Unable to load dynamic library 报错