Open mkandes opened 1 year ago
Even the v19.1 build from Spack was failing on the some of the features requested by the user. A custom build script was created for the user. This may serve as the starting point for an updated Spack package sometime in the future.
[mkandes@login01 dftbplus]$ pwd
/home/mkandes/software/dftbplus
[mkandes@login01 dftbplus]$ cat build-dftbplus.sh
#!/usr/bin/env bash
#
# A build script to compile DFTB+ (on Expanse).
#
# https://dftbplus.org
# https://github.com/dftbplus
#
# https://access-ci.atlassian.net/browse/ATS-2938
#SBATCH --job-name=build-dftbplus-23.1-20231025
#SBATCH --account=use300
#SBATCH --partition=debug
#SBATCH --nodes=1
#SBATCH --ntasks-per-node=1
#SBATCH --cpus-per-task=2
#SBATCH --mem=4G
#SBATCH --time=00:30:00
#SBATCH --output=%x.o%j.%N
declare -xr COMPILER_MODULE='gcc/10.2.0'
declare -xr CMAKE_MODULE='cmake/3.21.4'
declare -xr LAPACK_MODULE='openblas/0.3.18'
declare -xr ARPACK_MODULE='arpack-ng/3.8.0'
declare -xr DFTBPLUS_VERSION='23.1'
declare -xr DFTBPLUS_ROOT_DIR="${HOME}/software/dftbplus"
declare -xr DFTBPLUS_INSTALL_DIR="${DFTBPLUS_ROOT_DIR}/${DFTBPLUS_VERSION}/${COMPILER_MODULE}/${MPI_MODULE}"
module reset
module load "${COMPILER_MODULE}"
module load "${CMAKE_MODULE}"
module load "${LAPACK_MODULE}"
module load "${ARPACK_MODULE}"
module list
printenv
mkdir -p "${DFTBPLUS_INSTALL_DIR}"
cd "${DFTBPLUS_INSTALL_DIR}"
git clone https://github.com/dftbplus/dftbplus.git
cd dftbplus
git checkout "${DFTBPLUS_VERSION}"
./utils/get_opt_externals ALL
cmake -DCMAKE_INSTALL_PREFIX="${DFTBPLUS_INSTALL_DIR}" \
-DWITH_ARPACK='Y' \
-DWITH_MBD='Y' \
-DWITH_SDFTD3='Y' \
-DWITH_OMP='Y' \
-DWITH_MPI='N' \
-B _build .
cmake --build _build -- -j
cmake --install _build
[mkandes@login01 dftbplus]$
Note, however, the latest version of the dftbplus Spack package only supports up to dftbplus v19.1, which is quite old now. Moreover, the newer versions of dftbplus have changed their build options and dependencies quite a bit since v19.1, such as eliminating use of the dftd3 library, which this user requested, but now may have equivalent support via a new internal implementation. As such, some significant changes and/or updates to the Spack package are required to support the latest versions of dftbplus.