From c50bf7b4a8dbdf530673472d50b3f1f3c0ccedb9 Mon Sep 17 00:00:00 2001 From: Pascal Terjan Date: Wed, 19 Sep 2012 20:57:16 +0000 Subject: Enforce presence of the archs we want --- emi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/emi b/emi index 99fae15..ae7a5d4 100755 --- a/emi +++ b/emi @@ -192,12 +192,12 @@ foreach my $prefix (sort keys %pkg_tree) { my $ok = 1; foreach my $section (keys %{$pkg_tree{$prefix}{section}}) { - my $has_arched_packages = scalar(difference2([ keys %{$pkg_tree{$prefix}{section}{$section}{arch}} ], [ qw(src noarch) ])); + my @wanted_archs = defined($pkg_tree{$prefix}{section}{$section}{arch}{noarch}) ? ('noarch') : @{$config->{mandatory_arch}}; my $path = $pkg_tree{$prefix}{section}{$section}{path}; my %missing; plog('DEBUG', "... in $path"); - foreach my $m (if_($has_arched_packages, @{$config->{mandatory_arch}}), 'src') { + foreach my $m (@wanted_archs, 'src') { $excluded{$prefix}{$section}{$m} and next; my $x = "yes"; if (!$pkg_tree{$prefix}{section}{$section}{arch}{$m}) { -- cgit v1.2.1