2 setenv MACHINE `uname -n`
6 setenv EXT_DIR ~wrfhelp/external
9 if (! -d $EXT_DIR) then
10 echo "Cannot find EXT_DIR=$EXT_DIR"
13 # Search for queuing systems.
14 # Don't use which, as it always returns 0 on BSD
16 if ($status == 0) then
20 if ($status == 0) then
21 setenv SUBMIT LoadLeveller
23 which qsub >& /dev/null
24 # could be SGE of course, so might need better way to check
33 if (! $?PROCESSOR) then
34 # Unix people can't even report processor class properly
35 # across different machines or between ksh/bash on Linux
36 # They all need their heads banged together
37 # This kludge should give powerpc/i686/i386(for intel Mac)
38 if ( `uname` == "AIX" ) then
39 # Thanks Aix for reporting a hex string with -m, when
40 # all I wanted was powerpc
41 setenv PROCESSOR `uname -p`
43 # Thanks Linux for either reporting nothing with -n,
44 # or different values for ksh and bash, FFS
45 setenv PROCESSOR `uname -m`
46 if ("$PROCESSOR" == "Power Macintosh") then
47 setenv PROCESSOR powerpc
52 if ( `uname` == "AIX" ) then
53 # Brain dead Aix /bin/csh cannot handle arguments to
54 # sourced scripts, so force use of ibm
64 if ($COMPILER == g95) then
68 if ($COMPILER == xlf) then
72 if ($COMPILER == gnu) then
76 if ($COMPILER == cray) then
81 # List options in order of increasing preference
83 if (-d ${EXT_DIR}/netcdf/netcdf-3.6.1/${COMPILER}_${PROCESSOR}) then
84 setenv NETCDF ${EXT_DIR}/netcdf/netcdf-3.6.1/${COMPILER}_${PROCESSOR}
86 if (-d ${EXT_DIR}/rttov/rttov87/${COMPILER}_${PROCESSOR}) then
87 setenv RTTOV ${EXT_DIR}/rttov/rttov87/${COMPILER}_${PROCESSOR}
89 #if (-d ${EXT_DIR}/crtm/CRTM_02-29-08/${COMPILER}_${PROCESSOR}) then
90 # setenv CRTM ${EXT_DIR}/crtm/CRTM_02-29-08/${COMPILER}_${PROCESSOR}
92 if (-d ${EXT_DIR}/crtm/CRTM_02_03_09_REL_1_2/${COMPILER}_${PROCESSOR}) then
93 setenv CRTM ${EXT_DIR}/crtm/CRTM_02_03_09_REL_1_2/${COMPILER}_${PROCESSOR}
95 if (-d ${EXT_DIR}/mpi/mpich-1.2.7p1/${COMPILER}_${PROCESSOR}) then
96 setenv MPIHOME ${EXT_DIR}/mpi/mpich-1.2.7p1/${COMPILER}_${PROCESSOR}
98 if (-d ${EXT_DIR}/mpi/mpich2-1.0.6p1/${COMPILER}_${PROCESSOR}) then
99 setenv MPIHOME ${EXT_DIR}/mpi/mpich2-1.0.6p1/${COMPILER}_${PROCESSOR}
101 #if (-d ${EXT_DIR}/blas/blas/${COMPILER}_${PROCESSOR}) then
102 # setenv BLAS ${EXT_DIR}/blas/blas/${COMPILER}_${PROCESSOR}
104 #if (-d ${EXT_DIR}/lapack/lapack-3.1.1/${COMPILER}_${PROCESSOR}) then
105 # setenv LAPACK ${EXT_DIR}/lapack/lapack-3.1.1/${COMPILER}_${PROCESSOR}
107 #if (-d ${EXT_DIR}/fftpack/fftpack5/${COMPILER}_${PROCESSOR}) then
108 # setenv FFTPACK ${EXT_DIR}/fftpack/fftpack5/${COMPILER}_${PROCESSOR}
110 if (-d ${EXT_DIR}/bufr/bufr_ncep_nco/${COMPILER}_${PROCESSOR}) then
111 setenv BUFR ${EXT_DIR}/bufr/bufr_ncep_nco/${COMPILER}_${PROCESSOR}
113 if (-d ${EXT_DIR}/zlib/zlib-1.2.3/${COMPILER}_${PROCESSOR}) then
114 setenv ZLIB ${EXT_DIR}/zlib/zlib-1.2.3/${COMPILER}_${PROCESSOR}
116 if (-d ${EXT_DIR}/jpeg/jpeg-6b/${COMPILER}_${PROCESSOR}) then
117 setenv JPEG ${EXT_DIR}/jpeg/jpeg-6b/${COMPILER}_${PROCESSOR}
119 if (-d ${EXT_DIR}/hdf/hdf4.2r1/${COMPILER}_${PROCESSOR}) then
120 setenv HDF4 ${EXT_DIR}/hdf/hdf4.2r1/${COMPILER}_${PROCESSOR}
122 if (-d ${EXT_DIR}/hdf/hdf5-1.6.5/${COMPILER}_${PROCESSOR}) then
123 setenv HDF5 ${EXT_DIR}/hdf/hdf5-1.6.5/${COMPILER}_${PROCESSOR}
125 if (-d ${EXT_DIR}/hdf/HDF-EOS2.14v1.00/${COMPILER}_${PROCESSOR}) then
126 setenv HDFEOS ${EXT_DIR}/hdf/HDF-EOS2.14v1.00/${COMPILER}_${PROCESSOR}
128 if (-d ${EXT_DIR}/jasper/jasper-1.900.1/${COMPILER}_${PROCESSOR}) then
129 setenv JASPER ${EXT_DIR}/jasper/jasper-1.900.1/${COMPILER}_${PROCESSOR}
131 if (-d ${EXT_DIR}/netcdf/pnetcdf-1.0.1/${COMPILER}_${PROCESSOR}) then
132 setenv PNETCDF ${EXT_DIR}/netcdf/pnetcdf-1.0.1/${COMPILER}_${PROCESSOR}
134 #if (-d ${EXT_DIR}/madis/${COMPILER}_${PROCESSOR}) then
135 # setenv MADIS ${EXT_DIR}/madis/${COMPILER}_${PROCESSOR}
138 if (-d /usr/lpp/ppe.poe) then
139 setenv MPIHOME /usr/lpp/ppe.poe
142 setenv LINUX_MPIHOME $MPIHOME
143 setenv PATH $MPIHOME/bin:$PATH
147 if ($?PROCESSOR) then
148 echo "PROCESSOR " $PROCESSOR
151 echo "COMPILER " $COMPILER
154 echo "MPIHOME " $MPIHOME
163 echo "NETCDF " $NETCDF
169 # echo "LAPACK " $LAPACK
172 # echo "FFTPACK " $FFTPACK
190 echo "HDFEOS " $HDFEOS
193 echo "JASPER " $JASPER
196 echo "PNETCDF " $PNETCDF
199 # echo "MADIS " $MADIS
202 echo "SUBMIT " $SUBMIT
204 if ($?SUBMIT_OPTIONS1) then
205 echo "SUBMIT_OPTIONS1 $SUBMIT_OPTIONS1"
207 if ($?SUBMIT_OPTIONS2) then
208 echo "SUBMIT_OPTIONS2 $SUBMIT_OPTIONS2"
210 if ($?SUBMIT_OPTIONS3) then
211 echo "SUBMIT_OPTIONS3 $SUBMIT_OPTIONS3"
213 if ($?SUBMIT_OPTIONS4) then
214 echo "SUBMIT_OPTIONS4 $SUBMIT_OPTIONS4"
216 if ($?SUBMIT_OPTIONS5) then
217 echo "SUBMIT_OPTIONS5 $SUBMIT_OPTIONS5"
219 if ($?SUBMIT_OPTIONS6) then
220 echo "SUBMIT_OPTIONS6 $SUBMIT_OPTIONS6"
222 if ($?SUBMIT_OPTIONS7) then
223 echo "SUBMIT_OPTIONS7 $SUBMIT_OPTIONS7"
225 if ($?SUBMIT_OPTIONS8) then
226 echo "SUBMIT_OPTIONS8 $SUBMIT_OPTIONS8"
228 if ($?SUBMIT_OPTIONS9) then
229 echo "SUBMIT_OPTIONS9 $SUBMIT_OPTIONS9"
231 if ($?SUBMIT_OPTIONS10) then
232 echo "SUBMIT_OPTIONS10 $SUBMIT_OPTIONS10"
234 if ($?SUBMIT_WAIT_FLAG) then
235 echo "SUBMIT_WAIT_FLAG $SUBMIT_WAIT_FLAG"
238 if ($COMPILER == cray) then
239 # Cray use COMPILER for their own purposes, so reset