Serial installation error vasp-5.4.4

Questions regarding the compilation of VASP on various platforms: hardware, compilers and libraries, etc.


Moderators: Global Moderator, Moderator

Locked
Message
Author
vahid_askarpour
Newbie
Newbie
Posts: 23
Joined: Tue Jan 31, 2023 3:11 pm

Serial installation error vasp-5.4.4

#1 Post by vahid_askarpour » Wed Oct 18, 2023 10:41 pm

I have compiled VASP in parallel and it works fine. I need to compile the serial version as well. However, I get the following error while making the ncl variant:

Code: Select all

ifort -free -names lowercase -assume byterecl -w -O2 -I/cvmfs/soft.computecanada.ca/easybuild/software/2020/Core/imkl/2020.1.217/mkl/include/fftw -c mlwf.f90
mlwf.F(811): error #6460: This is not a field name that is defined in the encompassing structure.   [NCPU]
      IF (WRITE_SPN .AND. WDES%COMM%NCPU.NE.1) THEN
------------------------------------^
compilation aborted for mlwf.f90 (code 1)
make[2]: *** [makefile:169: mlwf.o] Error 1
make[2]: Leaving directory '/home/vaskarpo/bin/VASP5_serial/src/vasp.5.4.4/build/ncl'
cp: cannot stat 'vasp': No such file or directory
make[1]: *** [makefile:142: all] Error 1
make[1]: Leaving directory '/home/vaskarpo/bin/VASP5_serial/src/vasp.5.4.4/build/ncl'
make: *** [makefile:10: ncl] Error 2

The makefile.include is

Code: Select all

# Precompiler options
CPP_OPTIONS= -DHOST=\"LinuxIFC\"\
             -DCACHE_SIZE=4000 \
             -Davoidalloc \
             -Duse_bse_te \
             -Dtbdyn \
	     -DVASP2WANNIER90v2 


CPP        = fpp -f_com=no -free -w0  $*$(FUFFIX) $*$(SUFFIX) $(CPP_OPTIONS)

FC         = ifort
FCL        = ifort -mkl

FREE       = -free -names lowercase

FFLAGS     = -assume byterecl -w
OFLAG      = -O2
OFLAG_IN   = $(OFLAG)
DEBUG      = -O0

MKL_PATH   = $(MKLROOT)/lib/intel64
BLAS       =
LAPACK     = $(MKL_PATH)/libmkl_intel_lp64.a
BLACS      = 
SCALAPACK  = $(BLACS)

OBJECTS    = fft3dfurth.o fft3dlib.o 

INCS       =-I$(MKLROOT)/include/fftw

LLIBS      = $(SCALAPACK) $(LAPACK) $(BLAS) ~/bin/wannier90-2.1.0/libwannier.a


OBJECTS_O1 += fft3dfurth.o fftw3d.o fftmpi.o fftmpiw.o
OBJECTS_O2 += fft3dlib.o

# For what used to be vasp.5.lib
CPP_LIB    = $(CPP)
FC_LIB     = $(FC)
CC_LIB     = icc
CFLAGS_LIB = -O
FFLAGS_LIB = -O1 -FI
FREE_LIB   = -FR

OBJECTS_LIB= linpack_double.o 

# For the parser library
CXX_PARS   = icpc

LIBS       += parser
LLIBS      += -Lparser -lparser -lstdc++

# Normally no need to change this
SRCDIR     = ../../src
BINDIR     = ../../bin
Any suggestions would be greatly appreciated.

Thanks,
Vahid

martin.schlipf
Global Moderator
Global Moderator
Posts: 542
Joined: Fri Nov 08, 2019 7:18 am

Re: Serial installation error vasp-5.4.4

#2 Post by martin.schlipf » Thu Oct 19, 2023 12:36 pm

I don't know where you got your source code from but this line is not present in the version of 5.4.4. It should be easy enough to fix because the number of CPUs should be 1 in the serial case.

Martin Schlipf
VASP developer


vahid_askarpour
Newbie
Newbie
Posts: 23
Joined: Tue Jan 31, 2023 3:11 pm

Re: Serial installation error vasp-5.4.4

#3 Post by vahid_askarpour » Thu Oct 19, 2023 3:29 pm

The source code is VASP's but I added a patch called mlwf.patch from https://github.com/Chengcheng-Xiao/VASP ... x/tree/dev in order to fix the VASP2WANNIER90v2 interface issues.

I will try to fix the error since it seems to be not serious.

Thanks,
Vahid

martin.schlipf
Global Moderator
Global Moderator
Posts: 542
Joined: Fri Nov 08, 2019 7:18 am

Re: Serial installation error vasp-5.4.4

#4 Post by martin.schlipf » Fri Oct 20, 2023 6:10 am

While in general we cannot provide support for fixes that are applied on top of VASP, in this specific case it seems easy enough to just change it to

Code: Select all

#ifdef MPI
      IF (WRITE_SPN .AND. WDES%COMM%NCPU.NE.1) THEN
         IF (IO%IU0>=0) WRITE(*,*) 'MLWF_WANNIER90: WRITE_SPN only works in serial, skipping.'
         WRITE_SPN=.FALSE.
      ENDIF
#endif
By the way, why do you need the serial version of VASP? In principle, you can run the MPI version also on a single core so I would be interested to know about the specific use case.

Martin Schlipf
VASP developer


Locked