The following makefile.include was supplied to me, which was used for an existing installation of vasp 6.2.0 without hdf5 support. I am trying to modify it to recompile vasp with hdf5 support, in order to be able to use py4vasp.
# Precompiler options
CPP_OPTIONS= -DHOST=\"LinuxIFC\"\
-DMPI -DMPI_BLOCK=8000 -Duse_collective \
-DscaLAPACK \
-DCACHE_SIZE=4000 \
-Davoidalloc \
-Dvasp6 \
-Duse_bse_te \
-Dtbdyn \
-Dfock_dblbuf
CPP = fpp -f_com=no -free -w0 $*$(FUFFIX) $*$(SUFFIX) $(CPP_OPTIONS)
FC = mpiifort
FCL = mpiifort -mkl=sequential
FREE = -free -names lowercase
FFLAGS = -assume byterecl -w -xHOST
OFLAG = -O2
OFLAG_IN = $(OFLAG)
DEBUG = -O0
MKL_PATH = $(MKLROOT)/lib/intel64
BLAS =
LAPACK =
BLACS = -lmkl_blacs_intelmpi_lp64
SCALAPACK = $(MKL_PATH)/libmkl_scalapack_lp64.a $(BLACS)
OBJECTS = fftmpiw.o fftmpi_map.o fft3dlib.o fftw3d.o
INCS =-I$(MKLROOT)/include/fftw
LLIBS = $(SCALAPACK) $(LAPACK) $(BLAS)
OBJECTS_O1 += 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
FREE_LIB = $(FREE)
OBJECTS_LIB= linpack_double.o getshmem.o
# For the parser library
CXX_PARS = icpc
LLIBS += -lstdc++
# Normally no need to change this
SRCDIR = ../../src
BINDIR = ../../bin
#================================================
# GPU Stuff
CPP_GPU = -DCUDA_GPU -DRPROMU_CPROJ_OVERLAP -DUSE_PINNED_MEMORY -DCUFFT_MIN=28 -UscaLAPACK -Ufock_dblbuf
OBJECTS_GPU= fftmpiw.o fftmpi_map.o fft3dlib.o fftw3d_gpu.o fftmpiw_gpu.o
CC = icc
CXX = icpc
CFLAGS = -fPIC -DADD_ -Wall -qopenmp -DMAGMA_WITH_MKL -DMAGMA_SETAFFINITY -DGPUSHMEM=300 -DHAVE_CUBLAS
# Minimal requirement is CUDA >= 10.X. For "sm_80" you need CUDA >= 11.X.
CUDA_ROOT ?= /usr/local/cuda/
NVCC := $(CUDA_ROOT)/bin/nvcc -ccbin=icc -allow-unsupported-compiler
CUDA_LIB := -L$(CUDA_ROOT)/lib64 -lnvToolsExt -lcudart -lcuda -lcufft -lcublas
GENCODE_ARCH := -gencode=arch=compute_60,code=\"sm_60,compute_60\" \
-gencode=arch=compute_70,code=\"sm_70,compute_70\" \
-gencode=arch=compute_80,code=\"sm_80,compute_80\"
## For all legacy Intel MPI versions (before 2021)
#MPI_INC = $(I_MPI_ROOT)/intel64/include/
# Or when you are using the Intel oneAPI compiler suite
MPI_INC = $(I_MPI_ROOT)/include/
I appended these lines as explained in [1]
#Needed for py4vasp
CPP_OPTIONS+= -DVASP_HDF5
HDF5_ROOT ?= /home/myname/hdf/HDF5-1.12.1-Linux/HDF_Group/HDF5/1.12.1
LLIBS += -L$(HDF5_ROOT)/lib -lhdf5_fortran
INCS += -I$(HDF5_ROOT)/include
Adding these lines caused the following errors
:: initializing oneAPI environment ...
slurm_script: BASH_VERSION = 5.1.4(1)-release
:: advisor -- latest
:: ccl -- latest
:: clck -- latest
:: compiler -- latest
:: dal -- latest
:: debugger -- latest
:: dev-utilities -- latest
:: dnnl -- latest
:: dpcpp-ct -- latest
:: dpl -- latest
:: inspector -- latest
:: intelpython -- latest
:: ipp -- latest
:: ippcp -- latest
:: ipp -- latest
:: itac -- latest
:: mkl -- latest
:: mpi -- latest
:: tbb -- latest
:: vpl -- latest
:: vtune -- latest
:: oneAPI environment initialized ::
if [ ! -d build/std ] ; then mkdir build/std ; fi;
cp src/makefile src/.objects src/makedeps.awk makefile.include build/std ;
make -C build/std VERSION=std cleandependencies -j1
make[1]: Entering directory '/home/myname/vasp.6.2.0/build/std'
rm -f .depend
make[1]: Leaving directory '/home/myname/vasp.6.2.0/build/std'
make -C build/std VERSION=std all
make[1]: Entering directory '/home/myname/vasp.6.2.0/build/std'
rsync -ru ../../src/lib .
cp makefile.include lib
make -C lib -j1
make[2]: Entering directory '/home/myname/vasp.6.2.0/build/std/lib'
make libdmy.a
make[3]: Entering directory '/home/myname/vasp.6.2.0/build/std/lib'
make[3]: 'libdmy.a' is up to date.
make[3]: Leaving directory '/home/myname/vasp.6.2.0/build/std/lib'
make[2]: Leaving directory '/home/myname/vasp.6.2.0/build/std/lib'
rsync -ru ../../src/parser .
cp makefile.include parser
make -C parser -j1
make[2]: Entering directory '/home/myname/vasp.6.2.0/build/std/parser'
make libparser.a
make[3]: Entering directory '/home/myname/vasp.6.2.0/build/std/parser'
make[3]: 'libparser.a' is up to date.
make[3]: Leaving directory '/home/myname/vasp.6.2.0/build/std/parser'
make[2]: Leaving directory '/home/myname/vasp.6.2.0/build/std/parser'
rsync -u ../../src/*.F ../../src/*.inc .
rm -f vasp ; make vasp ; cp vasp ../../bin/vasp_std
make[2]: Entering directory '/home/myname/vasp.6.2.0/build/std'
mpiifort -free -names lowercase -assume byterecl -w -xHOST -O2 -I/home/software/materia/intel_lib/mkl/2021.4.0/include/fftw -I/home/myname/hdf/HDF5-1.12.1-Linux/HDF_Group/HDF5/1.12.1/include -c vhdf5_base.f90
vhdf5_base.F(6): error #7002: Error in opening the compiled module file. Check INCLUDE paths. [HDF5]
use hdf5
------^
vhdf5_base.F(36): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5intermediategroup_id
----------^
vhdf5_base.F(37): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5infileid
----------^
vhdf5_base.F(38): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5outfileid
----------^
vhdf5_base.F(39): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5wavefileid
----------^
vhdf5_base.F(40): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5ininputgroup_id
----------^
vhdf5_base.F(41): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5outinputgroup_id
----------^
vhdf5_base.F(42): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5outoriginalgroup_id
----------^
vhdf5_base.F(57): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T) :: create_inter_prop
----------^
vhdf5_base.F(204): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(218): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(232): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(247): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(263): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(274): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(316): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: fileid
------------^
vhdf5_base.F(344): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.F(346): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: groupid
------------^
vhdf5_base.F(357): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: groupid
------------^
vhdf5_base.F(370): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.F(372): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: groupid
------------^
vhdf5_base.F(387): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.F(389): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: groupid
------------^
vhdf5_base.F(410): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: groupid
------------^
vhdf5_base.F(426): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.F(451): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: groupid
------------^
vhdf5_base.F(457): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T) :: dset_id, attr_id, aspace, string_type
------------^
vhdf5_base.F(458): error #6683: A kind type parameter must be a compile-time constant. [HSIZE_T]
integer(HSIZE_T) :: dimensions(1)
------------^
vhdf5_base.F(459): error #6683: A kind type parameter must be a compile-time constant. [HSIZE_T]
integer(HSIZE_T) :: strlen
------------^
vhdf5_base.F(500): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.f90(2776): catastrophic error: Too many errors, exiting
compilation aborted for vhdf5_base.f90 (code 1)
make[2]: *** [makefile:181: vhdf5_base.o] Error 1
make[2]: Leaving directory '/home/myname/vasp.6.2.0/build/std'
cp: cannot stat 'vasp': No such file or directory
make[1]: *** [makefile:146: all] Error 1
make[1]: Leaving directory '/home/myname/vasp.6.2.0/build/std'
make: *** [makefile:9: std] Error 2
I am using a virtual machine Linux #1 SMP Debian 5.10.140-1 (2022-09-02), where I installed hdf5-1.12.1-Std-ubuntu2010_64.tar.gz from [2].
[1]: https://www.vasp.at/wiki/index.php/Makefile.include#HDF5_support_.28strongly_recommended.29) [2]: https://support.hdfgroup.org/ftp/HDF5/releases/hdf5-1.12/hdf5-1.12.1/bin/unix/
EDIT: Now I have tried building HDF5 from source rather than using the binary file, following these steps:
gunzip < hdf5-1.14.0.tar.gz | tar xf -
cd hdf5-1.14.0
./configure --enable-fortran --enable-cxx
make
make check # run test suite.
make install
make check-install # verify installation
After updating the HDF5_ROOT in vasp makefile.include, now the compiling job returns the following errors:
:: initializing oneAPI environment ...
slurm_script: BASH_VERSION = 5.1.4(1)-release
:: advisor -- latest
:: ccl -- latest
:: clck -- latest
:: compiler -- latest
:: dal -- latest
:: debugger -- latest
:: dev-utilities -- latest
:: dnnl -- latest
:: dpcpp-ct -- latest
:: dpl -- latest
:: inspector -- latest
:: intelpython -- latest
:: ipp -- latest
:: ippcp -- latest
:: ipp -- latest
:: itac -- latest
:: mkl -- latest
:: mpi -- latest
:: tbb -- latest
:: vpl -- latest
:: vtune -- latest
:: oneAPI environment initialized ::
if [ ! -d build/std ] ; then mkdir build/std ; fi;
cp src/makefile src/.objects src/makedeps.awk makefile.include build/std ;
make -C build/std VERSION=std cleandependencies -j1
make[1]: Entering directory '/home/myname/vasp.6.2.0/build/std'
rm -f .depend
make[1]: Leaving directory '/home/myname/vasp.6.2.0/build/std'
make -C build/std VERSION=std all
make[1]: Entering directory '/home/myname/vasp.6.2.0/build/std'
rsync -ru ../../src/lib .
cp makefile.include lib
make -C lib -j1
make[2]: Entering directory '/home/myname/vasp.6.2.0/build/std/lib'
make libdmy.a
make[3]: Entering directory '/home/myname/vasp.6.2.0/build/std/lib'
make[3]: 'libdmy.a' is up to date.
make[3]: Leaving directory '/home/myname/vasp.6.2.0/build/std/lib'
make[2]: Leaving directory '/home/myname/vasp.6.2.0/build/std/lib'
rsync -ru ../../src/parser .
cp makefile.include parser
make -C parser -j1
make[2]: Entering directory '/home/myname/vasp.6.2.0/build/std/parser'
make libparser.a
make[3]: Entering directory '/home/myname/vasp.6.2.0/build/std/parser'
make[3]: 'libparser.a' is up to date.
make[3]: Leaving directory '/home/myname/vasp.6.2.0/build/std/parser'
make[2]: Leaving directory '/home/myname/vasp.6.2.0/build/std/parser'
rsync -u ../../src/*.F ../../src/*.inc .
rm -f vasp ; make vasp ; cp vasp ../../bin/vasp_std
make[2]: Entering directory '/home/myname/vasp.6.2.0/build/std'
mpiifort -free -names lowercase -assume byterecl -w -xHOST -O2 -I/home/software/materia/intel_lib/mkl/2021.4.0/include/fftw -I/home/myname/hdf5-1.14.0/hdf5/include -c vhdf5_base.f90
vhdf5_base.F(6): error #7013: This module file was not generated by any release of this compiler. [HDF5]
use hdf5
------^
vhdf5_base.F(36): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5intermediategroup_id
----------^
vhdf5_base.F(37): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5infileid
----------^
vhdf5_base.F(38): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5outfileid
----------^
vhdf5_base.F(39): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5wavefileid
----------^
vhdf5_base.F(40): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5ininputgroup_id
----------^
vhdf5_base.F(41): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5outinputgroup_id
----------^
vhdf5_base.F(42): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5outoriginalgroup_id
----------^
vhdf5_base.F(57): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T) :: create_inter_prop
----------^
vhdf5_base.F(204): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(218): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(232): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(247): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(263): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(274): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(316): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: fileid
------------^
vhdf5_base.F(344): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.F(346): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: groupid
------------^
vhdf5_base.F(357): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: groupid
------------^
vhdf5_base.F(370): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.F(372): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: groupid
------------^
vhdf5_base.F(387): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.F(389): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: groupid
------------^
vhdf5_base.F(410): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: groupid
------------^
vhdf5_base.F(426): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.F(451): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: groupid
------------^
vhdf5_base.F(457): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T) :: dset_id, attr_id, aspace, string_type
------------^
vhdf5_base.F(458): error #6683: A kind type parameter must be a compile-time constant. [HSIZE_T]
integer(HSIZE_T) :: dimensions(1)
------------^
vhdf5_base.F(459): error #6683: A kind type parameter must be a compile-time constant. [HSIZE_T]
integer(HSIZE_T) :: strlen
------------^
vhdf5_base.F(500): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.f90(2776): catastrophic error: Too many errors, exiting
compilation aborted for vhdf5_base.f90 (code 1)
make[2]: *** [makefile:181: vhdf5_base.o] Error 1
make[2]: Leaving directory '/home/myname/vasp.6.2.0/build/std'
cp: cannot stat 'vasp': No such file or directory
make[1]: *** [makefile:146: all] Error 1
make[1]: Leaving directory '/home/myname/vasp.6.2.0/build/std'
make: *** [makefile:9: std] Error 2
EDIT2: Following @IanBush 's suggestion I have recompiled HDF5 with
CXX=icpc CC=icc FC=ifort ./configure --enable-fortran --enable-cxx; make -j 4
make check
make install
make check-install
but again when compiling vasp I obtained errors about the include path (I have checked that the directory HDF5_ROOT ?= /home/myname/hdf5-1.14.0/hdf5 actually contains include folder)
if [ ! -d build/std ] ; then mkdir build/std ; fi;
cp src/makefile src/.objects src/makedeps.awk makefile.include build/std ;
make -C build/std VERSION=std cleandependencies -j1
make[1]: Entering directory '/home/myname/vasp.6.2.0/build/std'
rm -f .depend
make[1]: Leaving directory '/home/myname/vasp.6.2.0/build/std'
make -C build/std VERSION=std all
make[1]: Entering directory '/home/myname/vasp.6.2.0/build/std'
rsync -ru ../../src/lib .
cp makefile.include lib
make -C lib -j1
make[2]: Entering directory '/home/myname/vasp.6.2.0/build/std/lib'
make libdmy.a
make[3]: Entering directory '/home/myname/vasp.6.2.0/build/std/lib'
make[3]: 'libdmy.a' is up to date.
make[3]: Leaving directory '/home/myname/vasp.6.2.0/build/std/lib'
make[2]: Leaving directory '/home/myname/vasp.6.2.0/build/std/lib'
rsync -ru ../../src/parser .
cp makefile.include parser
make -C parser -j1
make[2]: Entering directory '/home/myname/vasp.6.2.0/build/std/parser'
make libparser.a
make[3]: Entering directory '/home/myname/vasp.6.2.0/build/std/parser'
make[3]: 'libparser.a' is up to date.
make[3]: Leaving directory '/home/myname/vasp.6.2.0/build/std/parser'
make[2]: Leaving directory '/home/myname/vasp.6.2.0/build/std/parser'
rsync -u ../../src/*.F ../../src/*.inc .
rm -f vasp ; make vasp ; cp vasp ../../bin/vasp_std
make[2]: Entering directory '/home/myname/vasp.6.2.0/build/std'
mpiifort -free -names lowercase -assume byterecl -w -xHOST -O2 -I/home/software/materia/intel_lib/mkl/2021.4.0/include/fftw -I/home/myname/hdf5-1.14.0/hdf5/include -c vhdf5_base.f90
vhdf5_base.F(6): error #7002: Error in opening the compiled module file. Check INCLUDE paths. [HDF5]
use hdf5
------^
vhdf5_base.F(36): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5intermediategroup_id
----------^
vhdf5_base.F(37): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5infileid
----------^
vhdf5_base.F(38): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5outfileid
----------^
vhdf5_base.F(39): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5wavefileid
----------^
vhdf5_base.F(40): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5ininputgroup_id
----------^
vhdf5_base.F(41): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5outinputgroup_id
----------^
vhdf5_base.F(42): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T):: ih5outoriginalgroup_id
----------^
vhdf5_base.F(57): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T) :: create_inter_prop
----------^
vhdf5_base.F(204): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(218): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(232): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(247): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(263): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(274): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: fileid
------------^
vhdf5_base.F(316): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: fileid
------------^
vhdf5_base.F(344): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.F(346): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: groupid
------------^
vhdf5_base.F(357): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: groupid
------------^
vhdf5_base.F(370): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.F(372): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: groupid
------------^
vhdf5_base.F(387): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.F(389): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(out) :: groupid
------------^
vhdf5_base.F(410): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: groupid
------------^
vhdf5_base.F(426): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.F(451): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: groupid
------------^
vhdf5_base.F(457): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T) :: dset_id, attr_id, aspace, string_type
------------^
vhdf5_base.F(458): error #6683: A kind type parameter must be a compile-time constant. [HSIZE_T]
integer(HSIZE_T) :: dimensions(1)
------------^
vhdf5_base.F(459): error #6683: A kind type parameter must be a compile-time constant. [HSIZE_T]
integer(HSIZE_T) :: strlen
------------^
vhdf5_base.F(500): error #6683: A kind type parameter must be a compile-time constant. [HID_T]
integer(HID_T), intent(in) :: locid
------------^
vhdf5_base.f90(2776): catastrophic error: Too many errors, exiting
compilation aborted for vhdf5_base.f90 (code 1)
make[2]: *** [makefile:181: vhdf5_base.o] Error 1
make[2]: Leaving directory '/home/myname/vasp.6.2.0/build/std'
cp: cannot stat 'vasp': No such file or directory
make[1]: *** [makefile:146: all] Error 1
make[1]: Leaving directory '/home/myname/vasp.6.2.0/build/std'
make: *** [makefile:9: std] Error 2
```
module load hdf5
before doing the compiling, because HDF5 is already instaslled as a module. $\endgroup$CC=icc FC=ifort ./configure --enable-fortran --enable-cxx
$\endgroup$CXX=icpc CC=icc FC=ifort ./configure --enable-fortran --enable-cxx; make -j 4
successfully builds hdf5-1.14.0 with the Intel compiler and provides an hdf5.mod that the Intel compiler can use. I can't test against VASP as I don't have access to the source code, hence a comment rather than an answer, butmake check
passes all tests. $\endgroup$