mirror of https://github.com/QMCPACK/qmcpack.git
Remove macro HAVE_LIBHDF5
Signed-off-by: Steven Hahn <hahnse@ornl.gov>
This commit is contained in:
parent
9cf7089ada
commit
e0ecc9746e
|
@ -652,8 +652,6 @@ endif()
|
|||
find_package(HDF5 COMPONENTS C)
|
||||
|
||||
if(HDF5_FOUND)
|
||||
set(HAVE_LIBHDF5 1)
|
||||
|
||||
if(HDF5_IS_PARALLEL)
|
||||
message(STATUS "Parallel HDF5 library found")
|
||||
option(ENABLE_PHDF5 "Enable code paths using parallel HDF5" ON)
|
||||
|
@ -692,7 +690,7 @@ if(HDF5_FOUND)
|
|||
|
||||
add_library(IO::HDF5 INTERFACE IMPORTED)
|
||||
target_include_directories(IO::HDF5 INTERFACE "${HDF5_INCLUDE_DIR}")
|
||||
target_compile_definitions(IO::HDF5 INTERFACE "HAVE_LIBHDF5;H5_USE_16_API")
|
||||
target_compile_definitions(IO::HDF5 INTERFACE "H5_USE_16_API")
|
||||
target_link_libraries(IO::HDF5 INTERFACE "${HDF5_LIBRARIES}")
|
||||
if(ENABLE_PHDF5)
|
||||
target_compile_definitions(IO::HDF5 INTERFACE "ENABLE_PHDF5")
|
||||
|
|
|
@ -36,9 +36,6 @@
|
|||
/* Enable OpenMP parallelization. */
|
||||
#define QMC_OMP 1
|
||||
|
||||
/* Define to 1 if you have the `hdf5' library (-lhdf5). */
|
||||
#define HAVE_LIBHDF5 1
|
||||
|
||||
/* Define to 1 if you want to use parallel hdf5 for frequent output */
|
||||
/* #undef ENABLE_PHDF5 */
|
||||
|
||||
|
|
|
@ -16,9 +16,7 @@
|
|||
|
||||
#include "HDFWalkerInputManager.h"
|
||||
#include "OhmmsData/AttributeSet.h"
|
||||
#if defined(HAVE_LIBHDF5)
|
||||
#include "Particle/HDFWalkerInput_0_4.h"
|
||||
#endif
|
||||
#include "Message/Communicate.h"
|
||||
#include "hdf/HDFVersion.h"
|
||||
|
||||
|
@ -28,7 +26,6 @@ HDFWalkerInputManager::HDFWalkerInputManager(WalkerConfigurations& wc_list, size
|
|||
|
||||
HDFWalkerInputManager::~HDFWalkerInputManager() {}
|
||||
|
||||
#if defined(HAVE_LIBHDF5)
|
||||
bool HDFWalkerInputManager::put(xmlNodePtr cur)
|
||||
{
|
||||
//reference revision number
|
||||
|
@ -61,13 +58,4 @@ bool HDFWalkerInputManager::put(xmlNodePtr cur)
|
|||
CurrentFileRoot = cfile;
|
||||
return success;
|
||||
}
|
||||
#else
|
||||
bool HDFWalkerInputManager::put(xmlNodePtr cur) { return false; }
|
||||
#endif
|
||||
|
||||
void HDFWalkerInputManager::rewind(const std::string& h5root, int blocks)
|
||||
{
|
||||
// HDFWalkerInputCollect WO(h5root);
|
||||
// WO.rewind(wc_list_,blocks);
|
||||
}
|
||||
} // namespace qmcplusplus
|
||||
|
|
|
@ -37,8 +37,6 @@ public:
|
|||
//bool put(std::vector<xmlNodePtr>& mset, int pid);
|
||||
//bool put(std::vector<xmlNodePtr>& mset, Communicate* comm);
|
||||
std::string getFileRoot() { return CurrentFileRoot; }
|
||||
|
||||
void rewind(const std::string& h5root, int blocks);
|
||||
};
|
||||
} // namespace qmcplusplus
|
||||
|
||||
|
|
|
@ -661,7 +661,6 @@ bool LCAOrbitalBuilder::putFromXML(LCAOrbitalSet& spo, xmlNodePtr coeff_ptr)
|
|||
*/
|
||||
bool LCAOrbitalBuilder::putFromH5(LCAOrbitalSet& spo, xmlNodePtr coeff_ptr)
|
||||
{
|
||||
#if defined(HAVE_LIBHDF5)
|
||||
int neigs = spo.getBasisSetSize();
|
||||
int setVal = -1;
|
||||
std::string setname;
|
||||
|
@ -723,9 +722,6 @@ bool LCAOrbitalBuilder::putFromH5(LCAOrbitalSet& spo, xmlNodePtr coeff_ptr)
|
|||
}
|
||||
}
|
||||
myComm->bcast(spo.C->data(), spo.C->size());
|
||||
#else
|
||||
APP_ABORT("LCAOrbitalBuilder::putFromH5 HDF5 is disabled.")
|
||||
#endif
|
||||
return true;
|
||||
}
|
||||
|
||||
|
@ -736,7 +732,6 @@ bool LCAOrbitalBuilder::putFromH5(LCAOrbitalSet& spo, xmlNodePtr coeff_ptr)
|
|||
*/
|
||||
bool LCAOrbitalBuilder::putPBCFromH5(LCAOrbitalSet& spo, xmlNodePtr coeff_ptr)
|
||||
{
|
||||
#if defined(HAVE_LIBHDF5)
|
||||
ReportEngine PRE("LCAOrbitalBuilder", "LCAOrbitalBuilder::putPBCFromH5");
|
||||
int norbs = spo.getOrbitalSetSize();
|
||||
int neigs = spo.getBasisSetSize();
|
||||
|
@ -822,10 +817,6 @@ bool LCAOrbitalBuilder::putPBCFromH5(LCAOrbitalSet& spo, xmlNodePtr coeff_ptr)
|
|||
#ifdef HAVE_MPI
|
||||
myComm->comm.broadcast_n(spo.C->data(), spo.C->size());
|
||||
#endif
|
||||
|
||||
#else
|
||||
APP_ABORT("LCAOrbitalBuilder::putFromH5 HDF5 is disabled.")
|
||||
#endif
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
|
@ -17,14 +17,7 @@
|
|||
#ifdef HAVE_CONFIG_H
|
||||
#include "config.h"
|
||||
#endif
|
||||
#if defined(HAVE_LIBHDF5)
|
||||
#include "hdf5.h"
|
||||
#else
|
||||
using hid_t = int;
|
||||
using hsize_t = std::size_t;
|
||||
const int H5P_DEFAULT = 0;
|
||||
#endif
|
||||
|
||||
#include <string>
|
||||
|
||||
|
||||
|
|
|
@ -18,12 +18,9 @@
|
|||
#include "hdf_datatype.h"
|
||||
#include "hdf_dataspace.h"
|
||||
#include "hdf_dataproxy.h"
|
||||
#if defined(HAVE_LIBHDF5)
|
||||
#include "hdf_pete.h"
|
||||
#include "hdf_stl.h"
|
||||
#include "hdf_hyperslab.h"
|
||||
//#include "hdf_double_hyperslab.h"
|
||||
#endif
|
||||
#include <stack>
|
||||
#include <bitset>
|
||||
#ifdef HAVE_MPI
|
||||
|
|
|
@ -14,13 +14,10 @@
|
|||
#define QMCPLUSPLUS_H5DATATYPE_DEFINE_H
|
||||
|
||||
#include <type_traits>
|
||||
#if defined(HAVE_LIBHDF5)
|
||||
#include <hdf5.h>
|
||||
#endif
|
||||
|
||||
namespace qmcplusplus
|
||||
{
|
||||
#if defined(HAVE_LIBHDF5)
|
||||
/** map C types to hdf5 native types
|
||||
* bool is explicit removed due to the fact that it is implementation-dependant
|
||||
*/
|
||||
|
@ -44,24 +41,8 @@ BOOSTSUB_H5_DATATYPE(unsigned short, H5T_NATIVE_USHORT);
|
|||
BOOSTSUB_H5_DATATYPE(unsigned int, H5T_NATIVE_UINT);
|
||||
BOOSTSUB_H5_DATATYPE(unsigned long, H5T_NATIVE_ULONG);
|
||||
BOOSTSUB_H5_DATATYPE(unsigned long long, H5T_NATIVE_ULLONG);
|
||||
//BOOSTSUB_H5_DATATYPE(uint32_t, H5T_NATIVE_UINT32);
|
||||
//BOOSTSUB_H5_DATATYPE(uint64_t, H5T_NATIVE_UINT64);
|
||||
BOOSTSUB_H5_DATATYPE(float, H5T_NATIVE_FLOAT);
|
||||
BOOSTSUB_H5_DATATYPE(double, H5T_NATIVE_DOUBLE);
|
||||
|
||||
#else
|
||||
using hid_t = int;
|
||||
using herr_t = int;
|
||||
using hsize_t = std::size_t;
|
||||
const int H5P_DEFAULT = 0;
|
||||
|
||||
//return a non-sense integer
|
||||
template<typename T>
|
||||
inline hid_t get_h5_datatype(const T&)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
#endif
|
||||
} // namespace qmcplusplus
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue