Scheduled Downtime
On Friday 21 April 2023 @ 5pm MT, this website will be down for maintenance and expected to return online the morning of 24 April 2023 at the latest

Compiling WPS4.6.0 cannot generate ungrib.exe

liu lr

New member
I used the same method as before to compile the old version of WPS, but there were errors
make[1]: ftn: No such file or directory
make[1]: [Makefile:76: int2nc.exe] Error 127 (ignored)
make[1]: Leaving directory '/public/home/MS24/liulr/wrf4.6/WPS-4.6.0/util/src'
 

Attachments

  • log.compile.txt
    101 KB · Views: 5
Hi,
When you built WPS, did you use the option to have the GRIB2 libraries built internally? If not, can you give that a try? See step 4 under the Configure WPS section in this WRF Users' Guide section.
Hi, I still can't generate ungreb.exe after trying it your way. but I found that after . /configure it is clear that I chose 19 (Linux x86_64, Intel oneAPI compilers (dmpar)), but after that it shows that I'm using the gnu compiler, it shows as follows
Enter selection [1-44] : 19
------------------------------------------------------------------------
Configuration successful. To build the WPS, type: compile
------------------------------------------------------------------------
*** Failed to compile the gnu_flag_test program!
This may be because the selected build option does not work correctly.

Is there any other good solution to this problem?
 
Okay, so you tried to configure using the "configure --build-grid2-libs" option, and then recompiled and ungrib was still not created?

Regardless of which compiler you're using, you will still need a working gfortran since much of the code is written for that. I would also recommend NOT using a dmpar option for compiling WPS. Even if you compiled WRF with a dmpar option, you can compile WPS with a serial option, and that should work fine. You would only need a dmpar option if you planned to have very large domains (e.g., 1000s by 1000s of grid cells).
 
Okay, so you tried to configure using the "configure --build-grid2-libs" option, and then recompiled and ungrib was still not created?

