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

Convert_MPAS

This post was from a previous version of the WRF&MPAS-A Support Forum. New replies have been disabled and if you have follow up questions related to this post, then please start a new thread from the forum home page.

The default flags should work for the GNU Fortran compiler, but you may be able to get slightly better runtime performance with the following:
Code:
-Ofast -ffree-form -Wall -DHAVE_NF90_INQ_VARIDS
 
Hello,

I am still having trouble installing convert_MPAS. Any further suggestions?
I have tried with both the default flags and the ones you suggested with the same result.

"Fatal Error: Cannot read module file ‘netcdf.mod’ opened at (1), because it was created by a different version of GNU Fortran"

#
#

I have since checked and tried to edit the FC as well (gfortran, f77, F77):

(py24) epekema> gfortran --version

GNU Fortran (GCC) 8.3.1 20191121 (Red Hat 8.3.1-5)
Copyright (C) 2018 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

#
#

I have also found the "missing" mod and tried to include it in the Makefile

FC = gfortran -I/opt/conda/include/
FFLAGS = -O2 -ffree-form -Wall -DHAVE_NF90_INQ_VARIDS


Thanks as always,
Zach
 

Attachments

  • make.log.rtf
    1.4 KB · Views: 30
  • Makefile.rtf
    1.5 KB · Views: 30
I think this error message in your compilation log is the important part:
Code:
gfortran -O2 -ffree-form -Wall -DHAVE_NF90_INQ_VARIDS -c scan_input.F -I/home/kahi/zmenzo/.conda/envs/py24/include -I/home/kahi/zmenzo/.conda/envs/py24/include
scan_input.F:3:8:

     use netcdf
        1
Fatal Error: Cannot read module file ‘netcdf.mod’ opened at (1), because it was created by a different version of GNU Fortran

My guess would be that the NetCDF library provided by your conda environment (/home/kahi/zmenzo/.conda/envs/py24) was compiled with a different version of the GNU compilers from that being used to build the convert_mpas utility.

If you've installed the NetCDF library using the gcc and gfortran compilers in your path, can you check that the nc-config utility from that installation (perhaps in $NETCDF/bin) is in your path first?
 
Top