2

I'm trying for a few days now to install php-mcrypt on Centos 6 64bit, but I get this error

[root@cimpan tmp]# yum install php-mcrypt
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mi.mirror.garr.it
 * epel: mirror.switch.ch
 * extras: mi.mirror.garr.it
 * rpmforge: mirror.crazynetwork.it
 * updates: mi.mirror.garr.it
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package php-mcrypt.x86_64 0:5.3.3-3.el6 will be installed
--> Processing Dependency: php(zend-abi) = 20090626 for package: php-mcrypt-5.3.3-    3.el6.x86_64
--> Processing Dependency: php(api) = 20090626 for package: php-mcrypt-5.3.3-3.el6.x86_64
--> Finished Dependency Resolution
Error: Package: php-mcrypt-5.3.3-3.el6.x86_64 (epel)
           Requires: php(zend-abi) = 20090626
           Installed: php-common-5.4.28-1.el6.remi.x86_64 (@remi)
               php(zend-abi) = 20100525-x86-64
           Available: php-common-5.3.3-26.el6.x86_64 (base)
               php(zend-abi) = 20090626
           Available: php-common-5.3.3-27.el6_5.x86_64 (updates)
               php(zend-abi) = 20090626
Error: Package: php-mcrypt-5.3.3-3.el6.x86_64 (epel)
           Requires: php(api) = 20090626
           Installed: php-common-5.4.28-1.el6.remi.x86_64 (@remi)
               php(api) = 20100412-x86-64
           Available: php-common-5.3.3-26.el6.x86_64 (base)
               php(api) = 20090626
           Available: php-common-5.3.3-27.el6_5.x86_64 (updates)
               php(api) = 20090626
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest
[root@cimpan tmp]# rpm -qa | grep epel
epel-release-6-8.noarch

Epel release version seems to be ok too. Tried yum clean all but no luck either. It may be broken because I've updated PHP to 5.4.28?

(P.S.: pretty new to server management)

flaviu
  • 23
  • 1
  • 5

1 Answers1

1

Yes, it's unable to install that because it depends on PHP versions from the stock repos, while you've installed PHP from a third-party repo.

Since you've stepped away from using the supported versions of the PHP packages, you're dependent on either the third-party repo you're using for PHP to provide the package (which they apparently do not), or to install it by hand.

The operating system's package repositories for PHP libraries simply won't do you any good when you've ditched the version of PHP they actually support; this should be part of what you consider in deciding what version of PHP to use.

Shane Madden
  • 112,982
  • 12
  • 174
  • 248
  • thanks for the answer! so, if I want to have PHP 5.4 what is the best method to have it and to be able to install php-mcrypt properly? – flaviu May 26 '14 at 07:37
  • Use the remi repo (which **does** have `php-mcrypt` for php-5.4.28) properly, by configuring it into your `yum` repo set, instead of just grabbing the RPMs and installing them. You may wish to consider repository prioritisation, too. – MadHatter May 26 '14 at 07:44
  • I've removed php then installed webstatic's version of php then installed other extensions from the same repository. I have to study more about how packages and repositories work. Thank you again! – flaviu May 26 '14 at 07:54