]> granicus.if.org Git - php/commitdiff
fixed #25117, updated package-PEAR.xml to the current release level
authorGreg Beaver <cellog@php.net>
Sun, 17 Aug 2003 18:01:39 +0000 (18:01 +0000)
committerGreg Beaver <cellog@php.net>
Sun, 17 Aug 2003 18:01:39 +0000 (18:01 +0000)
pear/PEAR/Installer.php
pear/package-PEAR.xml

index 577973dff63559e552a6fd022b2931562941dac3..e38d48204de226df0e48731cb633121ccc996128 100644 (file)
@@ -222,6 +222,10 @@ class PEAR_Installer extends PEAR_Common
             $this->log(3, "+ mkdir $dest_dir");
         }
         if (empty($atts['replacements'])) {
+            if (!file_exists($orig_file)) {
+                return $this->raiseError("file does not exist",
+                                         PEAR_INSTALLER_FAILED);
+            }
             if (!@copy($orig_file, $dest_file)) {
                 return $this->raiseError("failed to write $dest_file",
                                          PEAR_INSTALLER_FAILED);
@@ -231,6 +235,10 @@ class PEAR_Installer extends PEAR_Common
                 $md5sum = md5_file($dest_file);
             }
         } else {
+            if (!file_exists($orig_file)) {
+                return $this->raiseError("file does not exist",
+                                         PEAR_INSTALLER_FAILED);
+            }
             $fp = fopen($orig_file, "r");
             $contents = fread($fp, filesize($orig_file));
             fclose($fp);
@@ -273,7 +281,7 @@ class PEAR_Installer extends PEAR_Common
             fclose($wp);
         }
         if (isset($md5sum)) {
-            if ($md5sum == $atts['md5sum']) {
+            if (strtolower($md5sum) == strtolower($atts['md5sum'])) {
                 $this->log(3, "md5sum ok: $final_dest_file");
             } else {
                 $this->log(0, "warning : bad md5sum for file $final_dest_file");
@@ -695,6 +703,9 @@ class PEAR_Installer extends PEAR_Common
                 if (PEAR::isError($res)) {
                     if (empty($options['ignore-errors'])) {
                         $this->rollbackFileTransaction();
+                        if ($res->getMessage() == "file does not exist") {
+                            $this->raiseError("file $file in package.xml does not exist");
+                        }
                         return $this->raiseError($res);
                     } else {
                         $this->log(0, "Warning: " . $res->getMessage());
index 5ced146ba12d52f7fabf23a67c4a258c713d67ab..b8899375f65754c8903dcef2db28ea1d77d9548f 100644 (file)
     </maintainer>
   </maintainers>
   <release>
-    <version>1.2b5</version>
-    <state>beta</state>
-    <date>2003-08-05</date>
+    <version>1.2.2?</version>
+    <date>2003-08-??</date>
+    <state>stable</state>
     <notes>
-* Changed license from PHP 2.02 to 3.0
-* Added support for optional dependencies
-* Made upgrade and uninstall package case insensitive
-* pear makerpm, now works and generates a better system independant spec file
-* pear install|build pecl-package, now exposes the compilation progress
-* Installer now checks dependencies on package uninstall
-* Added proxy support for remote commands using the xmlrcp C ext (Adam Ashley)
-* Added the command "download-all" (Alex Merz)
-* Made package dependency checking back to work
-* Added support for spaces in path names (Greg)
+* Fixed #25117 - MD5 checksum should be case-insensitive
 * Fixed static calls to PEAR error-handling methods in classes (Greg)
 * Added ability to use a static method callback for error-handling, and removed
 use of inadvisable @ in setErrorHandling (Greg)
-* Various bugfixes
-* Added new pear "bundle" command, which downloads and uncompress a PECL package.
-The main purpouse of this command is for easily adding extensions to the PHP sources
-before compiling it.
     </notes>
     <provides type="class" name="OS_Guess" />
     <provides type="class" name="System" />
@@ -123,6 +110,35 @@ before compiling it.
     </deps>
   </release>
   <changelog>
+    <release>
+      <version>1.2.1</version>
+      <date>2003-08-15</date>
+      <state>stable</state>
+      <notes>- Set back the default library path (BC issues)</notes>
+    </release>
+    <release>
+      <version>1.2</version>
+      <date>2003-08-14</date>
+      <state>stable</state>
+      <notes>Changes from 1.1:
+
+* Changed license from PHP 2.02 to 3.0
+* Added support for optional dependencies
+* Made upgrade and uninstall package case insensitive
+* pear makerpm, now works and generates a better system independant spec file
+* pear install|build pecl-package, now exposes the compilation progress
+* Installer now checks dependencies on package uninstall
+* Added proxy support for remote commands using the xmlrcp C ext (Adam Ashley)
+* Added the command &quot;download-all&quot; (Alex Merz)
+* Made package dependency checking back to work
+* Added support for spaces in path names (Greg)
+* Various bugfixes
+* Added new pear &quot;bundle&quot; command, which downloads and uncompress a PECL package.
+The main purpouse of this command is for easily adding extensions to the PHP sources
+before compiling it.
+      
+</notes>
+    </release>
     <release>
         <version>1.1</version>
         <state>stable</state>