Skip to content

Commit

Permalink
add configure file for NoahMP container environment
Browse files Browse the repository at this point in the history
  • Loading branch information
cenlinhe committed Jan 5, 2024
1 parent 984ee59 commit edd5781
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 2 deletions.
25 changes: 25 additions & 0 deletions hrldas/arch/user_build_options.gfortran.mpi.container
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@

#=============================================================================================
# Options for Linux with gnu gfortran MPI
# Please change the library paths according to your computer setup
#=============================================================================================

COMPILERF90 = mpif90
MPPFLAG = YES
FREESOURCE = -ffree-form -ffree-line-length-none
F90FLAGS = -g -fconvert=big-endian -fbounds-check -fno-range-check -fallow-argument-mismatch
MODFLAG = -I ../MPP
HYDRO_LIB = ../MPP/mpp_land.o ../MPP/CPL_WRF.o
LDFLAGS =
CPP = cpp
CPPFLAGS = -P -traditional -DMPP_LAND -D_GFORTRAN_ # -DSPATIAL_SOIL
LIBS =
LIBJASPER = -L/usr -ljasper -L/usr/lib/x86_64-linux-gnu -ljpeg
INCJASPER = -I/usr/include/jasper
NETCDFMOD = -I/usr/include
NETCDFLIB = -L/usr/lib -lnetcdf -lnetcdff
BZIP2 = NO
# BZIP2_INCLUDE = -I/usr/include
# BZIP2_LIB = -L/usr/lib64 -lbz2
RM = rm -f
CC = cc
11 changes: 9 additions & 2 deletions hrldas/configure
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,10 @@
print " 4. Linux ifort compiler MPI \n";
print " 5. Linux gfortran compiler serial \n";
print " 6. Linux gfortran compiler MPI \n";
print " 7. Linux gfortran compiler MPI for Docker container \n";
print " 0. exit only \n";

printf "\nEnter selection [%d-%d] : ",1,6 ;
printf "\nEnter selection [%d-%d] : ",1,7 ;

$response = <STDIN> ;
chop($response);
Expand Down Expand Up @@ -52,7 +53,13 @@
system "cp arch/user_build_options.gfortran.mpi user_build_options";
}

case 7 {
# MPI GFORTRAN for Docker container
system "cp arch/user_build_options.gfortran.mpi.container user_build_options";
}

else {print "no selection $response\n"; last}
}

print "Please reminder to change the software package path in the generated user_build_options file before compiling! \n";
print "The user_build_options file used for compiling source code has been successfully generated. \n";
print "Please check and change the software package path in the generated user_build_options file before compiling! \n";

0 comments on commit edd5781

Please sign in to comment.