Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

The method of compiling php5 mcrypt Module with centos Source Code

2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/01 Report--

This article mainly introduces the relevant knowledge of "centos source code compiling php5 mcrypt module method". The editor shows you the operation process through an actual case. The operation method is simple, fast and practical. I hope this article "centos source code compiling php5 mcrypt module method" can help you solve the problem.

Steps:

1. Download the source code of php5.3.x version from php.net

2.centos installs the appropriate expansion pack:

The copy code is as follows:

Yum install libmcrypt libmcrypt-devel mcrypt mhash

The following development environment is to compile the entire php source code preparation environment, this compilation mcrypt extension does not need to be executed.

The copy code is as follows:

Yum install-y httpd-devel libtool-ltdl libtool-ltdl-devel openssl-devel curl-devel\

Libjpeg libjpeg-devel libpng libpng-devel freetype freetype-devel\

Libc-client libc-client-devel gd gd-devel libmcrypt libmcrypt-devel\

Sqlite sqlite-devel mysql-devel libicu libicu-devel pcre-devel

3. Make sure phpize is installed on the server:

Whereis phpize

Determine the location of the php-config:

Whereis php-config

Execute:

. / configure-with-php-config=/usr/bin/php-config

4.make error:

Mcrypt.c:283: error: 'php_fe_end' undeclared here (not in a function)

Solution:

The copy code is as follows:

Sed-I's | php_fe_end | {null,null,null} |'. / ext/**/*.c

Make

If it is a zend_mod_end error, execute:

The copy code is as follows:

Sed-I's | zend_mod_end | {null,null,null} |'. / ext/**/*.c

5. Execute make test and there is no problem with the test. Then execute:

The copy code is as follows:

Make install

6. Add file: / etc/php.d/mcrypt.ini

The copy code is as follows:

Enable mbstring extension module

Extension=mcrypt.so

7. Restart the web server and check that php mcrypt is installed successfully.

This is the end of the introduction on "the method of compiling php5 mcrypt module with centos source code". Thank you for reading. If you want to know more about the industry, you can follow the industry information channel. The editor will update different knowledge points for you every day.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report