From c9ccd372fb9655493cd527c37e51a7bd035370cc Mon Sep 17 00:00:00 2001 From: Raphaƫl Hertzog Date: Sun, 21 Feb 2010 02:39:44 +0100 Subject: dpkg-gencontrol: now indicates which package is concerned by the substvars warnings Enhance Dpkg::Substvarst to be able to display a prefix before its warnings and errors and make use of that facility in dpkg-gencontrol to be explicit about where the substitution is done. --- scripts/Dpkg/Control/Hash.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'scripts/Dpkg/Control') diff --git a/scripts/Dpkg/Control/Hash.pm b/scripts/Dpkg/Control/Hash.pm index 6b9f9d5de..b613da40d 100644 --- a/scripts/Dpkg/Control/Hash.pm +++ b/scripts/Dpkg/Control/Hash.pm @@ -339,7 +339,7 @@ the corresponding value stored in the Dpkg::Substvars object. =cut sub apply_substvars { - my ($self, $substvars) = @_; + my ($self, $substvars, %opts) = @_; # Add substvars to refer to other fields foreach my $f (keys %$self) { @@ -348,7 +348,7 @@ sub apply_substvars { } foreach my $f (keys %$self) { - my $v = $substvars->substvars($self->{$f}); + my $v = $substvars->substvars($self->{$f}, %opts); if ($v ne $self->{$f}) { # If we replaced stuff, ensure we're not breaking # a dependency field by introducing empty lines, or multiple -- cgit v1.2.3