Tested on (Requirements)
OS base: CentOS (x86_64) \(\boldsymbol{\ge}\) 6.6
Compiler: GCC \(\boldsymbol{\ge}\) 7.4.
Requirements:
CHARM++ \(\boldsymbol{\ge}\) 6.8.2 with GCC 7.4.
CUDA 10.1 (Optional).
Build process
Download NAMD from the official website, you should create an account and agree the license term.
Decompress the tar file.
tar xfz NAMD_2.13_Source.tar.gz cd NAMD_2.13_Source
Compile CHARM++.
Charm++ [1] is a parallel object-oriented programming language based on C++ and developed in the Parallel Programming Laboratory at the University of Illinois at Urbana–Champaign. Charm++ is designed with the goal of enhancing programmer productivity by providing a high-level abstraction of a parallel program while at the same time delivering good performance on a wide variety of underlying hardware platforms.
Decompress it (the namd source files contains the needed source files of CHARM).
tar xf charm-6.8.2.tar cd charm-6.8.2
Compile it. The command structure is
build <target> <version> <options> [charmc-options ...]
## To compile NAMD with CUDA ./build charm++ multicore-linux-x86_64 smp gcc --with-production ## To compile NAMD with MPI ./build charm++ mpi-linux-x86_64 mpicxx gcc --with-production
Configure the compilation.
## To compile NAMD with CUDA ./config Linux-x86_64-g++ --charm-arch multicore-linux-x86_64 --with-cuda --cuda-prefix /path/to/cuda/10.1/ ## To compile NAMD with MPI ./config Linux-x86_64-g++ --charm-arch mpi-linux-x86_64-mpicxx
Compile NAMD.
cd Linux-x86_64-g++ make -j 4
Module files
NAMD with CUDA
#%Module1.0#################################################################### ## ## module load namd/2.13-gcc_CUDA ## ## /share/apps/modules/namd/2.13-gcc_CUDA ## Written by Manuela Carrasco Pinzon ## proc ModulesHelp {} { global version modroot puts stderr "Sets the environment for using NAMD 2.13 with CUDA\ \nin the shared directory /share/apps/namd/2.13/2.13-gcc_CUDA\ \nbuilded with GCC 7.4 and CUDA 10.1" } module-whatis "(Name________) namd" module-whatis "(Version_____) 2.13-gcc_CUDA" module-whatis "(Compilers___) gcc 7.4 and cuda 10.1" module-whatis "(System______) x86_64-redhat-linux" module-whatis "(Libraries___) " # for Tcl script use only set topdir /share/apps/namd/2.13/2.13-gcc_CUDA/ set version 2.13-gcc_CUDA set sys x86_64-redhat-linux conflict mafft module load gcc/7.4.0 module load cuda/10.1 prepend-path PATH $topdir/bin
NAMD with MPI
#%Module1.0#################################################################### ## ## module load namd/2.13-gcc_MPI ## ## /share/apps/modules/namd/2.13-gcc_MPI ## Written by Manuela Carrasco Pinzon ## proc ModulesHelp {} { global version modroot puts stderr "Sets the environment for using NAMD 2.13 with MPI\ \nin the shared directory /share/apps/namd/2.13/2.13-gcc_MPI\ \nbuilded with GCC 7.4 and OpenMPI 1.10.7" } module-whatis "(Name________) namd" module-whatis "(Version_____) 2.13-gcc_MPI" module-whatis "(Compilers___) gcc 7.4 and OpenMPI 1.10.7" module-whatis "(System______) x86_64-redhat-linux" module-whatis "(Libraries___) " # for Tcl script use only set topdir /share/apps/namd/2.13/2.13-gcc_MPI/ set version 2.13-gcc_MPI set sys x86_64-redhat-linux conflict mafft module load gcc/5.4.0 module load openmpi/1.10.7_gcc-5.4.0 prepend-path PATH $topdir/bin