On Mon, Jan 25, 2010 at 10:44:26AM -0500, RD Thrush wrote:
> ${PORTSDIR}/infrastructure/build/out-of-date generates unusable data
> for a port with a packing list containing '@option always-update'.
>
> The following patch fixes the problem (which appears to be fallout from the
> recent pkg_add improvements):
[...]
Here's a diff that actually applies (no tabs expanded) and
that uses
$plist->has('always-update')
instead of
defined $plist->{'always-update'}
Ciao,
Kili
Index: out-of-date
===================================================================
RCS file: /cvs/ports/infrastructure/build/out-of-date,v
retrieving revision 1.17
diff -u -p -r1.17 out-of-date
--- out-of-date 2 Jan 2010 12:54:22 -0000 1.17
+++ out-of-date 27 Jan 2010 10:46:16 -0000
@@ -45,7 +45,7 @@ sub collect_installed
print STDERR "Package $name has no valid
packing-list\n";
next;
}
-
+
my $subdir = $plist->{extrainfo}->{subdir};
$subdir =~ s/mystuff\///;
$subdir =~ s/\/usr\/ports\///;
@@ -53,9 +53,13 @@ sub collect_installed
$pkg->{$subdir}->{name} = $name;
$pkg->{$subdir}->{stem} = $stem;
$pkg->{$subdir}->{version} = $version;
- my $sig = $plist->signature;
- if (ref($sig)) { $sig = $sig->string; }
- $pkg->{$subdir}->{signature} = $sig;
+ if ($plist->has('always-update')) {
+ $pkg->{$subdir}->{signature} = 'always-update';
+ } else {
+ my $sig = $plist->signature;
+ if (ref($sig)) { $sig = $sig->string; }
+ $pkg->{$subdir}->{signature} = $sig;
+ }
}
return $pkg;
}