Sankar N
Sankar N

Reputation: 19

unable install pear dependencies

I am new to php and drupal i want install below commands

sudo pear install mail sudo pear install Net_SMTP sudo pear Auth_SASL sudo pear install mail_mime

I tried many ways to install but i saw result below like this sudo pear install mail_mime [sudo] password for ******: downloading Mail_Mime-1.10.0.tgz ... Starting to download Mail_Mime-1.10.0.tgz (35,375 bytes) .........done: 35,375 bytes could not extract the package.xml file from "/build/php5-0LI9sl/php5-5.5.9+dfsg/pear-build-download/Mail_Mime-1.10.0.tgz" Download of "pear/mail_mime" succeeded, but it is not a valid package archive Error: cannot download "pear/Mail_Mime" Download failed install failed.

can any one help me from this

Upvotes: 1

Views: 2378

Answers (2)

Kenneth Saey
Kenneth Saey

Reputation: 157

The accepted answer suggest to first run

 $ pear upgrade -Z pear/Archive_Tar

This however also gave me the error: Download of "pear/Archive_Tar" succeeded, but it is not a valid package archive. This did however download the Archive_Tar-1.4.2.tar file into my php\PEAR\download directory.

Next, I replaced the php\PEAR\Archive\Tar.php file with the one in php\PEAR\download\Archive_Tar-1.4.2.tar\Archive_Tar-1.4.2\Archive\Tar.php (You can rename the one in php\PEAR\Archive\ first, just to be safe).

This fixed the "not a valid package archive"-errors for me.

As suggested in the accepted answer, it would now be a good time to update your pear installation.

Upvotes: 2

kguest
kguest

Reputation: 3844

It seems that the Archive_Tar PEAR component needs to be replaced/upgraded.

Do this first:

$ sudo pear upgrade -Z pear/Archive_Tar

It would also be a good time to update your pear installation:

$ sudo pear upgrade pear

And then try the other steps again:

$ sudo pear install mail Net_SMTP Auth_SASL mail_mime

Upvotes: 3

Related Questions