Page 1 of 1

Undefined reference to parse_file_C

Posted: Thu Sep 21, 2017 4:52 am
by mwistey
Compiling VASP 5.4.4 on an Intel Linux cluster, using Intel ifort (IFORT) 17.0.4 20170411 with intelmpi/17.0.4, I get
locproj.f90:(.text+0xa5): undefined reference to `parse_file_C'
locproj.f90:(.text+0xb9): undefined reference to `free_parser_C'
locproj.f90:(.text+0x254): undefined reference to `fill_basis_info_C'
locproj.f90:(.text+0x26d): undefined reference to `free_parser_C'
make[2]: *** [vasp] Error 1

In case anybody else runs into this, it turned out to be a problem in the makefile.include. Specifically, the parser subdirectory was not getting compiled or copied to the build directory. I was using a makefile.include that had been recommended (perhaps for an old cluster or old version of VASP?), which lacked the following:
# For the parser library
CXX_PARS = icpc
LIBS += parser
LLIBS += -Lparser -lparser -lstdc++

Please reply below if this saves you a headache. It would be nice to feel like it wasn't a total waste.

Re: Undefined reference to parse_file_C

Posted: Thu Nov 23, 2017 11:19 am
by kseb@averell.umh.ac.be
Hello,

for the same error I added the following line on the end of makefile.include : # For the parser library
CXX_PARS = icpc
LIBS += parser
LLIBS += -Lparser -lparser -lstdc++

And it works.

Thanks,
Sébastien.