Page 1 of 1

Make error with gnu

Posted: Tue Sep 09, 2014 9:38 pm
by burkzdemir
Dear all,

I have successfully compiled yambo, however I get an error during make. Here is the result of the compilation;

#
# [VER] 3.4.1 r.3187
#
# [SYS] linux@x86_64
# [SRC] /home/burak/yambo-3.4.1
# [BIN] /home/burak/yambo-3.4.1/bin
# [FFT] Goedecker Fast Fourier transform with 0 cache
#
# [ ] Double precision
# [X] Redundant compilation
# [X] MPI
# [ ] OpenMP
# [X] PW (5.0) support
# [ ] ETSF I/O support
# [ ] SCALAPACK
# [ ] NETCDF/HDF5/Large Files
# [XX ] Built-in BLAS/LAPACK/LOCAL
#
# [ CPP ] gcc -E -P
# [ C ] gcc -g -O2 -D_C_US -D_FORTRAN_US
# [MPICC] mpicc -g -O2 -D_C_US -D_FORTRAN_US
# [ F90 ] gfortran -O3 -mtune=native
# [MPIF ] mpif90 -O3 -mtune=native
# [ F77 ] gfortran -O3 -mtune=native
# [Cmain]
# [NoOpt] -O0 -mtune=native
#
# [ MAKE ] make
# [EDITOR] vim
#

And the error I got during make is;

Fatal Error: File 'xc_f90_lib_m.mod' opened at (1) is not a GFORTRAN module file

Best,

Re: Make error with gnu

Posted: Tue Sep 09, 2014 9:50 pm
by Daniele Varsano
Dear Burak,
it looks you are mixing compilers. You can try to do a

Code: Select all

make clean_all
and then reconfigure the code assuring that your mpicc and mpif09 points to a gfortran compiler (you can see it by typing (mpif90/mpicc -v).
If you want to use the intel compilers this setting is working to me:

Code: Select all

#!/bin/bash
export MKL_LIB=$MKLROOT/lib/intel64
export CC=icc
export CXX=icpc
export F77=ifort
export F90=ifort
export PFC=mpiifort
export CFLAGS=-O3
export FFLAGS=" -O2 -assume buffered_io,byterecl"
export FFLAGS_NOOPT=" -O0 -assume buffered_io,byterecl"
./configure \
  --with-p2y=5.0 --with-iotk=/s3_home/varsano/codes/espresso-5.0.2/iotk \
  --with-blas="-L/$MKL_LIB -lmkl_intel_lp64  -lmkl_sequential -lmkl_core" \
  --with-lapack="-L/$MKL_LIB -lmkl_intel_lp64  -lmkl_sequential -lmkl_core" \
  --with-fftw=/s3_home/varsano/fftw-3.3.4/lib \
  --with-fftw-lib=/s3_home/varsano/fftw-3.3.4/lib/libfftw3.a \
  --with-netcdf-lib=/s3_home/varsano/netcdf/lib \
  --with-netcdf-include=/s3_home/varsano/netcdf/include \
  --with-netcdf-link=-lnetcdf \
  --enable-time-profile \
  --enable-msgs-comp
of course, modify the paths to your library and skip the libs you are not interested in.
You can try to set the precompiler as CPP="icc -E -ansi".
In any case, when having compilation problem, please post the config.log file.

Best,
Daniele

Re: Make error with gnu

Posted: Tue Sep 09, 2014 10:04 pm
by burkzdemir
I included 'mpif90=gfortran mpicc=gcc' in my configure command and problem solved! Many thanks!

Best,

Re: Make error with gnu

Posted: Tue Sep 09, 2014 10:07 pm
by Daniele Varsano
OK, but in this way yambo will run in serial mode only.
Check if

Code: Select all

# [X] MPI 
is marked at the end of the configure process.
Best,
Daniele