Blame | Last modification | View Log | Download | RSS feed
#!/bin/csh
# ----- Load modules --------------------------
module load netcdf/4.2.1-pgf90
module list
set tool = footprint
# ----- Set libraries and includes ------------
set libs = "${LAGRANTO}/lib/iotra.a"
set libs = "${libs} -L ${LAGRANTO}/lib"
set libs = "${libs} -lcdfio"
set libs = "${libs} -lcdfplus"
set libs = "${libs} ${LAGRANTO}/lib/times.a"
set ncdf_incs = `nc-config --fflags`
set ncdf_libs = `nc-config --flibs`
# ---- Modules ---------------------------------
${FORTRAN} -c footprint_proxy.f ${ncdf_incs}
${FORTRAN} -c rotate.f ${ncdf_incs}
set mods = "footprint_proxy.o rotate.a"
# ----- Compile --------------------- ----------
\rm -f ${tool}.o
\rm -f ${tool}
echo "${FORTRAN} -c ${tool}.f ${ncdf_incs}"
${FORTRAN} -c ${tool}.f ${ncdf_incs}
echo "${FORTRAN} -o ${tool} ${tool}.o ${mods} ${libs} ${ncdf_libs}"
${FORTRAN} -o ${tool} ${tool}.o ${mods} ${libs} ${ncdf_libs}
if ( ! -f ${tool} ) then
echo "ERROR: compilation of <tool> failed... exit"
exit 1
endif
exit 0