merge hdf5 bugfix

This commit is contained in:
James McClure 2021-11-03 12:39:59 -04:00
commit b9cb8504f6
6 changed files with 16 additions and 13 deletions

View File

@ -14,7 +14,6 @@ MESSAGE("====================")
SET( PROJ LBPM ) # Set the project name for CMake
SET( LBPM_LIB lbpm-wia ) # Set the final library name
SET( LBPM_INC ) # Set an optional subfolder for includes (e.g. include/name/...)
SET( TEST_MAX_PROCS 16 )
# Initialize the project
@ -149,6 +148,7 @@ ENDIF()
IF ( NOT ONLY_BUILD_DOCS )
CONFIGURE_MPI() # MPI must be before other libraries
CONFIGURE_MIC()
CONFIGURE_HDF5()
CONFIGURE_NETCDF()
CONFIGURE_SILO()
CONFIGURE_LBPM()

View File

@ -274,7 +274,7 @@ std::vector<IO::MeshDatabase> writeMeshesHDF5( const std::vector<IO::MeshDataStr
std::vector<IO::MeshDatabase> writeMeshesHDF5(
const std::vector<IO::MeshDataStruct> &, const std::string &, IO::FileFormat, int )
const std::vector<IO::MeshDataStruct> &, const std::string &, IO::FileFormat, int, Xdmf & )
{
return std::vector<IO::MeshDatabase>();
}

View File

@ -245,7 +245,9 @@ std::vector<IO::MeshDatabase> writeMeshesSilo(
{
return std::vector<IO::MeshDatabase>();
}
void writeSiloSummary( const std::vector<IO::MeshDatabase> &, const std::string & );
void writeSiloSummary( const std::vector<IO::MeshDatabase> &, const std::string & )
{
}
#endif

View File

@ -22,9 +22,6 @@
struct LBPM_Point {
LBPM_Point() : x(0.0), y(0.0), z(0.0) {}
LBPM_Point(double xv,double yv,double zv) : x(xv), y(yv), z(zv) {}
LBPM_Point(const LBPM_Point& rhs): x(rhs.x), y(rhs.y), z(rhs.z) {}
//Point& operator=(const Point& rhs) { this->x=rhs.x; this->y=rhs.y; this->z=rhs.z; return *this; }
//~Point() {}
double x,y,z;
};
typedef LBPM_Point Point;

View File

@ -103,12 +103,12 @@ ENDMACRO()
# Macro to find and configure hdf5
MACRO ( CONFIGURE_HDF5 )
CHECK_ENABLE_FLAG( USE_HDF5 0 )
IF ( USE_HDF5 )
# Check if we specified the silo directory
IF ( USE_HDF5 AND NOT FOUND_HDF5 )
# Check if we specified the hdf5 directory
IF ( HDF5_DIRECTORY )
VERIFY_PATH ( ${HDF5_DIRECTORY} )
INCLUDE_DIRECTORIES ( ${HDF5_DIRECTORY}/include )
SET ( HDF5_INCLUDE ${HDF5_DIRECTORY}/include )
SET( HDF5_INCLUDE ${HDF5_DIRECTORY}/include )
FIND_LIBRARY ( HDF5_LIB NAMES hdf5 PATHS ${HDF5_DIRECTORY}/lib NO_DEFAULT_PATH )
FIND_LIBRARY ( HDF5_HL_LIB NAMES hdf5_hl PATHS ${HDF5_DIRECTORY}/lib NO_DEFAULT_PATH )
ELSE()
@ -118,6 +118,8 @@ MACRO ( CONFIGURE_HDF5 )
${HDF5_HL_LIB}
${HDF5_LIB}
)
SET( FOUND_HDF5 TRUE )
SET( EXTERNAL_LIBS ${HDF5_LIBS} ${EXTERNAL_LIBS} )
ADD_DEFINITIONS ( -DUSE_HDF5 )
MESSAGE( "Using hdf5" )
MESSAGE( " ${HDF5_LIB}" )
@ -151,7 +153,7 @@ MACRO( CONFIGURE_NETCDF )
ELSE()
MESSAGE( FATAL_ERROR "Default search for netcdf is not yet supported. Use -D NETCDF_DIRECTORY=" )
ENDIF()
SET( EXTERNAL_LIBS ${NETCDF_LIBS} ${HDF5_LIBS} ${EXTERNAL_LIBS} )
SET( EXTERNAL_LIBS ${NETCDF_LIBS} ${EXTERNAL_LIBS} )
ADD_DEFINITIONS ( -DUSE_NETCDF )
MESSAGE( "Using netcdf" )
MESSAGE( " ${NETCDF_LIBS}" )
@ -179,7 +181,7 @@ MACRO ( CONFIGURE_SILO )
SET ( SILO_LIBS
${SILO_LIB}
)
SET( EXTERNAL_LIBS ${SILO_LIBS} ${HDF5_LIBS} ${EXTERNAL_LIBS} )
SET( EXTERNAL_LIBS ${SILO_LIBS} ${EXTERNAL_LIBS} )
ADD_DEFINITIONS ( -DUSE_SILO )
MESSAGE( "Using silo" )
MESSAGE( " ${SILO_LIB}" )
@ -261,7 +263,7 @@ ENDMACRO ()
# Macro to configure LBPM specific options
MACRO ( CONFIGURE_LBPM )
# Set the maximum number of processors for the tests
IF ( NOT TEST_MAX_PROCS )
IF ( NOT DEFINED TEST_MAX_PROCS )
SET( TEST_MAX_PROCS 32 )
ENDIF()
# Add the correct paths to rpath in case we build shared libraries

View File

@ -102,8 +102,10 @@ ADD_LBPM_TEST( TestColorSquareTube ../example/Bubble/input.db)
#ADD_LBPM_TEST_1_2_4( TestColorSquareTube ../example/Bubble/input.db)
SET_TESTS_PROPERTIES( hello_world PROPERTIES ENVIRONMENT "MPICH_RDMA_ENABLED_CUDA=0")
IF ( USE_MPI )
IF ( USE_MPI AND TEST_MAX_PROCS GREATER 1 )
SET_TESTS_PROPERTIES( hello_world_2procs PROPERTIES ENVIRONMENT "MPICH_RDMA_ENABLED_CUDA=0")
ENDIF()
IF ( USE_MPI AND TEST_MAX_PROCS GREATER 3 )
SET_TESTS_PROPERTIES( hello_world_4procs PROPERTIES ENVIRONMENT "MPICH_RDMA_ENABLED_CUDA=0")
ENDIF()