From b2969c5512719f60519599fe94303e1d037816fe Mon Sep 17 00:00:00 2001 From: Claudio Matsuoka Date: Tue, 14 Nov 2006 17:49:59 +0000 Subject: Fixed log message, renamed variable, code cleanup --- emi | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'emi') diff --git a/emi b/emi index 296eb7d..3a7270e 100755 --- a/emi +++ b/emi @@ -160,7 +160,7 @@ sub todo_func { if ($r =~ /(\d{14}\.\w+\.\w+\.\d+)_(.*\.([^.]+)\.rpm)$/) { my ($prefix, $rpm, $arch) = ($1, $2, $3); - plog("$program_name: found todo rpm $rpm ($prefix)"); + plog("found todo rpm $rpm ($prefix)"); push @{$pkg_tree{$prefix}{todo}}, $rpm; } } @@ -177,26 +177,26 @@ unlink $pidfile; # foreach my $prefix (keys %pkg_tree) { - my $ok = 1; my $target = $pkg_tree{$prefix}{target}; my $path = $pkg_tree{$prefix}{path}; my $section = $pkg_tree{$prefix}{section}; + my %missing; plog("processing $prefix in $path"); - my %missing; - foreach my $mandatory_arch (@{$config->{mandatory_arch}}, 'src') { - $excluded{$prefix}{$mandatory_arch} and next; + my $ok = 1; + foreach my $m (@{$config->{mandatory_arch}}, 'src') { + $excluded{$prefix}{$m} and next; my $x = "yes"; - if (!$pkg_tree{$prefix}{arch}{$mandatory_arch} && !$pkg_tree{$prefix}{arch}{noarch}){ - if (!$cache->{arch}{$prefix}{$mandatory_arch}) { - $missing{$mandatory_arch} = 1; + if (!$pkg_tree{$prefix}{arch}{$m} && !$pkg_tree{$prefix}{arch}{noarch}){ + if (!$cache->{arch}{$prefix}{$m}) { + $missing{$m} = 1; $x = "no"; $ok = 0; } else { $x = "yes (in cache)"; } } - plog(" mandatory architecture $mandatory_arch present: $x"); + plog(" mandatory architecture $m present: $x"); } unless ($ok) { -- cgit v1.2.1