diff --git a/source/adios2/ADIOS.cpp b/source/adios2/ADIOS.cpp index ac4725a53e4257fe58e1a06bef1e10578db4fb52..b39ebcc397d3ae71718145532630a7b81ee49a84 100644 --- a/source/adios2/ADIOS.cpp +++ b/source/adios2/ADIOS.cpp @@ -194,7 +194,16 @@ std::shared_ptr<Engine> ADIOS::Open(const std::string &name, "HDF5 library, can't use HDF5\n"); #endif } - + else if (type == "HDF5Reader") // -Junmin + { +#if defined(ADIOS_HAVE_PHDF5) && defined(ADIOS_HAVE_MPI) + return std::make_shared<HDF5Reader>(*this, name, accessMode, mpiComm, + method); +#else + throw std::invalid_argument("ERROR: this version didn't compile with " + "HDF5 library, can't use HDF5\n"); +#endif + } else { if (m_DebugMode == true)