From 5fb6b8fee487f9b017f13d8589745ca668eaedab Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Wed, 25 Jul 2012 17:02:05 +0000 Subject: sync with upstream rpm.org: "Fix perl version provide for packages defined in multiple blocks (#rhbz214496) Successive definitions of the same package shouldn't stomp on previously found $VERSION, this is how perl itself behaves. Patch from James Ralston." (Panu Matilainen, 2007-08-28) --- perl.prov | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'perl.prov') diff --git a/perl.prov b/perl.prov index 7ac8c16..1668d29 100755 --- a/perl.prov +++ b/perl.prov @@ -139,7 +139,11 @@ sub process_file { if ($package eq 'main') { undef $package; } else { - $require{$package}=undef; + # If $package already exists in the $require hash, it means + # the package definition is broken up over multiple blocks. + # In that case, don't stomp a previous $VERSION we might have + # found. (See BZ#214496.) + $require{$package} = undef unless (exists $require{$package}); } } } -- cgit v1.2.1