This is the definitive source of PEAR's core files.

Installs: 405 691

Dependents: 24

Suggesters: 0

Stars: 86

Watchers: 15

Forks: 86

v1.10.10 2019-11-19 18:59 UTC


What is the PEAR Installer? What is PEAR?

PEAR is the PHP Extension and Application Repository, found at

The PEAR Installer is this software, which contains executable files and PHP code that is used to download and install PEAR code from

PEAR contains useful software libraries and applications such as MDB2 (database abstraction), HTML_QuickForm (HTML forms management), PhpDocumentor (auto-documentation generator), DB_DataObject (Data Access Abstraction), and many hundreds more. Browse all available packages at, the list is constantly growing and updating to reflect improvements in the PHP language.


Do not run PEAR without installing it - if you downloaded this tarball manually, you MUST install it. Read the instructions in INSTALL prior to use.


Documentation for PEAR can be found at Installation documentation can be found in the INSTALL file included in this tarball.


Run the tests without installation as follows:

$ ./scripts/ run-tests -r tests

You should have the Text_Diff package installed to get nicer error output.

To run the tests with another PHP version, modify php_bin and set the PHP_PEAR_PHP_BIN environment variable:

$ pear config-set php_bin /usr/local/bin/php7
$ PHP_PEAR_PHP_BIN=/usr/local/bin/php7 ./scripts/ run-tests -r tests

Happy PHPing, we hope PEAR will be a great tool for your development work!

Test dependencies

  • zlib


Create a PEAR package as well as phars for pear-less installation:

$ rm -f PEAR-*.tgz
$ pear package package2.xml
$ cd go-pear-tarballs
$ rm -f PEAR-*
$ cp ../PEAR-*.tgz .
$ gunzip PEAR-*.tgz
$ pear download -Z Archive_Tar Console_Getopt Structures_Graph XML_Util
$ mkdir src && cd src
$ for i in ../*.tar; do tar xvf $i; done
$ mv *\/* .
$ cd ../../
$ php make-gopear-phar.php
$ php make-installpear-nozlib-phar.php

(Or simply run

go-pear.phar is contains the PEAR installer installer that asks questions where to install it. It is available from

install-pear-nozlib.phar installs PEAR automatically without asking anything. It is shipped with PHP itself.