File: run.pl

package info (click to toggle)
spades 3.13.1+dfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, sid
  • size: 22,172 kB
  • sloc: cpp: 136,213; ansic: 48,218; python: 16,809; perl: 4,252; sh: 2,115; java: 890; makefile: 507; pascal: 348; xml: 303
file content (22 lines) | stat: -rwxr-xr-x 504 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#!/usr/bin/perl

#my @children;

use Cwd 'abs_path';
use File::Basename;
my $script_dir = dirname(abs_path($0));

system("gcc $script_dir/pstree.c -o $script_dir/pstree");

my $child = fork;
exec "@ARGV 1>>rc_stdout.txt 2>>rc_stderr.txt" if $child == 0;
print "started...\n";

my $stat_proc = fork;
if ($stat_proc == 0) {
  exec "python3 $script_dir/stats_counter.py $child 1>>rc_stats.txt 2>>rc_stats.txt";
}

waitpid($child, 0);
waitpid($stat_proc, 0);
print "finished. Results are in rc_stats.txt\n";