Tweak to avoid an abort if the system definition cannot be opened to obtain the package names.
authorSimon Howkins <simonh@symbian.org>
Mon, 09 Nov 2009 18:13:38 +0000
changeset 108 8d399d7a7b6b
parent 107 5ef59c8a5f93
child 109 718b119bed63
Tweak to avoid an abort if the system definition cannot be opened to obtain the package names. Fixed a hard-coded "PDK_2.0.0".
releaseAutomation/packageComparison.pl
--- a/releaseAutomation/packageComparison.pl	Mon Nov 09 15:55:05 2009 +0000
+++ b/releaseAutomation/packageComparison.pl	Mon Nov 09 18:13:38 2009 +0000
@@ -63,11 +63,9 @@
 
 my $xml = XML::Parser->new(Style => "Objects") or die;
 # Load current names from current system definition
-my $tree = $xml->parsefile($sysDef);
-populateNames($packages->{current}, $tree);
+eval { populateNames($packages->{current}, $xml->parsefile($sysDef) ) };
 # Load previous names from previous system definition
-eval { $tree = $xml->parsestring(scalar `hg cat -r $previousPdkLabel $prevSysDef`) } or die $!;
-populateNames($packages->{previous}, $tree);
+eval { populateNames($packages->{previous}, $xml->parsestring(scalar `hg cat -r $previousPdkLabel $prevSysDef`) ) };
 
 # Output release note info...
 
@@ -164,7 +162,7 @@
 	print "==== $packages->{current}->{$_}->{name} ([$packages->{current}->{$_}->{url} $packages->{current}->{$_}->{path}]) ====\n";
 }
 
-print "\n=== FCLs used in PDK_2.0.0 but no longer needed ===\n\n";
+print "\n=== FCLs used in $previousPdkLabel but no longer needed ===\n\n";
 my @revertedToMCL = sort { packageSort($packages->{current}) } grep { inPrev($_) && $packages->{previous}->{$_}->{codeline} eq "FCL" && $packages->{current}->{$_}->{codeline} eq "MCL" } keys %{$packages->{current}};
 print "(none)\n" unless @revertedToMCL;
 foreach (@revertedToMCL)