Update of /cvsroot/fink/fink/perlmod/Fink
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv15632

Modified Files:
        Package.pm PkgVersion.pm ChangeLog 
Log Message:
Fixed typo in get_source_count shortcut for SplitOffs.

%n is now non-variant portion of Package (i.e., %type_*[] blanked
out). %Vn is full (with %type_*[] already expanded) Package. %N is %Vn
of parent. Thanks DRM.


Index: Package.pm
===================================================================
RCS file: /cvsroot/fink/fink/perlmod/Fink/Package.pm,v
retrieving revision 1.70
retrieving revision 1.71
diff -u -d -r1.70 -r1.71
--- Package.pm  1 Mar 2004 09:46:39 -0000       1.70
+++ Package.pm  4 Mar 2004 01:44:08 -0000       1.71
@@ -505,6 +505,7 @@
        my $filename = shift;
 
        my %pkg_expand;
+
        if (exists $properties->{type}) {
                if ($properties->{type} =~ /([a-z0-9+.\-]*)\s*\((.*?)\)/) {
                        # if we were fed a list of subtypes, remove the list and
@@ -533,10 +534,16 @@
                }
        }
 #      print map "\t$_=>$pkg_expand{$_}\n", sort keys %pkg_expand;
+
+
+       # store invariant portion of Package (for %n; %Vn is with variants)
+       ( $properties->{package_invariant} = $properties->{package} ) =~ 
s/\%type_(raw|pkg)\[.*?\]//g;
        if (exists $properties->{parent}) {
                # get parent's Package for percent expansion
+               # (only splitoffs can use %N in Package)
                $pkg_expand{'N'}  = $properties->{parent}->{package};
                $pkg_expand{'n'}  = $pkg_expand{'N'};  # allow for a typo
+               $properties->{package_invariant} = 
&expand_percent($properties->{package_invariant},\%pkg_expand, "$filename 
\"package\"");
        }
 
        $properties->{package} = &expand_percent($properties->{package},\%pkg_expand, 
"$filename \"package\"");

Index: PkgVersion.pm
===================================================================
RCS file: /cvsroot/fink/fink/perlmod/Fink/PkgVersion.pm,v
retrieving revision 1.234
retrieving revision 1.235
diff -u -d -r1.234 -r1.235
--- PkgVersion.pm       2 Mar 2004 21:37:50 -0000       1.234
+++ PkgVersion.pm       4 Mar 2004 01:44:08 -0000       1.235
@@ -149,7 +149,9 @@
                $parentdestdir = $destdir;
                $self->{_splitoffs} = [];
        }
-       $expand = { 'n' => $pkgname,
+       $self->{package_invariant} = $pkgname unless exists 
$self->{package_invariant};  # virtual packages don't know to set this field
+       $expand = { 'n' => $self->{package_invariant},
+                               'Vn'=> $pkgname,
                                'e' => $epoch,
                                'v' => $version,
                                'r' => $revision,
@@ -560,7 +562,7 @@
 sub get_source_count {
        my $self = shift;
 
-       if (exists $self->{_parent}) {
+       if (exists $self->{parent}) {
                # SplitOff packages have no sources of their own
                return 0;
        }

Index: ChangeLog
===================================================================
RCS file: /cvsroot/fink/fink/perlmod/Fink/ChangeLog,v
retrieving revision 1.562
retrieving revision 1.563
diff -u -d -r1.562 -r1.563
--- ChangeLog   2 Mar 2004 21:37:50 -0000       1.562
+++ ChangeLog   4 Mar 2004 01:44:08 -0000       1.563
@@ -1,3 +1,10 @@
+2004-03-03  Daniel Macks  <[EMAIL PROTECTED]>
+
+       * PkgVersion.pm: typo in get_source_count shortcut for SplitOffs.
+       * Package.pm, PkgVersion.pm: %n is now non-variant portion of
+       Package (i.e., %type_*[] blanked out). %Vn is full (with %type_*[]
+       already expanded) Package. %N is %Vn of parent.
+       
 2004-03-02  Daniel Macks  <[EMAIL PROTECTED]>
 
        * PkgVersion.pm: fix error message for missing Package: in



-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
Fink-commits mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/fink-commits

Reply via email to