Project

General

Profile

Building CDO on CentOS 7 crashes

Added by Nicolas Strike over 4 years ago

The Issue

Hello, I am attempting to build and install CDO so I can convert a number of grads files over to netcdf. However, each time I attempt to build CDO it crashes with the following output:


libtool: link: g++ -std=gnu++11 -g -O2 -fopenmp -o cdo cdo-cdo.o cdo-Adisit.o cdo-Afterburner.o cdo-Arith.o cdo-Arithc.o cdo-Arithdays.o cdo-Arithlat.o cdo-CDItest.o cdo-CDIread.o cdo-CDIwrite.o cdo-Cat.o cdo-Change.o cdo-Change_e5slm.o cdo-Cloudlayer.o cdo-CMOR.o cdo-CMOR_lite.o cdo-CMOR_table.o cdo-Collgrid.o cdo-Command.o cdo-Comp.o cdo-Compc.o cdo-Complextorect.o cdo-Cond.o cdo-Cond2.o cdo-Condc.o cdo-Consecstat.o cdo-Copy.o cdo-Deltat.o cdo-Deltime.o cdo-Derivepar.o cdo-Detrend.o cdo-Diff.o cdo-Distgrid.o cdo-Duplicate.o cdo-EOFs.o cdo-Eof3d.o cdo-EcaIndices.o cdo-Echam5ini.o cdo-Enlarge.o cdo-Enlargegrid.o cdo-Ensstat.o cdo-Ensstat3.o cdo-Ensval.o cdo-Eofcoeff.o cdo-Eofcoeff3d.o cdo-EstFreq.o cdo-Exprf.o cdo-FC.o cdo-Filedes.o cdo-Fillmiss.o cdo-Filter.o cdo-Fldrms.o cdo-Fldstat.o cdo-Fldstat2.o cdo-Fourier.o cdo-Gengrid.o cdo-Gradsdes.o cdo-Gridboxstat.o cdo-Gridcell.o cdo-Gridsearch.o cdo-Harmonic.o cdo-Hi.o cdo-Histogram.o cdo-Importamsr.o cdo-Importbinary.o cdo-Importcmsaf.o cdo-Importobs.o cdo-Importfv3grid.o cdo-Info.o cdo-Input.o cdo-Intgrid.o cdo-Intgridtraj.o cdo-Intlevel.o cdo-Intlevel3d.o cdo-Intntime.o cdo-Inttime.o cdo-Intyear.o cdo-Invert.o cdo-Invertlev.o cdo-Isosurface.o cdo-Lic.o cdo-MapReduce.o cdo-Maskbox.o cdo-Mastrfu.o cdo-Math.o cdo-Merge.o cdo-Mergegrid.o cdo-Mergetime.o cdo-Merstat.o cdo-Monarith.o cdo-Mrotuv.o cdo-Mrotuvb.o cdo-NCL_wind.o cdo-Ninfo.o cdo-Nmldump.o cdo-Output.o cdo-Outputgmt.o cdo-Pack.o cdo-Pardup.o cdo-Pinfo.o cdo-Pressure.o cdo-Recttocomplex.o cdo-Regres.o cdo-Remap.o cdo-Remapweights.o cdo-Remapeta.o cdo-Replace.o cdo-Replacevalues.o cdo-Rhopot.o cdo-Rotuv.o cdo-Runpctl.o cdo-Runstat.o cdo-Samplegrid.o cdo-Samplegridicon.o cdo-Seascount.o cdo-Seaspctl.o cdo-Seasstat.o cdo-Selbox.o cdo-Selgridcell.o cdo-Select.o cdo-Selmulti.o cdo-Seloperator.o cdo-Selrec.o cdo-Seltime.o cdo-Selvar.o cdo-Selyearidx.o cdo-Set.o cdo-Setattribute.o cdo-Setbox.o cdo-Setgatt.o cdo-Setgrid.o cdo-Sethalo.o cdo-Setmiss.o cdo-Setpartab.o cdo-Setrcaname.o cdo-Settime.o cdo-Setzaxis.o cdo-Shiftxy.o cdo-Showinfo.o cdo-Showattribute.o cdo-Sinfo.o cdo-Smooth.o cdo-Sort.o cdo-Sorttimestamp.o cdo-Specinfo.o cdo-Spectral.o cdo-Spectrum.o cdo-Split.o cdo-Splitrec.o cdo-Splitsel.o cdo-Splittime.o cdo-Splityear.o cdo-Subtrend.o cdo-Tee.o cdo-Templates.o cdo-Test.o cdo-Tests.o cdo-Timcount.o cdo-Timcumsum.o cdo-Timpctl.o cdo-Timselpctl.o cdo-Timselstat.o cdo-Timsort.o cdo-Timstat.o cdo-Timstat2.o cdo-Timstat3.o cdo-Tinfo.o cdo-Tocomplex.o cdo-Transpose.o cdo-Trend.o cdo-Tstepcount.o cdo-Unpack.o cdo-Vargen.o cdo-Varrms.o cdo-Varsstat.o cdo-Vertintml.o cdo-Vertintap.o cdo-Vertstat.o cdo-Vertcum.o cdo-Vertwind.o cdo-Verifygrid.o cdo-Wct.o cdo-Wind.o cdo-WindTrans.o cdo-Writegrid.o cdo-Writerandom.o cdo-XTimstat.o cdo-Yearmonstat.o cdo-Ydayarith.o cdo-Ydaypctl.o cdo-Ydaystat.o cdo-Ydrunpctl.o cdo-Ydrunstat.o cdo-Yhourarith.o cdo-Yhourstat.o cdo-Ymonarith.o cdo-Ymonpctl.o cdo-Ymonstat.o cdo-Yseaspctl.o cdo-Yseasstat.o cdo-Zonstat.o cdo-Magplot.o cdo-Magvector.o cdo-Maggraph.o cdo-template_parser.o cdo-results_template_parser.o cdo-magics_template_parser.o cdo-StringUtilities.o cdo-CdoMagicsMapper.o  ./.libs/libcdo.a ../libcdi/src/.libs/libcdi.a ../src/lib/yac/.libs/libyac.a ../src/lib/gradsdes/.libs/libgradsdes.a ../src/lib/ncl/.libs/libncl.a -lm -pthread -fopenmp
../src/lib/ncl/.libs/libncl.a(rvdv.o): In function `dvrfidf_':
rvdv.f:(.text+0x11b): undefined reference to `__f95_error_message_and_abort'
rvdv.f:(.text+0x1da): undefined reference to `__f95_error_message_and_abort'
rvdv.f:(.text+0x299): undefined reference to `__f95_error_message_and_abort'
rvdv.f:(.text+0x358): undefined reference to `__f95_error_message_and_abort'
rvdv.f:(.text+0x417): undefined reference to `__f95_error_message_and_abort'
../src/lib/ncl/.libs/libncl.a(rvdv.o):rvdv.f:(.text+0x193b): more undefined references to `__f95_error_message_and_abort' follow
collect2: error: ld returned 1 exit status
make[1]: *** [cdo] Error 1
make[1]: Leaving directory `/home/strike/cdo-1.9.7.1/src'
make: *** [check-recursive] Error 1

