Package home | Report new bug | New search | Development Roadmap Status: Open | Feedback | All | Closed Since Version 0.3.0

Bug #6373 pear makerpm generates RPMs that cannot be uninstalled
Submitted: 2005-12-30 12:45 UTC
From: bugs at timj dot co dot uk Assigned: timj
Status: Closed Package: PEAR_Command_Packaging
PHP Version: 5.1.1 OS: Irrelevant
Roadmaps: (Not assigned)    
Subscription  


 [2005-12-30 12:45 UTC] bugs at timj dot co dot uk
Description: ------------ The current version of the template.spec supplied with PEAR produces RPMs that do not uninstall cleanly. This should have been fixed in bug #5959 but it appears there was a problem (human error?) with the application of the patch in the above bug, meaning that there is still a stray line in the postun script: rm @rpm_xml_dir@/@package@.xml Test script: --------------- # pear makerpm HTTP-1.4.0.tgz # rpm -ivh PEAR::HTTP-1.4.0.noarch.rpm [above all works fine] # rpm -e PEAR::HTTP Here's the trivial fix: --- template.spec.1.7 2005-12-30 12:29:18.000000000 +0000 +++ template.spec.new 2005-12-30 12:36:53.000000000 +0000 @@ -34,7 +34,6 @@ # if refcount = 0 then package has been removed (not upgraded) if [ "$1" -eq "0" ]; then pear uninstall --nodeps -r @possible_channel@@package@ - rm @rpm_xml_dir@/@package@.xml fi Expected result: ---------------- uninstall ok: channel://pear.php.net/HTTP-1.4.0 [RPM is uninstalled OK] Actual result: -------------- uninstall ok: channel://pear.php.net/HTTP-1.4.0 rm: cannot remove `/var/lib/pear/HTTP.xml': No such file or directory error: %postun(PEAR::HTTP-1.4.0-1.noarch) scriptlet failed, exit status 1 [RPM is not uninstalled although the PEAR registry no longer thinks HTTP is there]

Comments

 [2006-02-10 11:59 UTC] timj at php dot net
This bug has been fixed in CVS. If this was a documentation problem, the fix will appear on pear.php.net by the end of next Sunday (CET). If this was a problem with the pear.php.net website, the change should be live shortly. Otherwise, the fix will appear in the package's next release. Thank you for the report and for helping us make PEAR better.