Search code examples
phpapacheredhatyum

Installing PHP on a server where HTTPD was installed by source


There is one server where Apache HTTPD was installed by source, so, there is no Yum/RPM register of installed Apache HTTPD.

When trying to install PHP 5.x packages using yum, it gives errors saying the dependent package "httpd" was not found.

What's the correct approach to install PHP and the remaining PHP RPM children packages (as example php-pecl-jsonc RPM), since yum is not allowing it to be installed?


Solution

  • The problem was solved installing the PHP RPM files ignoring the dependencies from HTTPD and then moving the mod_php files (mod_php.so) from the original source directory into the respective modules directory from the HTTPD installed by source.