11 |
echo "where possible OPTIONS are:" |
echo "where possible OPTIONS are:" |
12 |
echo " (-help|-h) print usage" |
echo " (-help|-h) print usage" |
13 |
echo " (-mpi) use MPI input files" |
echo " (-mpi) use MPI input files" |
14 |
|
echo " (-ieee|-noieee) if possible, use IEEE compiler flags" |
15 |
echo " (-optfile=|-of=)STRING list of optfiles to use" |
echo " (-optfile=|-of=)STRING list of optfiles to use" |
16 |
echo " (-a|-addr)STRING list of email recipients" |
echo " (-a|-addr)STRING list of email recipients" |
17 |
echo " (DEF=\"edhill@mitgcm.org\")" |
echo " (DEF=\"edhill@mitgcm.org\")" |
19 |
echo " (DEF=\"\" which builds all)" |
echo " (DEF=\"\" which builds all)" |
20 |
echo " (-b|-bash)STRING location of \"bash\" executable" |
echo " (-b|-bash)STRING location of \"bash\" executable" |
21 |
echo " (DEF=\"\" for \"/bin/bash\")" |
echo " (DEF=\"\" for \"/bin/bash\")" |
22 |
echo " (-c|-command)STRING command to run" |
echo " (-command)STRING command to run" |
23 |
echo " (DEF=\"make output.txt\")" |
echo " (DEF=\"make output.txt\")" |
24 |
echo " (-m|-make)STRING command to use for \"make\"" |
echo " (-m|-make)STRING command to use for \"make\"" |
25 |
echo " (DEF=\"make\")" |
echo " (DEF=\"make\")" |
26 |
|
echo " (-clean) *ONLY* run \"make CLEAN\"" |
27 |
echo " (-quick|-q) same as \"-nogenmake -noclean -nodepend\"" |
echo " (-quick|-q) same as \"-nogenmake -noclean -nodepend\"" |
28 |
echo " (-nogenmake|-ng) skip the genmake stage" |
echo " (-nogenmake|-ng) skip the genmake stage" |
29 |
echo " (-noclean|-nc) skip the \"make clean\" stage" |
echo " (-noclean|-nc) skip the \"make clean\" stage" |
192 |
command="$command --optfile=$OPTFILE" |
command="$command --optfile=$OPTFILE" |
193 |
# echo " command=\"$command\"" |
# echo " command=\"$command\"" |
194 |
fi |
fi |
195 |
|
if test "x$IEEE" != x ; then |
196 |
|
command="$command -ieee" |
197 |
|
fi |
198 |
$command > make.log 2>&1 |
$command > make.log 2>&1 |
199 |
RETVAL=$? |
RETVAL=$? |
200 |
for i in gm_state gm_optfile gm_local Makefile ; do |
for i in genmake_state genmake_optfile genmake_local Makefile ; do |
201 |
if test -r $i ; then |
if test -r $i ; then |
202 |
cp $i $CDIR |
cp $i $CDIR |
203 |
fi |
fi |
392 |
-debug Produce even more output which will mean nothing to most |
-debug Produce even more output which will mean nothing to most |
393 |
-force Do "make CLEAN" before compiling. This forces a complete rebuild. |
-force Do "make CLEAN" before compiling. This forces a complete rebuild. |
394 |
-clean Do "make CLEAN" after compiling and testing. |
-clean Do "make CLEAN" after compiling and testing. |
|
-noieee By default, $0 uses the -ieee option for genmake. This turns it off. |
|
395 |
-cleanup Aggresively removes all model output, executables and object files |
-cleanup Aggresively removes all model output, executables and object files |
396 |
and then exits. Use with care. |
and then exits. Use with care. |
397 |
|
|
424 |
expts='' |
expts='' |
425 |
# ieee=1 |
# ieee=1 |
426 |
|
|
427 |
|
IEEE= |
428 |
|
if test "x$MITGCM_IEEE" != x ; then |
429 |
|
IEEE=$MITGCM_IEEE |
430 |
|
fi |
431 |
|
|
432 |
|
|
433 |
CLEANUP=f |
CLEANUP=f |
434 |
QUICK=f |
QUICK=f |
435 |
NOGENMAKE=f |
NOGENMAKE=f |
507 |
-nodepend | --nodepend | -nd | --nd) |
-nodepend | --nodepend | -nd | --nd) |
508 |
NODEPEND=t ;; |
NODEPEND=t ;; |
509 |
|
|
510 |
-mpi) MPI=t ;; |
-mpi) MPI=true ;; |
511 |
|
|
512 |
|
-ieee) IEEE=true ;; |
513 |
|
-noieee) IEEE= ;; |
514 |
|
|
515 |
-verbose) verbose=2 ;; |
-verbose) verbose=2 ;; |
516 |
-debug) debug=1 ;; |
-debug) debug=1 ;; |
|
-clean) clean=1 ;; |
|
517 |
-quiet) verbose=0 ;; |
-quiet) verbose=0 ;; |
518 |
|
|
519 |
-*) |
-*) |
608 |
# Verify that the testdir exists and contains previous |
# Verify that the testdir exists and contains previous |
609 |
# results in the correct location--or skip this directory! |
# results in the correct location--or skip this directory! |
610 |
if test ! -r $dir"/results/output.txt" ; then |
if test ! -r $dir"/results/output.txt" ; then |
|
echo |
|
611 |
echo "can't read \"$dir/results/output.txt\" -- skipping $dir" |
echo "can't read \"$dir/results/output.txt\" -- skipping $dir" |
|
echo |
|
612 |
continue |
continue |
613 |
fi |
fi |
614 |
|
|