~ubuntu-branches/ubuntu/oneiric/mpqc/oneiric

« back to all changes in this revision

Viewing changes to debian/chkmpqcval

  • Committer: Bazaar Package Importer
  • Author(s): Michael Banck
  • Date: 2010-02-27 15:55:01 UTC
  • mfrom: (3.1.4 sid)
  • Revision ID: james.westby@ubuntu.com-20100227155501-ug7yg3uil3cmy9il
Tags: 2.3.1-6
* Upload to unstable.
* debian/mpqcval: Fix using default directory if no files are specified on
  the command-line.
* debian/rules (OPENMPIARGS): Enable MPI configure switches.

Show diffs side-by-side

added added

removed removed

Lines of Context:
18
18
    shift;
19
19
    my $rundir = $ARGV[0];
20
20
    shift;
 
21
    if (!$rundir) {
 
22
        $rundir = "/usr/share/mpqc/validate";
 
23
    }
21
24
    opendir(DIR,"$dir");
22
25
    my @files = sort(readdir(DIR));
23
26
    closedir(DIR);
27
30
        }
28
31
    }
29
32
}
30
 
else {
 
33
elsif ($#ARGV+1 == 2) {
31
34
    my $file1 = shift;
32
35
    my $file2 = shift;
33
36
 
40
43
 
41
44
    check($file1, $file2);
42
45
}
 
46
else {
 
47
    my $dir = ".";
 
48
    my $rundir = "/usr/share/mpqc/validate";
 
49
    opendir(DIR,"$dir");
 
50
    my @files = sort(readdir(DIR));
 
51
    closedir(DIR);
 
52
    foreach $file (@files) {
 
53
        if ($file =~ /.out$/) {
 
54
            check("$dir/$file", "$rundir/$file");
 
55
        }
 
56
    }
 
57
}
43
58
 
44
59
# Takes the name of the output file as the first argument.  It must end in
45
60
# a .out. The QCInput file must be in the same directory and must end in a
50
65
    my $comparefileout = shift;
51
66
    my $file = $fileout;
52
67
    $file =~ s/\.out$//;
53
 
    my $filein = "/usr/share/mpqc/run/$file.qci";
 
68
    my $filein = "/usr/share/mpqc/validate/$file.qci";
54
69
 
55
70
    my $result = new QCResult("$filein","$fileout");
56
71
    my $ok = "failed";