Reputation: 314
I'm trying to compile a Quantum ESPRESSO code with some other packages. After playing around with the Makefile and compiling flags a bit, I "obtained" an error as below. Is there any way to get around this? Am I missing any flag to avoid the error? Or does it come from the code itself?
$ mpif90 -fdollar-ok -ffree-line-length-none -O3 -fopenmp -fPIC -I ../../../qe/6.0-mpi/Modules -I ../src -I ../src ../../../qe/6.0-mpi/PW/src/libpw.a ../../../qe/6.0-mpi/Modules/libqemod.a ../../../qe/6.0-mpi/FFTXlib/libqefft.a ../../../qe/6.0-mpi/LAXlib/libqela.a -Wall -c qevars.f90
Warning: qevars.f90:30: Illegal preprocessor directive
Warning: qevars.f90:32: Illegal preprocessor directive
Warning: qevars.f90:34: Illegal preprocessor directive
Warning: qevars.f90:56: Illegal preprocessor directive
Warning: qevars.f90:58: Illegal preprocessor directive
Warning: qevars.f90:60: Illegal preprocessor directive
Warning: qevars.f90:68: Illegal preprocessor directive
Warning: qevars.f90:70: Illegal preprocessor directive
Warning: qevars.f90:72: Illegal preprocessor directive
Warning: qevars.f90:74: Illegal preprocessor directive
Warning: qevars.f90:75: Illegal preprocessor directive
Warning: qevars.f90:77: Illegal preprocessor directive
qevars.f90:33:43:
use io_files, ONLY : nd_nmbr, prefix, outdir, tmp_dir, nwordwfc, iunwfc
1
Error: Symbol ‘outdir’ referenced at (1) not found in module ‘io_files’
qevars.f90:73:43:
use wvfct, ONLY : npw, npwx, nbnd, igk, g2kin, wg, et, ecutwfc
1
Error: Symbol ‘igk’ referenced at (1) not found in module ‘wvfct’
qevars.f90:73:63:
use wvfct, ONLY : npw, npwx, nbnd, igk, g2kin, wg, et, ecutwfc
1
Error: Symbol ‘ecutwfc’ referenced at (1) not found in module ‘wvfct’
qevars.f90:71:43:
use wvfct, ONLY : npw, npwx, nbnd, igk, g2kin, wg, et
1
Error: Symbol ‘igk’ referenced at (1) not found in module ‘wvfct’
Upvotes: 1
Views: 1269
Reputation: 59999
Error messages and warnings like
Warning: qevars.f90:30: Illegal preprocessor directive
are normally cased by Fortran code containing preprocessor directives but not preprocessed by the preprocessor. In gfortran use -cpp
to enable the preprocessor or use file extensions with capital F (.F
, .F90
).
The lack of preprocessing can cause many following errors being reported.
Upvotes: 2