Skip to main content

Build your own VASP 6

For VASP 6.X.X version, VASP provide several templates of makefile.include, which contain information such as precompiler options, compiler options, and how to link libraries. You can pick up one based on your system and preferred features . Here we provide some examples about how to install vasp 6.3.0 on Anvil with different module environments. We also prepared two versions of VASP6 installation scripts at the end of this page.

Link to section 'Step 1: Download' of 'Build your own VASP 6' Step 1: Download

As a license holder, you can download the source code of VASP from the VASP Portal, we will not check your license in this case.

Copy the VASP resource file vasp.6.3.0.tgz to the desired location, and unzip the file tar zxvf vasp.6.3.0.tgz to obtain the folder /path/to/vasp-build-folder/vasp.6.3.0 and reveal its content.

Link to section 'Step 2: Prepare makefile.include' of 'Build your own VASP 6' Step 2: Prepare makefile.include

  • For GNU compilers parallelized using OpenMPI + OpenMP, combined with MKL

    We modified the makefile.include.gnu_ompi_mkl_omp file to adapt the Anvil system. Download it to your VASP build folder /path/to/vasp-build-folder/vasp.6.3.0:

    $ cd /path/to/vasp-build-folder/vasp.6.3.0
    $ wget https://www.rcac.purdue.edu/files/knowledge/compile/src/makefile.include.gnu_ompi_mkl_omp
    $ cp makefile.include.gnu_ompi_mkl_omp makefile.include

    If you would like to include the Wannier90 interface, you may also need to include the following lines to the end of your makefile.include file:

    # For the VASP-2-Wannier90 interface (optional)
    CPP_OPTIONS    += -DVASP2WANNIER90
    WANNIER90_ROOT ?=$(WANNIER90_HOME)
    LLIBS          += -L$(WANNIER90_ROOT) -lwannier

    Then, load the required modules:

    $ module purge 
    $ module load gcc/11.2.0  openmpi/4.1.6
    $ module load intel-mkl hdf5 
    # If you would like to include the Wannier90 interface, also load the following module:
    # $ module load wannier90/3.1.0
  • For Intel compilers parallelized using IMPI + OpenMP, combined with MKL

    We modified the makefile.include.intel_omp file to adapt the Anvil system. Download it to your VASP build folder /path/to/vasp-build-folder/vasp.6.3.0:

    $ cd /path/to/vasp-build-folder/vasp.6.3.0
    $ wget https://www.rcac.purdue.edu/files/knowledge/compile/src/makefile.include.intel_omp
    $ cp makefile.include.intel_omp makefile.include

    If you would like to include the Wannier90 interface, you may also need to include the following lines to the end of your makefile.include file:

    # For the VASP-2-Wannier90 interface (optional)
    CPP_OPTIONS    += -DVASP2WANNIER90
    WANNIER90_ROOT ?=$(WANNIER90_HOME)
    LLIBS          += -L$(WANNIER90_ROOT) -lwannier

    Then, load the required modules:

    $ module purge 
    $ module load intel/19.0.5.281  impi/2019.5.281
    $ module load intel-mkl hdf5 
    # If you would like to include the Wannier90 interface, also load the following module:
    # $ module load wannier90/3.1.0

Link to section 'Step 3: Make' of 'Build your own VASP 6' Step 3: Make

Open makefile, make sure the first line is VERSIONS = std gam ncl.

Build VASP with command make all to install all three executables vasp_std, vasp_gam, and vasp_ncl or use make std to install only the vasp_std executable. Use make veryclean to remove the build folder if you would like to start over the installation process.

Link to section 'Step 4: Test' of 'Build your own VASP 6' Step 4: Test

You can open an Interactive session to test the installed VASP 6. Here is an example of testing above installed VASP 6.3.0 with GNU compilers and OpenMPI:

$ cd /path/to/vasp-build-folder/vasp.6.3.0/testsuite
$ module purge 
$ module load gcc/11.2.0 openmpi/4.1.6 intel-mkl hdf5
# If you included the Wannier90 interface, also load the following module:
# $ module load wannier90/3.1.0
$ ./runtest

Link to section ' ' of 'Build your own VASP 6'  

Helpful?

Thanks for letting us know.

Please don't include any personal information in your comment. Maximum character limit is 250.
Characters left: 250
Thanks for your feedback.