* If a patch already exists, it must still be included in the manifest.

This commit is contained in:
Eelco Dolstra 2004-12-31 11:07:12 +00:00
parent 35b76a81c4
commit c53898cb65

View file

@ -215,12 +215,13 @@ foreach my $p (keys %dstOutPaths) {
my $finalName =
"$narDiffHash-$name-$closestVersion-to-$version.nar-bsdiff";
print " size $narDiffSize; full size $dstNarBz2Size\n";
if (-e "$patchesDir/$finalName") {
print " not copying, already exists\n";
next;
}
print " size $narDiffSize; full size $dstNarBz2Size\n";
else {
system("cp '$tmpdir/DIFF' '$patchesDir/$finalName.tmp'") == 0
or die "cannot copy diff";
@ -228,6 +229,8 @@ foreach my $p (keys %dstOutPaths) {
rename("$patchesDir/$finalName.tmp", "$patchesDir/$finalName")
or die "cannot rename $patchesDir/$finalName.tmp";
}
# Add the patch to the manifest.
addPatch \%dstPatches, $p,
{ url => "$patchesURL/$finalName", hash => $narDiffHash