/[MITgcm]/MITgcm/tools/example_scripts/faulks/test_lcs_fc5
ViewVC logotype

Annotation of /MITgcm/tools/example_scripts/faulks/test_lcs_fc5

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.2 - (hide annotations) (download)
Sat May 20 14:21:46 2006 UTC (18 years ago) by edhill
Branch: MAIN
Changes since 1.1: +2 -2 lines
use the Intel v9 compiler on FC5 since v8 does not seem to work (at least
  as it is currently installed on authors)

1 edhill 1.1 #! /usr/bin/env bash
2    
3 edhill 1.2 # $Header: /u/gcmpack/MITgcm/tools/example_scripts/faulks/test_lcs_fc5,v 1.1 2006/05/19 17:52:57 edhill Exp $
4 edhill 1.1
5     # Ed Hill
6    
7     # Test script for MITgcm that should work on most of the lcs.mit.edu
8     # Linux machines.
9    
10     usage()
11     {
12     cat << EOF
13    
14     Usage: $0 [OPTIONS]
15    
16     where possible OPTIONS are:
17     (-help|-h) print usage
18     (-dir | -d) TDIR specify testing directory
19     (def="$TDIR")
20     (-of | -optfile) FILE specify an OPTFILE
21     (def="$OPTFILE")
22     (-[no]ieee) IEEE math flag
23     (def="$IEEE")
24    
25     EOF
26     exit 1
27     }
28    
29    
30     # defaults
31     export PATH='/usr/local/bin:/bin:/usr/bin'
32     OPTFILE=
33     TESTDIR="/scratch/edhill/test_"`hostname`
34     IEEE="-ieee"
35    
36     # Parse options
37     ac_prev=
38     for ac_option ; do
39    
40     # If the previous option needs an argument, assign it.
41     if test -n "$ac_prev"; then
42     eval "$ac_prev=\$ac_option"
43     ac_prev=
44     continue
45     fi
46    
47     ac_optarg=`expr "x$ac_option" : 'x[^=]*=\(.*\)'`
48    
49     case $ac_option in
50    
51     -help | --help | -h | --h)
52     usage ;;
53    
54     -dir | --dir | -d | --d)
55     ac_prev=TESTDIR ;;
56     -dir=* | --dir=* | -d=* | --d=*)
57     TESTDIR=$ac_optarg ;;
58    
59     -of | --of | -optfile | --optfile)
60     ac_prev=OPTFILE ;;
61     --of=* | -of=* | --optfile=* | -optfile=*)
62     OPTFILE=$ac_optarg ;;
63    
64     -ieee)
65     IEEE="-ieee" ;;
66     -noieee)
67     IEEE= ;;
68    
69     *)
70     echo "Error: don't understand argument \"$ac_option\""
71     usage
72     ;;
73    
74     esac
75    
76     done
77    
78     # Turn off stack limit for FIZHI
79     ulimit -s unlimited
80    
81     echo -n "Creating a temp directory ..."
82     mach=`hostname`
83     file=${OPTFILE##*/}
84     tdir=$TESTDIR"_"$file
85     test -e $tdir && rm -rf $tdir
86     mkdir $tdir
87     echo " done"
88    
89     echo -n "Downloading the MITgcm code from CVS pserver..."
90     cd $tdir
91     export CVSROOT='/u/gcmpack'
92     cvs co MITgcm > /dev/null 2>&1
93     echo " done"
94    
95     echo "Running testreport using:"
96     cd MITgcm/verification
97     comm="./testreport $IEEE -a edhill@mitgcm.org"
98     if test "x$OPTFILE" != x ; then
99     comm="$comm -of=$OPTFILE"
100     fi
101     echo " \"$comm\""
102     echo "======================"
103     echo
104     $comm | tail -100
105    
106     echo
107     echo "======================"
108     echo "Cleaning test directories:"
109     ./testreport -clean > /dev/null 2>&1
110     echo "======================"
111     echo
112    
113     echo "Running testreport using:"
114     cd MITgcm/verification
115 edhill 1.2 comm="./testreport $IEEE -of ../tools/build_options/linux_ia32_ifort+authors_v9 -a edhill@mitgcm.org"
116 edhill 1.1 echo " \"$comm\""
117     echo "======================"
118     echo
119     $comm | tail -100
120    
121     echo
122     echo "======================"
123     echo "Cleaning test directories:"
124     ./testreport -clean > /dev/null 2>&1
125     echo "======================"
126     echo
127    
128     echo "Running testreport using:"
129     export PGI=/usr/local/pkg/pgi/pgi-6.1-5
130     cd MITgcm/verification
131     comm="./testreport $IEEE -of ../tools/build_options/linux_ia32_pgf77+authors_fc5 -a edhill@mitgcm.org"
132     echo " \"$comm\""
133     echo "======================"
134     echo
135     $comm | tail -100
136    
137     echo
138     echo "======================"
139     echo "Cleaning test directories:"
140     ./testreport -clean > /dev/null 2>&1
141     echo "======================"
142     echo
143    
144     echo "Running testreport using:"
145     comm="./testreport -adm $IEEE -a edhill@mitgcm.org"
146     if test "x$OPTFILE" != x ; then
147     comm="$comm -of=$OPTFILE"
148     fi
149     echo " \"$comm\""
150     echo "======================"
151     echo
152     $comm | tail -100
153    

  ViewVC Help
Powered by ViewVC 1.1.22