Linux:使用php-java-bridge让PHP5支持java

使用php-java-bridgePHP5支持java

一、下载:

http://ncu.dl.sourceforge.net/project/php-java-bridge/RHEL_FC%20SecurityEnhancedLinux/php-java-bridge_5.5.4.1/php-java-bridge_5.5.4.1.tar.gz

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

最新的版本是:php-java-bridge_6.1.2.1.tar.gz

但不能使用这个版本,因为这个版本中缺少一个函数:java_require

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

二、首先说明一下安装不成功的情况:

解压:

tar zxvfphp-java-bridge_5.5.4.1.tar.gz

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

进入目录:

cd php-java-bridge-5.5.4.1/

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

执行phpize

/usr/local/php/bin/phpize

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

编译:

./configure --with-java=$JAVA_HOME--with-php-config=/usr/local/php/bin/php-config

编译的过程和结果都是没问题的,但接下来的make操作就要注意了:

make

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

报错:

phpdoc -j -c PHPDocConfig.ini>/dev/null

/bin/sh: phpdoc: command notfound

make[1]: *** [JavaRaw.inc]错误127

make[1]: Leaving directory`/root/downloads/jdk/php-java-bridge-5.5.4.1/server'

make: ***[/root/downloads/jdk/php-java-bridge-5.5.4.1/modules/stamp]错误2

错误信息中提示没有phpdoc命令。

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

在网上查阅了大量资料,知道phpdoc命令是安装phpDocumentor后生成的,而phpDocumentor的安装又是有php的pear模块完成的。

三、安装pear,为安装phpDocumentor做准备

根据网络提供的大量资料显示,所以我们首先安装pear:

同样查阅了大量的网络资料来完成。

安装pear需要使用php命令来执行一个go-pear.php的文件来完成:

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

go-pear.php文件的获取:

访问:http://pear.php.net/go-pear

将整个网页内容复制下来并存储为go-pear.php即可。

我们这里可以使用vim命令建立go-pear.php文件,将内容复制进去,保存,增加执行权限即可。

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

用php命令执行go-pear.php

/usr/local/php/bin/phpgo-pear.php

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

出现如下提示:

Welcome to go-pear!

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

Go-pear will install the 'pear' command andall the files needed by

it.<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>This command is yourtool for PEAR installation and maintenance.</wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

Go-pear also lets you download and installthe following optional PEAR

packages: PEAR_Frontend_Web-beta,PEAR_Frontend_Gtk2, MDB2.

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

If you wish to abort, press Control-C now, or press Enter tocontinue:

回车,出现如下内容:

HTTP proxy (http://user:[email protected]:port), orEnter for none::

再回车,出现如下内容,提示你安装位置:

Below is a suggested file layout for your new PEARinstallation.<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>To</wbr>

change individual locations, type the number in front of the

directory.<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>Type 'all' to change all of them orsimply press Enter to</wbr>

accept these locations.

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">1. Installation prefix ($prefix) :/root/downloads/jdk</wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">2. Temporary filesdirectory<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">: $prefix/temp</wbr></wbr></wbr></wbr></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">3. Binariesdirectory<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">: $prefix/bin</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">4. PHP code directory ($php_dir) :$prefix/PEAR</wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">5. Documentation basedirectory<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>: $php_dir/docs</wbr></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">6. Data basedirectory<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">: $php_dir/data</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">7. Tests basedirectory<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">: $php_dir/tests</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

1-7, 'all' or Enter to continue:

我们可以在命令行后输入1-7和all或者直接回车继续,

我们这里选择输入all,回车。

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

上一步选择all以后,就要对每一项的安装目录进行定义,这个根据变量提示来确定,这里之定义了四项,定义一项回车一次:

1-7, 'all' or Enter to continue: all

Installation prefix ($prefix)[/root/downloads/jdk]:

Temporary files directory[$prefix/temp]:

Binaries directory[$prefix/bin]:/usr/bin

PHP code directory ($php_dir)[$prefix/PEAR]:/usr/local/php/bin

Documentation base directory[$php_dir/docs]:/usr/local/php/docs

Data base directory[$php_dir/data]:/usr/local/php/data

Tests base directory[$php_dir/tests]:

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

回车后,返回刚才定义的信息:

Below is a suggested file layout for your new PEARinstallation.<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>To</wbr>

change individual locations, type the number in front of the

directory.<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>Type 'all' to change all of them orsimply press Enter to</wbr>

accept these locations.

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">1. Installation prefix ($prefix) :/root/downloads/jdk</wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">2. Temporary filesdirectory<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">: $prefix/temp</wbr></wbr></wbr></wbr></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">3. Binariesdirectory<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">: /usr/bin</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">4. PHP code directory ($php_dir) :/usr/local/php/bin</wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">5. Documentation basedirectory<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>: /usr/local/php/docs</wbr></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">6. Data basedirectory<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">: /usr/local/php/data</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">7. Tests basedirectory<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">: $php_dir/tests</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

1-7, 'all' or Enter to continue:

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

到这里,再回车:

The following PEAR packages are bundled with PHP:PEAR_Frontend_Web-beta,

PEAR_Frontend_Gtk2, MDB2.

Would you like to install these as well? [Y/n] :

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

输入Y,继续:

Loading zlib: ok

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

Bootstrapping Installer...................

Bootstrapping PEAR.php............(remote) ok

Bootstrapping Archive/Tar.php............(remote) ok

Bootstrapping Console/Getopt.php............(remote) ok

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

Extracting installer..................

Downloading package: PEAR.............ok

Downloading package: Structures_Graph....ok

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

Preparing installer..................

Updating channel "doc.php.net"

Update of Channel "doc.php.net" succeeded

Updating channel "pear.php.net"

Update of Channel "pear.php.net" succeeded

Updating channel "pecl.php.net"

Update of Channel "pecl.php.net" succeeded

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

Installing selected packages..................

Downloading and installing package: PEAR.............warning:pear/PEARrequires<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">package "pear/Archive_Tar" (recommended version 1.3.7)</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

warning: pear/PEAR requires package "pear/Structures_Graph"(recommendedversion<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">1.0.3)</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

warning: pear/PEAR requires package "pear/Console_Getopt"(recommended version1<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">.2.3)</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

warning: pear/PEAR requires package "pear/XML_Util" (recommendedversion 1.2.1)

downloading PEAR-1.9.1.tgz ...

Starting to download PEAR-1.9.1.tgz (293,587 bytes)

......................................done: 293,587 bytes

install ok: channel://pear.php.net/PEAR-1.9.1

PEAR: Optional feature webinstaller available (PEAR's web-basedinstaller)

PEAR: Optional feature gtkinstaller available (PEAR'sPHP-GTK-based installer)

PEAR: Optional feature gtk2installer available (PEAR'sPHP-GTK2-based installer)

PEAR: To install optional features use "pear installpear/PEAR#featurename"

Installing bootstrap package: Structures_Graph.......install ok:channel://pear.<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">php.net/Structures_Graph-1.0.3</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

Downloading and installing package:Archive_Tar-stable.......downloading Archive_Tar-1.3.7.tgz ...

Starting to download Archive_Tar-1.3.7.tgz (17,610 bytes)

...done: 17,610 bytes

install ok: channel://pear.php.net/Archive_Tar-1.3.7

Downloading and installing package:Console_Getopt-stable.......downloading Console_Getopt-1.2.3.tgz...

Starting to download Console_Getopt-1.2.3.tgz (4,011 bytes)

...done: 4,011 bytes

install ok: channel://pear.php.net/Console_Getopt-1.2.3

Downloading and installing package:PEAR_Frontend_Web-beta.......downloadingPEAR_Frontend_Web-0.7.4.tgz ...

Starting to download PEAR_Frontend_Web-0.7.4.tgz (53,321bytes)

...done: 53,321 bytes

downloading HTML_Template_IT-1.3.0.tgz ...

Starting to download HTML_Template_IT-1.3.0.tgz (23,309bytes)

...done: 23,309 bytes

install ok: channel://pear.php.net/HTML_Template_IT-1.3.0

install ok: channel://pear.php.net/PEAR_Frontend_Web-0.7.4

Downloading and installing package: PEAR_Frontend_Gtk2.......Didnot download optional dependencies: pear/XML_Parser, pear/XML_Util,use --alldeps to download automatically

Did not download optional dependencies: pear/System_Command, use--alldeps to download automatically

pear/PEAR_Frontend_Gtk2 requires PHP extension "php-gtk"(version >= 2.0.0dev)

pear/Config can optionally use package "pear/XML_Parser"

pear/Config can optionally use package "pear/XML_Util"

pear/Gtk2_EntryDialog requires PHP extension "php-gtk" (version>= 2.0.0dev)

pear/Gtk2_FileDrop requires PHP extension "php-gtk" (version>= 2.0.0dev)

pear/MIME_Type can optionally use package"pear/System_Command"

downloading Config-1.10.11.tgz ...

Starting to download Config-1.10.11.tgz (27,939 bytes)

...done: 27,939 bytes

downloading MIME_Type-1.2.0.tgz ...

Starting to download MIME_Type-1.2.0.tgz (11,581 bytes)

...done: 11,581 bytes

install ok: channel://pear.php.net/Config-1.10.11

install ok: channel://pear.php.net/MIME_Type-1.2.0

Downloading and installing package: MDB2.............downloadingMDB2-2.4.1.tgz ...

Starting to download MDB2-2.4.1.tgz (119,790 bytes)

...done: 119,790 bytes

install ok: channel://pear.php.net/MDB2-2.4.1

MDB2: Optional feature fbsql available (Frontbase SQL driver forMDB2)

MDB2: Optional feature ibase available (Interbase/Firebirddriver for MDB2)

MDB2: Optional feature mysql available (MySQL driver forMDB2)

MDB2: Optional feature mysqli available (MySQLi driver forMDB2)

MDB2: Optional feature mssql available (MS SQL Server driver forMDB2)

MDB2: Optional feature oci8 available (Oracle driver forMDB2)

MDB2: Optional feature pgsql available (PostgreSQL driver forMDB2)

MDB2: Optional feature querysim available (Querysim driver forMDB2)

MDB2: Optional feature sqlite available (SQLite2 driver forMDB2)

MDB2: To install optional features use "pear installpear/MDB2#featurename"

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

******************************************************************************

WARNING!<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>The include_path defined in thecurrently used php.ini does not</wbr>

contain the PEAR PHP directory you just specified:

</root/downloads/jdk/PEAR>

If the specified directory is also not in the include_path usedby

your scripts, you will have problems getting any PEAR packagesworking.

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

到这里提示如下,提示是否更改php.ini文件

Would you like to alter php.ini</usr/local/apache2/conf/php.ini>?[Y/n] :

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

选择Y,继续:

php.ini</usr/local/apache2/conf/php.ini>include_path updated.

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

Current includepath<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">: .:/usr/local/php/lib/php</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

Configureddirectory<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">: /root/downloads/jdk/PEAR</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

Currently used php.ini (guess) :/usr/local/apache2/conf/php.ini

Press Enter to continue:

回车,继续,出现提示的地方就按照提示输入信息继续,直到完成!<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

四、用pearlist可以查看安装了的pear包:

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

Package<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">Version State</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

Archive_Tar<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">1.3.7<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>stable</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

Config<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">1.10.11 stable</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

Console_Getopt<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">1.2.3<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>stable</wbr></wbr></wbr></wbr></wbr>

HTML_Template_IT<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">1.3.0<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>stable</wbr></wbr></wbr>

MDB2<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">2.4.1<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>stable</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

MIME_Type<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">1.2.0<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>stable</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

PEAR<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">1.9.1<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>stable</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr>

PEAR_Frontend_Web0.7.4<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>beta</wbr></wbr>

Structures_Graph<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">1.0.3<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"><span></span>stable</wbr></wbr></wbr>

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

四、安装完了pear后,使用pear来安装PhpDocumentor

首先查找到pear安装位置:

find / -name pear

结果:

/usr/bin/pear

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

执行安装:

/usr/bin/pear installPhpDocumentor

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

Did not download optional dependencies:pear/XML_Beautifier, use --alldeps to downloadautomatically

pear/PhpDocumentor can optionally usepackage "pear/XML_Beautifier" (version >=1.1)

downloading PhpDocumentor-1.4.3.tgz...

Starting to downloadPhpDocumentor-1.4.3.tgz (2,423,486 bytes)

..........

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

当出现如下信息的时候就说明phpdoc安装完成了:

install ok:channel://pear.php.net/PhpDocumentor-1.4.3

注意:可能PhpDocumentor-1.4.3的服务器在美国加州,尽管软件只有不到3M,安装过程相当慢,有可能还会断掉,如果出现这样的情况需要多试几次才行。

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

五、接下来就是重新编译安装php-java-bridge-5.5.4.1了:

进入php-java-bridge-5.5.4.1的目录:

执行phpize

/usr/local/php/bin/phpize

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

编译:

./configure --with-java=$JAVA_HOME--with-php-config=/usr/local/php/bin/php-config

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

安装:

make

make install

注意:如果在make过结束出现错误,那么请执行make clean清理一下,重新编译后,再make就可以了。

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

配置:

编辑php.ini文件:

vim/usr/local/apache2/conf/php.ini

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

添加如下内容:

[Java]

java.java_home="/usr/local/java/jdk1.6/"

java.java="/usr/local/java/jdk1.6/jre/bin/java"

java.log_file="/var/log/php-java-bridge.log"

java.classpath="/usr/local/php/lib/php/extensions/no-debug-non-zts-20060613/JavaBridge.jar"

java.libpath="/usr/local/php/lib/php/extensions/no-debug-non-zts-20060613/"

extension_dir ="/usr/local/php/lib/php/extensions/no-debug-non-zts-20060613/"

extension = java.so

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

重启apache

service httpd restart

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px"></wbr>

访问phpinfo页面:

<wbr style="padding-bottom:0px; margin:0px; padding-left:0px; padding-right:0px; font-family:宋体; font-size:9pt; padding-top:0px">如果有java模块,就说明安装成功了。</wbr>

你可能感兴趣的:(bridge)