日期:2014-05-17  浏览次数:20569 次

windows上使用pear安装php扩展
在windows上使用pear安装php扩展
相关网站:
http://www.php.net
http://pear.php.net
http://pear2.php.net
http://pecl.php.net
pear2需要使用sqlite3
执行命令:
1、php D:\php\php5.3.5\pyrus.phar install D:\php\php5.3.5\ext\libevent-0.0.4.tgz
Pyrus version 2.0.0a3 SHA-1: BE7EA9D171AE3873F1BBAF692EEE9165BB14BD5D
Using PEAR installation found at D:\php\php5.3.5\ext
Downloading pecl.php.net/libevent
PEAR2\Pyrus\Registry\Exception: Error: package pecl.php.net/libevent could not b
e installed in registry: Unable to execute statement: constraint failed
Exception: Unable to execute statement: constraint failed

2、php D:\php\php5.3.5\pyrus.phar -v install pecl/libevent
Pyrus version 2.0.0a3 SHA-1: BE7EA9D171AE3873F1BBAF692EEE9165BB14BD5D
Using PEAR installation found at D:\wamp\bin\php\php5.3.5\ext
PEAR2\Pyrus\Installer\Exception: Dependency validation failed for some packages
to install, installation aborted
PEAR2\Pyrus\Package\Dependency\Set\Exception: Unable to find a compatible relea
se for pecl.php.net/libevent

3、php D:\php\php5.3.5\pyrus.phar -v install pecl/libevent-0.0.4
Pyrus version 2.0.0a3 SHA-1: BE7EA9D171AE3873F1BBAF692EEE9165BB14BD5D
Using PEAR installation found at D:\php\php5.3.5\ext
Downloading pecl.php.net/libevent

Connected...
Mime-type: application/octet-stream

[================>
[================================================================>
[===============================================================================
PHP Warning:  rmdir(D:\php\php5.3.5\ext\.journal-src): Permission denie
d in phar://D:/wamp/bin/php/php5.3.5/pyrus.phar/PEAR2_Pyrus-2.0.0a3/php/PEAR2/Py
rus/Filesystem.php on line 103
PHP Stack trace:
PHP   1. {main}() D:\php\php5.3.5\pyrus.phar:0
PHP   2. PEAR2\Pyrus\ScriptFrontend\Commands->run() D:\php\php5.3.5\pyr
us.phar:52
PHP   3. PEAR2\Pyrus\ScriptFrontend\Commands->install() phar://D:/wamp/bin/php/p
hp5.3.5/pyrus.phar/PEAR2_Pyrus-2.0.0a3/php/PEAR2/Pyrus/ScriptFrontend/Commands.p
hp:284
PHP   4. PEAR2\Pyrus\Installer::commit() phar://D:/wamp/bin/php/php5.3.5/pyrus.p
har/PEAR2_Pyrus-2.0.0a3/php/PEAR2/Pyrus/ScriptFrontend/Commands.php:491
PHP   5. PEAR2\Pyrus\Installer->install() phar://D:/wamp/bin/php/php5.3.5/pyrus.
phar/PEAR2_Pyrus-2.0.0a3/php/PEAR2/Pyrus/Installer.php:313
PHP   6. PEAR2\Pyrus\AtomicFileTransaction::getTransactionObject() phar://D:/wam
p/bin/php/php5.3.5/pyrus.phar/PEAR2_Pyrus-2.0.0a3/php/PEAR2/Pyrus/Installer.php:
465
PHP   7. PEAR2\Pyrus\AtomicFileTransaction\Manager->getTransaction() phar://D:/w
amp/bin/php/php5.3.5/pyrus.phar/PEAR2_Pyrus-2.0.0a3/php/PEAR2/Pyrus/AtomicFileTr
ansaction.php:71
PHP   8. PEAR2\Pyrus\AtomicFileTransaction\Transaction->__construct() phar://D:/
wamp/bin/php/php5.3.5/pyrus.phar/PEAR2_Pyrus-2.0.0a3/php/PEAR2/Pyrus/AtomicFileT
ransaction/Manager.php:67
PHP   9. PEAR2\Pyrus\AtomicFileTransaction\Transaction->begin() phar://D:/wamp/b
in/php/php5.3.5/pyrus.phar/PEAR2_Pyrus-2.0.0a3/php/PEAR2/Pyrus/AtomicFileTransac
tion/Transaction.php:37
PHP  10. PEAR2\Pyrus\AtomicFileTransaction\Transaction\TwoStage->begin() phar://
D:/wamp/bin/php/php5.3.5/pyrus.phar/PEAR2_Pyrus-2.0.0a3/php/PEAR2/Pyrus/AtomicFi
leTransaction/Transaction.php:60
PHP  11. PEAR2\Pyrus\AtomicFileTransaction\Transaction\Base->begin() phar://D:/w
amp/bin/php/php5.3.5/pyrus.phar/PEAR2_Pyrus-2.0.0a3/php/PEAR2/Pyrus/AtomicFileTr
ansaction/Transaction/TwoStage.php:49
PHP  12. PEAR2\Pyrus\Filesystem::rmrf() phar://D:/wamp/bin/php/php5.3.5/pyrus.ph
ar/PEAR2_Pyrus-2.0.0a3/php/PEAR2/Pyrus/AtomicFileTransaction/Trans