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.
Undefined reference to parse_file_C
Moderators: Global Moderator, Moderator
-
- Newbie
- Posts: 12
- Joined: Fri Sep 26, 2014 2:22 am
- License Nr.: 5-1877
-
- Newbie
- Posts: 1
- Joined: Thu Jul 01, 2010 1:09 pm
- Location: Belgique
Re: Undefined reference to parse_file_C
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.
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.