PEAR install issue, downloads but doesn't install - php

I saw this thread which is exactly what I've done as well, Downgraded PHP to version 5.2 on Ubuntu 10.4
When running as root I just get the download, no install message, any thoughts?
pear install Mail_Mime-1.8.0.tgz
downloading Mail_Mime-1.8.0.tgz ...
Starting to download Mail_Mime-1.8.0.tgz (31,292 bytes)
.........done: 31,292 bytes
I've looked in the phpinfo() and see nothing except the pear path
include_path .:/usr/share/php:/usr/share/pear .:/usr/share/php:/usr/share/pear
running pear list I get this
pear list
Installed packages, channel pear.php.net:
=========================================
Package Version State
Archive_Tar 1.3.3 stable
Console_Getopt 1.2.3 stable
PEAR 1.9.0 stable
Structures_Graph 1.0.2 stable
XML_Util 1.2.1 stable

please manual download Mail_Mime files and extract to /usr/share/pear/

Found a work around, not the best solution but it works. Using the Ubuntu Download Center, search for pear and install the needed packages. Most are listing with a prepending php-
php-mail

Related

Pear packages installing but not found afterwards

I am working on a mac and trying to install http_request2 and mail_mime via the pear package manager.
When I use the pear install command I see this:
$ pear install http_request2
downloading HTTP_Request2-2.2.1.tgz ...
Starting to download HTTP_Request2-2.2.1.tgz (107,339 bytes)
.........................done: 107,339 bytes
downloading Net_URL2-2.0.5.tgz ...
Starting to download Net_URL2-2.0.5.tgz (17,456 bytes)
...done: 17,456 bytes
install ok: channel://pear.php.net/Net_URL2-2.0.5
install ok: channel://pear.php.net/HTTP_Request2-2.2.1
Which leads me to believe that this is installed correctly. However, if I then run pear list -a I get the following output:
$ pear list -a
Installed packages, channel __uri:
==================================
(no packages installed)
Installed packages, channel doc.php.net:
========================================
(no packages installed)
Installed packages, channel pear.php.net:
=========================================
Package Version State
Archive_Tar 1.3.11 stable
Console_Getopt 1.3.1 stable
PEAR 1.9.4 stable
Structures_Graph 1.0.4 stable
XML_Util 1.2.1 stable
Installed packages, channel pecl.php.net:
=========================================
(no packages installed)
http_request2 is not included among the installed packages, despite just being told that it was installed.
I can also run the pear install http_request2 command again and it will not give me the
ignoring installed package pear/http_request2
like it's supposed to, instead it just proceeds with the install.
I ran
pear config-get php_dir
and found http_request2 in that directory.
I tried changing the include_path variable in my php.ini file as suggested in this post: Pear Packages not working but it didn't change anything.
I would prefer not to reinstall pear if possible because I'm not experienced with this and don't want to accidentally end up with two pears, as suggested can happen here: https://stackoverflow.com/a/6596669/2718779. Any suggestions?
You probably stumble across the issue I solved in https://stackoverflow.com/a/19177767/282601 - two versions of pear installed.

phpuml command not found

I m trying to set up phpuml to generate xmi files which I intent to import using umbrello.
I have managed to get PHP_UML installed using XSL alpha package which is a dependency for PHP_UML.
Here is the output of the list command
vihaan#cd:~$ pear list
Installed packages, channel pear.php.net:
=========================================
Package Version State
Archive_Tar 1.3.11 stable
Console_CommandLine 1.2.0 stable
Console_Getopt 1.3.1 stable
PEAR 1.9.4 stable
PHP_UML 1.6.1 stable
Structures_Graph 1.0.4 stable
XML_Util 1.2.1 stable
XML_XSLT_Wrapper 0.2.2 alpha
It seems like PHP_UML is installed but on trying to execute the phpuml command I get
vihaan#cd:~$ phpuml
phpuml: command not found
I cant figure out whats wrong?
To see where the phpuml script for installed to, use the command
$ pear list php_uml | grep phpuml

Need to install propel_generator version 1.3.5

I need to install propel_generator version 1.3.5 on my machine. I tried to install it using PEAR via:
pear install propel/propel_generator-1.3.5
but it failed with the following message:
Failed to download propel/propel_generator, version "1.3.5", latest release is version 1.6.7, stability "stable", use "channel://pear.propelorm.org/propel_generator-1.6.7" to install
install failed
Following this answer I checked http://pear.propelorm.org/Chiara_PEAR_Server_REST/r/propel_generator/allreleases.xml and the earliest version of propel_generator that is available for install via PEAR from there is version 1.3.0 and the next to follow is 1.4.0 with no 1.3.5 in between.
Is there a way to install propel_generator version 1.3.5 using PEAR or any other way?
I can't even find the source code for the 1.3.5 generator.
PS: The generator is being used by a legacy system so upgrading isn't really an option.
There was never an official release of 1.3.5, see the list of tags at http://svn.propelorm.org/tags/ - you won't get that version from anywhere.

How to uninstall PEAR from one installation of PHP and then install it with another existing PHP installation

I have two installations of php on my server. One version of php is 5.2.0 configured with pear, and the other is 5.2.9 configured --without-pear. My server is running Red Hat Enterprise Linux AS release 4 (Nahant Update 9).
I would like to uninstall pear (and also PHPUnit) from php 5.2.0, and then reinstall it as part of the 5.2.9 version of php. The pear installation docs don't really cover this type of a situation, although they do tell Linux users to "consult the documentation for the respective distribution" in the event that they want to install pear with a version of php that was configured --without-pear. I am having trouble finding such documentation, and even if I did, I am not sure how to remove the existing pear installation first.
Here is a partial answer to my own question: After trial and error, I discovered that you can uninstall pear by running this command:
$ sudo pear uninstall pear
I would like to see this added to the official pear docs, since they don't mention uninstalling pear at all.
Use the Command Help
pear help
You'll see the uninstall command listed in the output. :)
Output
Commands:
build Build an Extension From C Source
bundle Unpacks a Pecl Package
channel-add Add a Channel
...
uninstall Un-install Package
...

Install propel_generator 1.2?

I'm trying to install propel_generator version 1.2 (later versions are incompatible with the project I'm working on). I've tried
pear install propel/propel_generator-1.2
But I get the following error:
Failed to download propel/propel_generator, version "1.2",
latest release is version 1.5.2, stability "stable",
use "channel://pear.propelorm.org/propel_generator-1.5.2" to install
install failed
Anybody know how I can install this using Pear?
The short answer is: You can't.
The explanation is:
I took a look at http://pear.propelorm.org/Chiara_PEAR_Server_REST/r/propel_generator/allreleases.xml and the earliest version of propel_generator that is available for install via PEAR from there is version 1.3.0
You could download the v1.2.0 code from http://svn.propelorm.org/tags/1.2.0/ and create a pear package.xml yourself, using their BuildPropelPEARPackageTask.php script, if you really need to.

Categories