You are on page 1of 2

Are you installing a system-wide PEAR or a local copy?

(system|local) [system] : local


Please confirm local copy by typing 'yes' : yes
Below is a suggested file layout for your new PEAR installation. To
change individual locations, type the number in front of the
directory. Type 'all' to change all of them or simply press Enter to
accept these locations.
1. Installation base ($prefix) : C:\Program Files\PHP\v5.3
2. Temporary directory for processing : C:\Program Files\PHP\v5.3\tmp
3. Temporary directory for downloads : C:\Program Files\PHP\v5.3\tmp
4. Binaries directory : C:\Program Files\PHP\v5.3
5. PHP code directory ($php_dir) : C:\Program Files\PHP\v5.3\pea
r
6. Documentation directory : C:\Program Files\PHP\v5.3\doc
s
7. Data directory : C:\Program Files\PHP\v5.3\dat
a
8. User-modifiable configuration files directory : C:\Program Files\PHP\v5.3\cfg
9. Public Web Files directory : C:\Program Files\PHP\v5.3\www
10. Tests directory : C:\Program Files\PHP\v5.3\te
sts
11. Name of configuration file : C:\Program Files\PHP\v5.3\pe
ar.ini
12. Path to CLI php.exe : .
1-12, 'all' or Enter to continue:
Continue following the prompts to complete the installation process. During the
installation you may see a warning similar to the one shown below:
******************************************************************************
WARNING! The include_path defined in the currently used php.ini does not
contain the PEAR PHP directory you just specified:
<C:\Program Files\PHP\v5.3\pear>
If the specified directory is also not in the include_path used by
your scripts, you will have problems getting any PEAR packages working.
Would you like to alter php.ini <C:\Program Files\PHP\v5.3\php.ini>? [Y/n] : y
Make sure to say yes [y] to the question about altering php.ini so that include_
path directive is updated to the correct PEAR PHP directorty
After that you may also get a warning about out-of-date version of PEAR package
manager:
** WARNING! Old version found at C:\Program Files\PHP\v5.3, please remove it or
be sure to use the new c:\program files\php\v5.3\pear.bat command
If you see that then after the go-pear.bat has finished its work, run the follow
ing command to upgrade the PEAR package manager:
C:\Program Files\PHP\v5.3>pear upgrade pear
downloading PEAR-1.9.1.tgz ...
Starting to download PEAR-1.9.1.tgz (293,587 bytes)
.................done: 293,587 bytes
downloading Archive_Tar-1.3.7.tgz ...
Starting to download Archive_Tar-1.3.7.tgz (17,610 bytes)
...done: 17,610 bytes
downloading Structures_Graph-1.0.4.tgz ...
Starting to download Structures_Graph-1.0.4.tgz (30,318 bytes)
...done: 30,318 bytes
upgrade ok: channel://pear.php.net/Archive_Tar-1.3.7
upgrade ok: channel://pear.php.net/Structures_Graph-1.0.4
upgrade ok: channel://pear.php.net/PEAR-1.9.1
PEAR: Optional feature webinstaller available (PEAR's web-based installer)
PEAR: Optional feature gtkinstaller available (PEAR's PHP-GTK-based installer)
PEAR: Optional feature gtk2installer available (PEAR's PHP-GTK2-based installer)
PEAR: To install optional features use "pear install pear/PEAR#featurename"
At this point PEAR package manager is installed and you can start using it to do
wnload and install PEAR packages. For example to install phploc package, follow
these steps:
Step 1: Register the appropriate PEAR channels:
C:\Program Files\PHP\v5.3>pear channel-discover pear.phpunit.de
Adding Channel "pear.phpunit.de" succeeded
Discovery of channel "pear.phpunit.de" succeeded
C:\Program Files\PHP\v5.3>pear channel-discover components.ez.no
Adding Channel "components.ez.no" succeeded
Discovery of channel "components.ez.no" succeeded
Step 2: Install the phploc package:
C:\Program Files\PHP\v5.3>pear install phpunit/phploc
phpunit/phploc can optionally use PHP extension "bytekit"
downloading phploc-1.5.1.tgz ...
Starting to download phploc-1.5.1.tgz (7,893 bytes)
.....done: 7,893 bytes
downloading File_Iterator-1.2.3.tgz ...
Starting to download File_Iterator-1.2.3.tgz (3,406 bytes)
...done: 3,406 bytes
downloading ConsoleTools-1.6.1.tgz ...
Starting to download ConsoleTools-1.6.1.tgz (869,994 bytes)
...done: 869,994 bytes
downloading Base-1.8.tgz ...
Starting to download Base-1.8.tgz (236,357 bytes)
...done: 236,357 bytes
install ok: channel://pear.phpunit.de/File_Iterator-1.2.3
install ok: channel://components.ez.no/Base-1.8
install ok: channel://components.ez.no/ConsoleTools-1.6.1
install ok: channel://pear.phpunit.de/phploc-1.5.1
Finally run the phploc to ensure that it works correctly:
C:\Program Files\PHP\v5.3>phploc
phploc 1.5.1 by Sebastian Bergmann.
Usage: phploc [switches] <directory|file> ...
--count-tests Count PHPUnit test case classes and test methods.
--log-xml <file> Write result in XML format to file.
--exclude <directory> Exclude <directory> from code analysis.
--suffixes <suffix,...> A comma-separated list of file suffixes to check.
--help Prints this usage information.
--version Prints the version and exits.
--verbose Print progress bar.

You might also like