Is anyone able to tell me why this is failing? I've tested it on 3 different computers with similar setups, just different versions of the same software packages.

Some info about my setup:

OS: CentOS 7
NetCDF: Installed and enabled. Tested with version 4.6.1, 4.4.4, 4.7.0
HDF5: Installed and enabled. Tested with version 1.10.5
gcc: 4.8.5

Steps I took:

  1. Download and unzip the cdo tar
  2. enter cdo-1.9.7.1 folder
  3. run
    ./configure --with-netcdf=/usr/local/NETCDF-4.X.X
  4. run
    make check
  5. output listed above is reached (after a few minutes)

I have also attached what I believe to be relevant log/config files.


Replies (5)

RE: Building CDO on CentOS 7 crashes - Added by Nicolas Strike over 4 years ago

Correction, I ran the ./configure with hdf5 passed in as well.

./configure --with-netcdf=/usr/local/NETCDF-4.X.X --with-hdf5=/usr/local/HDF-1.10.5

RE: Building CDO on CentOS 7 crashes - Added by Nicolas Strike over 4 years ago

It looks like someone reported a similar issue here: https://code.mpimet.mpg.de/issues/8959

RE: Building CDO on CentOS 7 crashes - Added by Ralf Mueller over 4 years ago

the error points to Fortran, so I checked the Fortran compiler used during the build: it's /opt/oracle/developerstudio12.5/bin/f90. Please use gfortran if possible by adding

FC=gfortran F77=gfortran
to your configure call.

hth
ralf

RE: Building CDO on CentOS 7 crashes - Added by Nicolas Strike over 4 years ago

I ran

./configure --with-netcdf=/usr/local/NETCDF-C.4.7.0-gfortran --with-hdf5=/usr/local/HDF-1.10.5-gfortran FC=gfortran F77=gfortran

and attempted another
make check
, but it failed on the same error message. Fortunately yesterday I was able to get CDO to work by
booting up an Ubuntu VM and installing it on there (took about 20min to install ubuntu, cdo, and all the dependancies), so I don't particularly need to resolve
this issue anymore, but I wanted to record my findings from the command above.

RE: Building CDO on CentOS 7 crashes - Added by Ralf Mueller over 4 years ago

Hi Nic!

just as a side note - there are several other options to use cdo without building it yourself

For an automatic build from the source I can recommend Spack.

cheers
ralf

    (1-5/5)