cd /path/to/WAVEWATCH
tar -xvf WW3-6.07.1.tar.gz
cd WW3-6.07.1
vi env_ww3.sh
############# gnu + openmpi ################# export PATH=/path/to/GNU/bin:$PATH export LD_LIBRARY_PATH=/path/to/GNU/lib64:$LD_LIBRARY_PATH export PATH=/path/to/OpenMPI/bin:$PATH export LD_LIBRARY_PATH=/path/to/OpenMPI/lib:$LD_LIBRARY_PATH ############# netcdf ################# export NETCDF_DIR=/path/to/NETCDF export NETCDF_LIBDIR=$NETCDF_DIR/lib export NETCDF_INCDIR=$NETCDF_DIR/include export PATH=$NETCDF_DIR/bin:$PATH export LD_LIBRARY_PATH=$NETCDF_LIBDIR:$LD_LIBRARY_PATH export WWATCH3_NETCDF=NC4 export NETCDF_CONFIG=$NETCDF_DIR/bin/nc-config ############# metis ################# export METIS_PATH=/path/to/METIS export PATH=$METIS_PATH/bin:$PATH export LD_LIBRARY_PATH=$METIS_PATH/lib:$LD_LIBRARY_PATH
“/path/to/GNU”指GNU9.1的安装路径,“/path/to/OPENMPI”指OpenMPI的安装路径,“/path/to/NETCDF”指NETCDF和NETCDF-Fortran的安装路径,“/path/to/METIS”指ParMETIS的安装路径。
source env_ww3.sh
./model/bin/w3_setup model/
***************************** *** WAVEWATCH III setup *** ***************************** [INFO] local env file wwatch3.env created in /home/WW3-6.07.1/model/bin/wwatch3.env Setup file /home/WW3-6.07.1/model/bin/wwatch3.env not found Default set up : Printer (listings) : printer Auxiliary FORTRAN comp. : gfortran Auxiliary C compiler : gcc Scratch directory : /path/to/WAVEWATCH/WW3-6.07.1/model/tmp Save sources : yes Save listings : yes Update settings ? [y/n] y Creating new set-up : Printer for listings [printer] : Auxiliary FORTRAN compiler [gfortran] : Auxiliary C compiler [gcc] : Scratch space [/home/wdy/WW3-6.07.1/model/tmp] : Save source code files (*.f) [yes] : Save listing files [yes] : Modified set up : Printer (listings) : printer Auxiliary FORTRAN comp. : gfortran Auxiliary C compiler : gcc Scratch directory : /path/to/WAVEWATCH III/WW3-6.07.1/model/tmp Save sources : yes Save listings : yes New settings OK ? [y/n] y Setup makefile for auxiliary programs …… Create required model subdirectories Finished setting up WAVEWATCH III