diff --git a/easybuild/easyconfigs/d/Dice/Dice-20240101-foss-2022b.eb b/easybuild/easyconfigs/d/Dice/Dice-20240101-foss-2022b.eb new file mode 100644 index 00000000000..201cdb4bf25 --- /dev/null +++ b/easybuild/easyconfigs/d/Dice/Dice-20240101-foss-2022b.eb @@ -0,0 +1,52 @@ +easyblock = 'MakeCp' + +name = 'Dice' +version = '20240101' +_commit = '823f303719efaee441b8bea3e5f9d5a159b58939' + +homepage = 'https://github.com/sanshar/Dice' +description = """Dice contains code for performing SHCI, VMC, GFMC, DMC, FCIQMC, stochastic MRCI +and SC-NEVPT2, and AFQMC calculations with a focus on ab initio systems.""" + +toolchain = {'name': 'foss', 'version': '2022b'} +toolchainopts = {'cstd': 'c++14'} + +github_account = 'sanshar' +source_urls = [GITHUB_SOURCE] +sources = [{'download_filename': '%s.tar.gz' % _commit, 'filename': SOURCE_TAR_GZ}] +patches = ['Dice-20221025_icpt-mkl-to-flexiblas.patch', 'Dice-20240101_deprecated-global-placeholders.patch'] +checksums = [ + {'Dice-20240101.tar.gz': 'f7a60c0df1ba1d27e60b478a15f9ef0e5282a030cc5acc520470eef4f55940b9'}, + {'Dice-20221025_icpt-mkl-to-flexiblas.patch': 'a712913e5b372017be0ea7508479094e96f06c0cfd46d0bfe61d85ef42cd1386'}, + {'Dice-20240101_deprecated-global-placeholders.patch': + 'fbf4037e928a57e737faed95dc7d6e1e5cdb8cee8db48503268d250a34c12ccc'}, +] + +builddependencies = [ + ('Eigen', '3.4.0'), + ('git', '2.38.1', '-nodocs'), +] + +dependencies = [ + ('Boost.MPI', '1.81.0'), + ('HDF5', '1.14.0'), +] + +# Use build environment defined by EB +prebuildopts = "sed -i 's/^FLAGS_BASE =.*/FLAGS_BASE=$(CXXFLAGS) -g -w -I. $(CPPFLAGS)/' Makefile && " +buildopts = 'CXX="$MPICXX" USE_INTEL="no" HAS_AVX2="no" ' # avoid changes to -march +buildopts += 'INCLUDE_MKL="-I${EBROOTFLEXIBLAS}/include" LIB_MKL="${LIBBLAS}" ' # use FlexiBLAS +buildopts += 'GIT_BRANCH="master" GIT_HASH="%s"' % _commit +buildopts += 'BOOST="${EBROOTBOOSTMPI}" ' +buildopts += 'EIGEN="${EBROOTEIGEN}/include" ' +buildopts += 'HDF5="${EBROOTHDF5}" ' + +files_to_copy = ['bin'] + +_binaries = ['Dice', 'DQMC', 'GFMC', 'ICPT', 'VMC', 'ZDice2', 'ZSHCI'] +sanity_check_paths = { + 'files': ['bin/%s' % x for x in _binaries], + 'dirs': [], +} + +moduleclass = 'chem' diff --git a/easybuild/easyconfigs/d/Dice/Dice-20240101_deprecated-global-placeholders.patch b/easybuild/easyconfigs/d/Dice/Dice-20240101_deprecated-global-placeholders.patch new file mode 100644 index 00000000000..9a474df63c3 --- /dev/null +++ b/easybuild/easyconfigs/d/Dice/Dice-20240101_deprecated-global-placeholders.patch @@ -0,0 +1,49 @@ +resolve Error: "pragma message: The practice of declaring the Bind placeholders (_1, _2, ...) in the global namespace is deprecated. Please use + using namespace boost::placeholders, or define BOOST_BIND_GLOBAL_PLACEHOLDERS to retain the current behavior." +define BOOST_BIND_GLOBAL_PLACEHOLDERS +replace #include with #include +diff -ru Dice.orig/ZSHCI/Hmult.h Dice/ZSHCI/Hmult.h +--- Dice.orig/ZSHCI/Hmult.h 2024-01-11 17:10:03.915355000 +0100 ++++ Dice/ZSHCI/Hmult.h 2024-01-11 17:20:04.223600142 +0100 +@@ -32,6 +32,7 @@ + #include + #include "SHCISortMpiUtils.h" + #include "SHCImake4cHamiltonian.h" ++#define BOOST_BIND_GLOBAL_PLACEHOLDERS + + using namespace Eigen; + using namespace std; +diff -ru Dice.orig/ZSHCI/iowrapper.h Dice/ZSHCI/iowrapper.h +--- Dice.orig/ZSHCI/iowrapper.h 2024-01-11 17:10:03.926065371 +0100 ++++ Dice/ZSHCI/iowrapper.h 2024-01-11 17:50:17.289606580 +0100 +@@ -18,6 +18,7 @@ + */ + #ifndef IOWRAPPER_HEADER_H + #define IOWRAPPER_HEADER_H ++#define BOOST_BIND_GLOBAL_PLACEHOLDERS + #include + #include + #include +diff -ru Dice.orig/ZSHCI/SHCI.cpp Dice/ZSHCI/SHCI.cpp +--- Dice.orig/ZSHCI/SHCI.cpp 2024-01-11 17:10:03.917251803 +0100 ++++ Dice/ZSHCI/SHCI.cpp 2024-01-11 17:19:30.845898274 +0100 +@@ -59,7 +59,7 @@ + #include "symmetry.h" + MatrixXd symmetry::product_table; + #include +-#include ++#include + + // Initialize + using namespace Eigen; +diff -ru Dice.orig/ZSHCI/symmetry.cpp Dice/ZSHCI/symmetry.cpp +--- Dice.orig/ZSHCI/symmetry.cpp 2024-01-11 17:10:03.927561000 +0100 ++++ Dice/ZSHCI/symmetry.cpp 2024-01-11 17:38:01.888632035 +0100 +@@ -25,7 +25,7 @@ + #include + #include + #include +-#include ++#include + #include + + #include "integral.h"