Bug 106672

Summary: Typo in /usr/lib/rpm/perl.req
Product: [Retired] Red Hat Linux Reporter: Jon Warbrick <jw35>
Component: rpmAssignee: Jeff Johnson <jbj>
Status: CLOSED ERRATA QA Contact: Mike McLean <mikem>
Severity: medium Docs Contact:
Priority: medium    
Version: 9   
Target Milestone: ---   
Target Release: ---   
Hardware: i386   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2003-12-26 19:03:10 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jon Warbrick 2003-10-09 13:47:32 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030703

Description of problem:
The RE 
    
     s/\(*$//;

is used in an attempt to strip anything in brackets from a posible module name.
It should be 

     s/\(.*$//;

(note the extra dot). This bug results in a bogus dependancy, for example for
the FakeApache.pm component of HTML::Mason

Version-Release number of selected component (if applicable):
rpm-4.2-0.69

How reproducible:
Always

Steps to Reproduce:
1.Obtain and unpack (e.g.)
http://search.cpan.org/CPAN/authors/id/D/DR/DROLSKY/HTML-Mason-1.23.tar.gz
2.Rin /usr/lib/rpm/perl.req HTML-Mason-1.23/lib/HTML/Mason/FakeApache.pm
3.Note (bogus) perl(HTML::Mason::MethodMaker(read_write) dependancy
    

Actual Results:  perl(HTML::Mason::MethodMaker(read_write)

Expected Results:  perl(HTML::Mason::MethodMaker)

Additional info:

Folowing patch fixes:

*** /usr/lib/rpm/perl.req.orig	2003-10-09 14:02:42.000000000 +0100
--- /usr/lib/rpm/perl.req	2003-10-09 14:27:37.000000000 +0100
***************
*** 170,176 ****
        # sometimes people do use POSIX qw(foo), or use POSIX(qw(foo)) etc
        # we can strip qw.*$, as well as (.*$:
        $module =~ s/qw.*$//;
!       $module =~ s/\(*$//;
  
        $module =~ s/\.pm$//;
  
--- 170,176 ----
        # sometimes people do use POSIX qw(foo), or use POSIX(qw(foo)) etc
        # we can strip qw.*$, as well as (.*$:
        $module =~ s/qw.*$//;
!       $module =~ s/\(.*$//;
  
        $module =~ s/\.pm$//;

Comment 1 Jeff Johnson 2003-12-26 19:03:10 UTC
Hmmm, I swear I just closed this ...

FIxed in CVS, should be in rpm-4.2.2-0.8 and later.

Note: perl.req is being replaced with perldeps.pl soonish.

Comment 2 John Flanagan 2004-05-12 04:27:17 UTC
An errata has been issued which should help the problem described in this bug report. 
This report is therefore being closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files, please follow the link below. You may reopen 
this bug report if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2004-098.html