- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Dear Everyone,
I'm using intel compiler 2018 and installing NETCDF-C-4.8.1 and NETCDF-F.4.5.2. I set CC=mpiicc FC=mpiifort F77=mpiifort F90=mpiifort. And I successfully built and generated the netcdf.mod file. However, the first line of netcdf.mod shows that GFORTRAN module version '10' created from netcdf4.f90. And this leads a downstream software using mpiifort fail to link the netcdf.mod. My question is, why does mpiifort generate a netcdf.mod with GFORTRAN module version? Thanks!
Wish you good,
RyanOcean
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
mpiifort does not create gfortran mod files by default. Something in the NETCDF build system must be in error.
If you can capture the make with VERBOSE perhaps it will show the issue. For example, if mpiifort is given a bad argument like
mpiifort -fc=gfortran
is one way mpiifort can call gfortran instead of ifort. you may try
export FC='mpiifort -fc=ifort'
same for F90, F77.
what I am telling you is this: the default for mpiifort is to use ifort. It can invoke gfortran if FC is set incorrectly to gfortran. You'll have to dig around to find where their build is running amok
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
mpiifort does not create gfortran mod files by default. Something in the NETCDF build system must be in error.
If you can capture the make with VERBOSE perhaps it will show the issue. For example, if mpiifort is given a bad argument like
mpiifort -fc=gfortran
is one way mpiifort can call gfortran instead of ifort. you may try
export FC='mpiifort -fc=ifort'
same for F90, F77.
what I am telling you is this: the default for mpiifort is to use ifort. It can invoke gfortran if FC is set incorrectly to gfortran. You'll have to dig around to find where their build is running amok
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Many thanks. I find that export FC='mpiifort -fc=ifort' really works, although I don't find some clues that claim to use gfortran wrapper for mpiifort in the configure file. And I get a *.mod with intel compiler now. Thanks again!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
It is possible that the Gfortran .mod file was generated by using make, which used Gfortran as the Fortran compiler according to its implicit rules for .f90 source files. That make procedure may have failed in a step after the production of the .mod file, and failing to find a rule for deleting such files (possibly as part of make clean), would leave behind the mod file. That mod file could become a nuisance later.
In other words, the mere presence of a module file does not justify the claim "I successfully built and generated the netcdf.mod file".
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Many thanks! I understand your ideas. After export FC='mpiifort -fc=ifort', I got a *.mod file with intel compiler.
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page