Further tweak to avoid reporting deletion roots already marked as "Out".
authorWilliam Roberts <williamr@symbian.org>
Wed, 20 Oct 2010 23:13:37 +0100
changeset 76 af2426f01bab
parent 75 b0f4d5be8407
child 77 4bb92ff6576a
Further tweak to avoid reporting deletion roots already marked as "Out".
tools/filter_obyfile.pl
--- a/tools/filter_obyfile.pl	Wed Oct 20 22:45:30 2010 +0100
+++ b/tools/filter_obyfile.pl	Wed Oct 20 23:13:37 2010 +0100
@@ -411,14 +411,22 @@
 	{
 	next if (defined $must_have_exes{$exe});
 	my %dependents;
-	my $deletion_root = 1;
+	my $deletion_root = "";
 	foreach my $prerequisite (@{$exe_prerequisites{$exe}})
 		{
 		next if (defined $must_have_exes{$prerequisite});
-		$deletion_root = 0;	# at least one prerequisite is not a must_have, so will delete this exe if removed
+		$deletion_root = $prerequisite;	# at least one prerequisite is not a must_have, so will delete this exe if removed
 		last;
 		}
-	next if (!$deletion_root);
+	if (defined $deletions{$exe_to_romfile{$exe}})
+		{
+		if ($deletion_root ne "")
+			{
+			#print STDERR "Explicit deletion of $exe is not efficient - $deletion_root would remove it\n";
+			}
+			next;	# no need to report this one
+		}
+	next if ($deletion_root ne "");
 	
 	count_dependents($exe, \%dependents);
 	my $count = scalar keys %dependents;