Get the App
SLTechnology News&Howtos  ›  Servers  › 

CentOS yum php mcrypt extension installation method

Shulou Source: shulou.com Published: 2022-06-01 17:12:53 11月15日 Update

This article mainly explains the "CentOS yum php mcrypt extension installation method", the content of the article is simple and clear, easy to learn and understand, the following please follow the editor's ideas slowly in depth, together to study and learn "CentOS yum php mcrypt extension installation mode" bar!

When you install the mcrypt extension using yum install php-mcrypt, you will be prompted that there is no package installed.

Setting up Install Process

No package php-mcrypt available.

Error: Nothing to do

Mcrypt is an encryption extension library, which can be loaded with 22 encryption and decryption algorithms included in it.

Php5.3.2 is installed by default in CentOS6

There is no mcrypt extension in the default redhat repos php

According to Red Hat's official news (https://bugzilla.redhat.com/show_bug.cgi?id=621268) RHEL does not intend to add mcrypt support for PHP

Joe Orton 2010-08-05 04:47:17 EDT

Thanks for the report.

We are not planning to ship mcrypt support for PHP.

Solution:

After downloading the new php 5.3 source code package from the php official website, extract it to the local directory

After entering the ext directory under the decompressed directory, you will find that there is mcrypt.

Enter the mcrypt directory

# cd / ext/mcrypt

# phpize

Note: if you report-bash:phpize not Found, then yum install php-devel can make phpize compile dynamically and install the extension.

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

# make & & make install

Appear:

Libraries have been installed in:

/ var/php-5.3.10/ext/mcrypt/modules

If you ever happen to want to link against installed libraries

In a given directory, LIBDIR, you must either use libtool, and

Specify the full pathname of the library, or use the `- LLIBDIR'

Flag during linking and do at least one of the following:

-add LIBDIR to the `LD_LIBRARY_PATH' environment variable

During execution

-add LIBDIR to the `LD_RUN_PATH' environment variable

During linking

-use the `- Wl,-rpath-Wl,LIBDIR' linker flag

-have your system administrator add LIBDIR to `/ etc/ld.so.conf'

See any operating system documentation about shared libraries for

More information, such as the ld (1) and ld.so (8) manual pages.

Build complete.

Don't forget to run 'make test'.

Installing shared extensions: / usr/lib64/php/modules/

View:

# php-m

...

Libxml

Mbstring

Mcrypt

Mysql

...

[Zend Modules]

Installed successfully!

If you look at phpinfo again, you can see the details of the mcrypt extension.

Thank you for your reading, the above is the content of "CentOS yum php mcrypt extension installation". After the study of this article, I believe you have a deeper understanding of the installation of CentOS yum php mcrypt extension, and the specific use needs to be verified in practice. Here is, the editor will push for you more related knowledge points of the article, welcome to follow!

Tags: Way directory learning content encryption success again encryption and decryption dynamic can make official that is ideas situations articles methods more results messages source code Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Redmi NVidia Linux OPPO Reno Shulou Technology