|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #25326 When Upgrading PEAR modules, Mail::Mail needed Net_SMTP.
Submitted: 2003-08-30 16:16 UTC Modified: 2005-05-24 01:00 UTC
Avg. Score:3.5 ± 0.5
Reproduced:0 of 2 (0.0%)
From: ler at lerctr dot org Assigned: cox (profile)
Status: No Feedback Package: PEAR related
PHP Version: 4.3.3 OS: UnixWare 7.1.3UP2
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: ler at lerctr dot org
New email:
PHP Version: OS:


 [2003-08-30 16:16 UTC] ler at lerctr dot org
When I ran the make install for 4.3.3 of PHP, it tried to upgrade all 
my Installed PEAR modules (Good!), but it does them in 
Alphabetical order, which is a problem for Mail::Mail, as Mail::Mail 
needs the upgraded Net_SMTP, which hadn't been installed yet.  
On the 2nd make install (compile issues), it worked fine.  
Can the install script be made smarter to deal with this issue? 


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2003-08-31 00:42 UTC]
Perhaps the install script could utilize the new --onlyreqdeps option added in CVS, so that installed packages will always have their required dependencies installed/upgraded?  That should fix this issue nicely.

 [2003-08-31 01:23 UTC]
This patch, when used with the CVS version of PEAR (1.3b1) should fix the problem, but as simple as it looks, some serious testing is required.  The patch will download and install all required dependencies, or upgrade them if they are already installed.  There are some possible side effects from this that result from the increased dependence on downloading.  I can't think of anything too serious offhand, but I don't have much experience installing PEAR using the compile --with-pear method.

In any case, try out this patch, with the CVS version of PEAR (checkout php-src/pear, and pear upgrade package-PEAR.xml).  Let us know if it fixes the problem.


Index: pear/install-pear.php
RCS file: /repository/php-src/pear/install-pear.php,v
retrieving revision 1.15
diff -u -r1.15 install-pear.php
--- pear/install-pear.php	14 Aug 2003 20:14:33 -0000	1.15
+++ pear/install-pear.php	31 Aug 2003 06:19:05 -0000
@@ -86,6 +86,7 @@
         $old_ver = $reg->packageInfo($package, 'version');
         if (version_compare($new_ver, $old_ver, 'gt')) {
             $options['upgrade'] = true;
+            $options['onlyreqdeps'] = true;
             $err = $installer->install($instfile, $options);
             if (PEAR::isError($err)) {
                 $ui->outputData(sprintf("[PEAR] %s: %s", $package, $err->getMessage()));

 [2003-08-31 01:39 UTC] ler at lerctr dot org
Given my stuff is already updated, I can't test real easily.  
I wish I could. 
 [2003-08-31 06:29 UTC]
Greg we can not access internet at php compile time, in any case. The solution is to ship all the packages needed by the packages bundled in the php distribution.

In this case just need to add the correct release tarball of Net_SMTP to php-src/pear/packages.

Pierre? ;)
 [2003-08-31 08:14 UTC] ler at lerctr dot org
Actually, the correct version of Net_SMTP is in the tarball, but the 
install/upgrade part is stupid in that it just does the upgrades in 
Alphabetical order, which means that Net_SMTP is NOT installed 
when Mail::Mail is installed.  
a 2nd make install installs Mail::Mail, because Net_SMTP is 
installed the first time, but Mail::Mail is not because of the 
Does that help any?
 [2003-08-31 09:20 UTC]
I guess that Greg fixed that already, so we only need to pass all the packages to the $installer object as an array.

I'll take this task if no other one appears.
 [2005-05-24 01:00 UTC] pear-dev at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Mon Jun 05 18:03:38 2023 UTC