Regardless of which compiler you're using, you will still need a working gfortran since much of the code is written for that. I would also recommend NOT using a dmpar option for compiling WPS. Even if you compiled WRF with a dmpar option, you can compile WPS with a serial option, and that should work fine. You would only need a dmpar option if you planned to have very large domains (e.g., 1000s by 1000s of grid cells).
Yes, I tried . /configure --build-grid2-libs and still can't generate ungrib.exe. i think it's still a compiler mismatch problem, i use intel compiler but it always defaults to gnu compiler, so i choose 4 after . /configure , it generated ungrib.exe, but with the following error. But I still want to select intel compiler for compilation, how do I convert it?
module_date_pack.o: In function `date_pack_mp_split_date_char_':
module_date_pack.f90:(.text+0x2406): undefined reference to `for_read_int_fmt'
module_date_pack.f90:(.text+0x2441): undefined reference to `for_read_int_fmt'
module_date_pack.f90:(.text+0x247c): undefined reference to `for_read_int_fmt'
module_date_pack.f90:(.text+0x24ba): undefined reference to `for_read_int_fmt'
module_date_pack.f90:(.text+0x24f8): undefined reference to `for_read_int_fmt'
module_date_pack.o:module_date_pack.f90:(.text+0x2541): more undefined references to `for_read_int_fmt' follow
collect2: error: ld returned 1 exit status
make[1]: [Makefile:85: height_ukmo.exe] Error 1 (ignored)
make[1]: Leaving directory '/public/home/MS24/liuc/wrf/4.6/WPS-4.6.0/util/src'
if [ -h height_ukmo.exe ] ; then \
/bin/rm -f height_ukmo.exe ; \
fi ; \
if [ -h ../height_ukmo.exe ] ; then \
/bin/rm -f ../height_ukmo.exe ; \
fi ; \
if [ -e src/height_ukmo.exe ] ; then \
ln -sf src/height_ukmo.exe . ; \
fi
( cd src ; \
if [ "" = yes ] ; then \
WRF_DIR2=/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1 ; \
else \
WRF_DIR2=/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1 ; \
fi ; \
make -i -r int2nc.exe \
WRF_DIR="$WRF_DIR2" \
FC="mpif90 " \
CC="mpicc" \
CPP="/usr/bin/cpp -P -traditional" \
FFLAGS="-ffree-form -O -fconvert=big-endian -frecord-marker=4" \
CFLAGS="" \
LDFLAGS="" \
CPPFLAGS="-D_UNDERSCORE -DBYTESWAP -DLINUX -DIO_NETCDF -DBIT32 -DNO_SIGNAL -D_MPI -D_UTIL" )
make[1]: Entering directory '/public/home/MS24/liuc/wrf/4.6/WPS-4.6.0/util/src'
/bin/rm -f int2nc.f90
/usr/bin/cpp -P -traditional -D_UNDERSCORE -DBYTESWAP -DLINUX -DIO_NETCDF -DBIT32 -DNO_SIGNAL -D_MPI -D_UTIL int2nc.F > int2nc.f90
gfortran -ffree-form -O -fconvert=big-endian -frecord-marker=4 -I/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/external/io_netcdf -I/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/external/io_grib_share -I/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/external/io_grib1 -I/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/external/io_int -I/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/inc -I/public/home/MS24/liuc/tools/netcdf-4.9.2/include -c int2nc.f90
int2nc.f90:15.7:

use module_debug
1
Fatal Error: File 'module_debug.mod' opened at (1) is not a GNU Fortran module file
make[1]: [Makefile:81: int2nc.o] Error 1 (ignored)
gfortran -o int2nc.exe -I/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/external/io_netcdf -I/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/external/io_grib_share -I/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/external/io_grib1 -I/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/external/io_int -I/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/inc -I/public/home/MS24/liuc/tools/netcdf-4.9.2/include int2nc.o module_debug.o misc_definitions_module.o read_met_module.o cio.o -L/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/external/io_grib1 -lio_grib1 -L/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/external/io_grib_share -lio_grib_share -L/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/external/io_int -lwrfio_int -L/public/home/MS24/liuc/wrf/4.6/WRF-4.6.1/external/io_netcdf -lwrfio_nf -L/public/home/MS24/liuc/tools/netcdf-4.9.2/lib -lnetcdff -lnetcdf
gfortran: error: int2nc.o: No such file or directory
make[1]: [Makefile:76: int2nc.exe] Error 1 (ignored)
make[1]: Leaving directory '/public/home/MS24/liuc/wrf/4.6/WPS-4.6.0/util/src'
if [ -h int2nc.exe ] ; then \
/bin/rm -f int2nc.exe ; \
fi ; \
if [ -h ../int2nc.exe ] ; then \
/bin/rm -f ../int2nc.exe ; \
fi ; \
if [ -e src/int2nc.exe ] ; then \
ln -sf src/int2nc.exe . ; \
fi
 
Do you have a path to your intel compiler set? If your system is able to build it with a GNU option, but not with the intel option, it's likely related to your specific environment settings. I would advise speaking to a systems administrator at your institution to see if they can help get your environment set up properly to use intel.
 
Do you have a path to your intel compiler set? If your system is able to build it with a GNU option, but not with the intel option, it's likely related to your specific environment settings. I would advise speaking to a systems administrator at your institution to see if they can help get your environment set up properly to use intel.
Yes, but when I install WRF4.6.0, after configure select 15 and compile successfully, but when I compile WPS4.6.0 after configure no matter select 17 or 19, it shows the following.But my environment configuration only has the intel compiler.
*** Failed to compile the gnu_flag_test program!
This may be because the selected build option does not work correctly.
 
As a workaround for this issue, since you said you were able to build WPS using a gnu option, you can just simply use that WPS build for processing your files, and then it's perfectly fine to use the intel-installed WRF to run real and wrf.

If for some reason, you still need to install WPS with the intel compiler, take a look at this page and try following the instructions exactly to check that all your libraries, compilers, and paths are installed correctly, and so the WPS system can find them.
 
Top