From: alegrand Date: Thu, 20 Jan 2011 13:04:55 +0000 (+0000) Subject: Untested update to take deployment file into account. X-Git-Tag: v3.6_beta2~482 X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/commitdiff_plain/f4da53bd5d079a51859a52524d51059425b6d462 Untested update to take deployment file into account. git-svn-id: svn+ssh://scm.gforge.inria.fr/svn/simgrid/simgrid/trunk@9447 48e7efb5-ca39-0410-a469-dd3cf9ba447f --- diff --git a/tools/simgrid_update_xml.pl b/tools/simgrid_update_xml.pl index 2ca57b959b..0547ad96d4 100755 --- a/tools/simgrid_update_xml.pl +++ b/tools/simgrid_update_xml.pl @@ -19,10 +19,12 @@ my($output_string); $ARGV[0] or die "simgrid_update_xml.pl \n"; open INPUT, "$ARGV[0]" or die "Cannot open input file $ARGV[0]: $!\n"; -$output_string .= "\n"; -$output_string .= "\n"; -$output_string .= "\n"; -$output_string .= " \n"; +$output_string = "\n". + "\n". + "\n"; + + +my($AS_opened)=0; my $line; while (defined($line = )) { @@ -74,7 +76,21 @@ while (defined($line = )) { if ($fromversion < 3) { $line =~ s/\blink:ctn\b/link_ctn/g; $line =~ s/\btrace:connect\b/trace_connect/g; - $line =~ s/^(.*)<\/platform>(.*)$/ <\/AS>\n<\/platform>/; + + if($AS_opened && (($line=~ /<\/platform>/) || ($line=~ /\n"; + $AS_opened=1; + } } $output_string .= "$line\n";