geoschem / geos-chem

GEOS-Chem "Science Codebase" repository. Contains GEOS-Chem science routines, run directory generation scripts, and interface code. This repository is used as a submodule within the GCClassic and GCHP wrappers, as well as in other modeling contexts (external ESMs).
http://geos-chem.org
Other
164 stars 156 forks source link

A very stubborn bug when "make -j",please help me #2458

Open Leonardchenll opened 6 days ago

Leonardchenll commented 6 days ago

Your name

Liliang Chen

Your affiliation

Chinese research academy of Environmental Science

What happened? What did you expect to happen?

This is the result of "cmake" under my build folder

1726062060751

However,every time I run "make -j",It shows

1726062084462

I don't know how to solve the problem cause i am just a beginner.Anyone who know how to correct,I really appreciate it

What are the steps to reproduce the bug?

make -j

Please attach any relevant configuration and log files.

No response

What GEOS-Chem version were you using?

13.4.0

What environment were you running GEOS-Chem on?

Personal computer

What compiler and version were you using?

The Fortran compiler identification is GNU 7.5.0

Will you be addressing this bug yourself?

Yes, but I will need some help

In what configuration were you running GEOS-Chem?

GCClassic

What simulation were you running?

Full chemistry

As what resolution were you running GEOS-Chem?

4x5

What meterology fields did you use?

MERRA-2

Additional information

No response

yantosca commented 6 days ago

Thanks for writing @Leonardchenll. I think that is a compiler error. The best way forward would be to try with a newer version of the GNU compiler (anything higher than 9.3). You can build a newer version with Spack as described on ReadTheDocs:

But before you do that, see if your system has a newer version of the GNU compilers available. If you are using GEOS-Chem on a Mac you may be able to try e.g. brew install gcc, or if you are on a Linux system you can install the GNU compilers with whichever package manager you have

Leonardchenll commented 6 days ago

@yantosca Thanks,however,After I change my gfortran to 10.3.0,It also shows erro like

1726064627882

And the the FailedCompile.txt said Fatal Error: Cannot read module file ‘/usr/include/netcdf.mod’ opened at (1), because it was created by a different version of GNU Fortran compilation terminated. CMakeFiles/cmTC_fbc54.dir/build.make:77: recipe for target 'CMakeFiles/cmTC_fbc54.dir/try_compile.F90.o' failed make[1]: [CMakeFiles/cmTC_fbc54.dir/try_compile.F90.o] Error 1 make[1]: Leaving directory '/home/cll/GC-oper/test-13.4.0/test/build/try_compile/CMakeFiles/CMakeTmp' Makefile:127: recipe for target 'cmTC_fbc54/fast' failed make: [cmTC_fbc54/fast] Error 2 SO,what happened,why I use gun 10.3.0 it goes error and 7.5.0 will not Thank you very much

yantosca commented 5 days ago

Thanks for the feedback @Leonardchenll. The netCDF and netCDF-Fortran libraries have to be created with the same compiler version that you use to compile GEOS-Chem. Do you have a version of netCDF that was built with GNU 10.3.0 compilers? If not then you will have to install them with Spack using the instructions on ReadTheDocs.