PEAR is archived and read-only

This mirror preserves historical PEAR package releases and metadata so existing references remain available.

Home » PEAR » PEAR » Bug #7594

Bug in PEAR-DB installation

Details

Submitted2006-05-10 05:32 UTC
Fromcontact at manfred-muench dot com
StatusBogus
PackagePEAR
PHP Version5.1.4
OSLinux (Gentoo) on AMD64
Roadmaps(Not assigned)

Comments

[2006-05-10 05:32 UTC] contact at manfred-muench dot com

Description:
------------
When installing PEAR-DB (version 1.7.6-r1) I get the following error message (emerging in gentoo with debug option switched on):

###############################
000355 + pear -d php_bin=/usr/lib/php5/bin/php install --force --loose --nodeps --offline --packagingroot=/var/tmp/portage/PEAR-DB-1.7.6-r1/image/ /var/tmp/portage/PEAR-DB-1.7.6-r1/work/DB-1.7.6/package.xml
000356 + diefunc php-pear-r1_src_install 66 1 'Unable to install PEAR package'
000357 + local funcname=php-pear-r1_src_install lineno=66 exitcode=1
000358 + shift 3
000359 + echo
000360
000361 + echo '!!! ERROR: dev-php/PEAR-DB-1.7.6-r1 failed.'
000362 !!! ERROR: dev-php/PEAR-DB-1.7.6-r1 failed.
###############################

Running this pear command on the shell reveals:

###############################
fozzie ~ # pear -d php_bin=/usr/lib/php5/bin/php install --force --loose --nodeps --offline --packagingroot=/var/tmp/portage/PEAR-DB-1.7.6-r1/image/ /var/tmp/portage/PEAR-DB-1.7.6-r1/work/DB-1.7.6/package.xml
warning: pear/DB requires package "pear/PEAR" (version >= 1.0b1)
install ok: channel://pear.php.net/DB-1.7.6

Fatal error: Call to a member function setConfig() on a non-object in /usr/local/lib64/php/PEAR/Command/Install.php on line 546
###############################

PEAR/PEAR is installed (version 1.4.9-r1), so I don't understand the warning. However, debugging this install.php file a little, showed this:
in line 545 is a call to retrieve the $pkg variable from $reg with two parameters: $param->getPackage() and $param->getChannel. The first parameter is empty while the second parameter contains "pear.php.net" (as expected). That's why I render that $pkg is null so the call $pkg->... in line 546 fails.

My USE-flags for php:
bcmath cgi cli apache2 berkdb bzip2 calendar crypt curl curlwrappers cjk dba exif ftp gettext gd gdbm gmp hash iconv imap ipv6 kerberos ldap mbstring mcrypt mhash mssql mysql mysqli ncurses nls odbc pcre pcntl pspell readline sasl session simplexml snmp soap sockets spell ssl truetype xml xmlreader xmlwriter xmlrpc xpm xsl yaz zip zlib

Reference: http://forums.gentoo.org/viewtopic.php?p=3307725

Test script:
---------------
Just type:
emerge PEAR-PEAR PEAR-DB on an AMD64 system running Gentoo, php-5.1.4 compiled with the USE flags as in my bug description.

Expected result:
----------------
I expect that everything installs ok.

Actual result:
--------------
see Description.