s_p
s_p

Reputation: 4693

yum install mcrypt on AWS linux (centos)

I cant seem to install mcrypt on my new linux box with PHP 5.4
I have tried sudo yum install php-mcrypt, sudo yum install php-mcrypt.x86_64

result:

Loaded plugins: priorities, update-motd, upgrade-helper
Resolving Dependencies
--> Running transaction check
---> Package php-mcrypt.x86_64 0:5.3.28-1.5.amzn1 will be installed
--> Processing Dependency: php-common(x86-64) = 5.3.28-1.5.amzn1 for package: php-mcrypt-5.3.28-1.5.amzn1.x86_64
--> Processing Dependency: libmcrypt.so.4()(64bit) for package: php-mcrypt-5.3.28-1.5.amzn1.x86_64
--> Processing Dependency: libltdl.so.7()(64bit) for package: php-mcrypt-5.3.28-1.5.amzn1.x86_64
--> Running transaction check
---> Package libmcrypt.x86_64 0:2.5.8-9.1.2.amzn1 will be installed
---> Package libtool-ltdl.x86_64 0:2.4.2-18.4.8.2.21.amzn1 will be installed
---> Package php-common.x86_64 0:5.3.28-1.5.amzn1 will be installed
--> Processing Conflict: php54-common-5.4.30-1.56.amzn1.x86_64 conflicts php-common < 5.4.30-1.56.amzn1
--> Finished Dependency Resolution
Error: php54-common conflicts with php-common-5.3.28-1.5.amzn1.x86_64
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

inside php.ini i've added mcrypt.so, but this didnt do anything
so then i took that off and created /etc/php.d/mcrypt.ini and added extension=mcrypt.so

Any help please
thank you

Upvotes: 6

Views: 11263

Answers (4)

Giulio Gazzetto
Giulio Gazzetto

Reputation: 41

sudo yum install php56-mcrypt

sudo service httpd restart

worked wery well for me

Upvotes: 0

Hung Mac
Hung Mac

Reputation: 323

you can use:

sudo yum install php56-mcrypt
sudo service httpd restart

Upvotes: 19

alex t
alex t

Reputation: 861

You have to remove all php5.3 associated packages, including httpd, because php5.4>= works with httpd24. After unistalling all these packages, check that all your packages are compatible with php 5.4.

This code might allow you removing httpd in order to reinstall httpd24:
sudo yum erase httpd httpd-tools apr apr-util

Check this link that works for php 5.5 and might help you installing php5.4 installing php.5.5 with mcrypt on AWS Linux

Upvotes: 1

ceejayoz
ceejayoz

Reputation: 180023

Chances are the package is named php54-mcrypt instead of php-mcrypt if you have existing packages named like php54-common.

Upvotes: 11

Related Questions