3 # Copyright (c) 2012-2022. The SimGrid Team.
6 # This program is free software; you can redistribute it and/or modify it
7 # under the terms of the license (GNU LGPL) which comes with this package.
13 die "Usage: perl update_tesh.pl <directory> <old.tesh>\n";
16 my($directory)=$ARGV[0];
21 open SH_LIGNE, $old or die "Unable to open $old. $!\n";
28 while(defined($line=<SH_LIGNE>))
30 if($line =~ /^\$(.*)$/)
33 $line =~ s/\$\{srcdir\:\=\.\}/./g;
36 $line =~ s/^\$\ */.\//g;
37 $line =~ s/--log=([^ ]*)/--log="$1"/g;
40 open (FILE, "$line 2>&1|");
41 while(defined($l=<FILE>))
50 if($line =~ /^\>(.*)$/)