Where do PEAR packages normally get installed?

/usr/share/php/

is correct for Debian.

/usr/share/php/PEAR

itself contains classes for PEAR itself.

The reason for using /usr/share/php is that the pear CLI tool is an installer that installs libraries (or applications) for PHP - choosing php is thus correct.


in case php is installed in /usr/local/php

pear is here:

/usr/local/php/lib/php


I am using Mac OSX Lion. I installed pear in /usr/lib/php/pear

So the data also be installed there.


Yes, that is the correct directory on Debian, and Ubuntu.

Regardless of which O/S you are using, you can find the correct install directory by running: pear config-get php_dir via a console. And you get full directory path.

For example, with XAMPP application on Microsoft Window you have to go to XAMPP installation directory path <<XAMPP Installation folder path>>/bin and use ./pear config-get php_dir which lead to execute the binary file using current location and do the same job.

Tags:

Php

Pear