cd /path/to/hwrf/wrfrun/sorc/ tar -xvf ../../HWRF_v4.0a_gfdl-vortextracker.tar.gz
export LIB_W3_PATH=$HWRF_DIR/hwrfrun/sorc/hwrf-utilities/libs export LIB_BACIO_PATH=$HWRF_DIR/hwrfrun/sorc/hwrf-utilities/libs export LIB_G2_PATH=$HWRF_DIR/hwrfrun/sorc/hwrf-utilities/libs export LIB_JASPER_PATH=$JASPER_LIB export LIB_PNG_PATH=$LIBPNG_LIB export LIB_Z_PATH=$ZLIB_LIB
vim patch-gfdl-vortextracker
输入以下内容并保存。
diff -Nru gfdl-vortextracker/arch/configure.defaults gfdl-vortextracker_ok/arch/configure.defaults --- gfdl-vortextracker/arch/configure.defaults 2017-07-21 02:50:08.122659000 +0800 +++ gfdl-vortextracker_ok/arch/configure.defaults 2023-07-21 16:04:07.195770420 +0800 @@ -1,4 +1,27 @@ ########################################################### +#ARCH Linux aarch64, Bisheng compiler, HyperMPI KML # serial +# +LDFLAGS = -fopenmp -Wl,-noinhibit-exec -Wl,--build-id -L$(HMPI_LIB) -L$(KML_LIB) -lkm_l9 -lkm -lmathlib + +BYTE_ORDER = BIG_ENDIAN +SFC = mpifort -fopenmp +SF90 = mpif90 -fopenmp -ffree-form +SCC = mpicc -fopenmp +FFLAGS = -O3 -ffp-model=precise -fconvert=big-endian -DLINUX -I$(HMPI_INC) -fvariable-format-expr +DEBUG_FLAGS = -O0 -g -traceback -I$(HMPI_INC) +CPP = cpp +CPPFLAGS = -P -traditional -D$(BYTE_ORDER) #-DWRF -Dibm_sp -I/usr/lpp/ppe.poe/include/thread + +DM_FC = mpifort +DM_F90 = mpif90 -ffree-form +DM_CC = mpicc + +FC = $(DM_FC) +F90 = $(DM_F90) +CC = $(DM_CC) + +CFLAGS = -O3 +########################################################### #ARCH AIX #serial #
patch -p0 < ./patch-gfdl-vortextracker
cd gfdl-vortextracker echo 1 | ./configure
./compile 2>&1 | tee -a build.log
ls -l trk_exec/*.exe
成功编译后将在目录trk_exec中生成可执行文件。