Commit ed4f3dc8 authored by miller86's avatar miller86
Browse files

Fixed problems with FindXdmf. It was only third party lib support function

using FIND_PACKAGE and was explicitly setting XDMF_DIR, both of which are
intended to be handled by SET_UP_THIRD_PARTY.

Added ${HDF5_XXX_DIR} refs to Xdmf.xml. Why? The Xdmf plugin doesn't use
HDF5 does it? Yes, thats correct. It does not. However, either we are using
Xdmf lib header files incorrectly or Xdmf lib is itself flawed in this
regard but by virtue of include dependencies, our Xdmf plugin is indeed
including hdf5.h as well as other HDF5 header files. So, the Xdmf plugin
is presently DIRECTLY dependent on HDF5 and therefore needs HDF5 lib
variables in its .xml file.

Note, if the Xdmf plugin was not DIRECTLY dependent on HDF5, and only
indirectly through Xdmf library's use of HDF5 itself, then
VISIT_XDMF_LIBDEP would be the correct way to handle that.

Found and fixed the opposite problem with H5Part. The H5Part plugin is
DIRECTLY dependent on a number of libraries including HDF5, FASTBIT,
SZIP. And, the .xml file for H5Part captures this dependency by
including all the lib INCLUDE_DIR and LIB_DIR variables. However, we
were also defining LIBDEP variable for it in CMakeLists.txt as well
as many config-site files and that is not appropriate for H5Part.




git-svn-id: http://visit.ilight.com/svn/visit/trunk/src@12076 18c085ea-50e0-402c-830e-de6fd14e8384
parent 14effd80
......@@ -38,6 +38,9 @@
# Kathleen Bonnell, Thu May 27 17:01:22 MST 2010
# Windows builds can be handled the same as non-windows for XDMF.
#
# Mark C. Miller, Fri Jul 30 22:06:06 PDT 2010
# Removed logic setting XDMF_DIR (that is done to SET_UP_THIRD_PARTY)
# as well as FIND_PACKAGE (also done by SET_UP_THIRD_PARTY).
#****************************************************************************/
# Use the XDMF_DIR hint from the config-site .cmake file
......@@ -46,6 +49,3 @@
INCLUDE(${VISIT_SOURCE_DIR}/CMake/SetUpThirdParty.cmake)
SET_UP_THIRD_PARTY(XDMF lib include Xdmf vtklibxml2)
SET(XDMF_DIR ${XDMF_LIBRARY_DIR}/XdmfCMake)
FIND_PACKAGE(XDMF QUIET)
......@@ -312,6 +312,11 @@ VISIT_3RDPARTY_VAR(VISIT_TCMALLOC_DIR "Path containing the tcmalloc library's
# Define the options that let us pick I/O library installation locations. When
# the library option is defined then we also define the variable name passed as
# the 3rd argument. That variable is what is used in our various Find routines.
#
# Note: Define LIBDEP ONLY for libs a plugin is INdirectly dependent on (e.g.
# needs to link but not to compile). Use the plugin's .xml file for
# libs a plugin is DIRECTLY dependent on (e.g. needs to both compile
# and link).
VISIT_3RDPARTY_VAR(VISIT_ADIOS_DIR "Path containing the ADIOS library's include and lib" ADIOS_DIR)
VISIT_3RDPARTY_VAR(VISIT_ADVIO_DIR "Path containing the AdvIO library's include and lib" ADVIO_DIR)
VISIT_3RDPARTY_VAR(VISIT_BOXLIB2D_DIR "Path containing the Boxlib 2D library's include and lib" BOXLIB2D_DIR)
......@@ -327,7 +332,6 @@ VISIT_3RDPARTY_DEP(VISIT_HDF4_LIBDEP "HDF4 library dependencies" HDF4_LIBDEP)
VISIT_3RDPARTY_VAR(VISIT_HDF5_DIR "Path containing the HDF5 library's include and lib" HDF5_DIR)
VISIT_3RDPARTY_DEP(VISIT_HDF5_LIBDEP "HDF5 library dependencies" HDF5_LIBDEP)
VISIT_3RDPARTY_VAR(VISIT_H5PART_DIR "Path containing the H5Part library's include and lib" H5PART_DIR)
VISIT_3RDPARTY_DEP(VISIT_H5PART_LIBDEP "H5Part library dependencies" H5PART_LIBDEP)
VISIT_3RDPARTY_VAR(VISIT_MILI_DIR "Path containing the Mili library's include and lib" MILI_DIR)
VISIT_3RDPARTY_VAR(VISIT_NETCDF_DIR "Path containing the NETCDF library's include and lib" NETCDF_DIR)
VISIT_3RDPARTY_VAR(VISIT_SILO_DIR "Path containing the Silo library's include and lib" SILO_DIR)
......
......@@ -113,7 +113,6 @@ VISIT_OPTION_DEFAULT(VISIT_HDF5_LIBDEP ${VISITHOME}/szip/2.1/${VISITARCH}/lib sz
## H5Part
##
VISIT_OPTION_DEFAULT(VISIT_H5PART_DIR ${VISITHOME}/h5part/1.6.0/${VISITARCH})
VISIT_OPTION_DEFAULT(VISIT_H5PART_LIBDEP HDF5_LIBRARY_DIR hdf5 ${VISIT_HDF5_LIBDEP})
##
## Mili
......
......@@ -93,7 +93,6 @@ VISIT_OPTION_DEFAULT(VISIT_HDF5_LIBDEP ${VISITHOME}/szip/2.1/${VISITARCH}/lib sz
## H5Part
##
VISIT_OPTION_DEFAULT(VISIT_H5PART_DIR ${VISITHOME}/h5part/1.6.0/${VISITARCH})
VISIT_OPTION_DEFAULT(VISIT_H5PART_LIBDEP HDF5_LIBRARY_DIR hdf5 ${VISIT_HDF5_IBDEP})
##
## Mili
......
......@@ -100,7 +100,6 @@ VISIT_OPTION_DEFAULT(VISIT_HDF5_LIBDEP ${VISITHOME}/szip/2.1/${VISITARCH}/lib sz
## H5Part
##
VISIT_OPTION_DEFAULT(VISIT_H5PART_DIR ${VISITHOME}/h5part/1.6.0/${VISITARCH})
VISIT_OPTION_DEFAULT(VISIT_H5PART_LIBDEP HDF5_LIBRARY_DIR hdf5 ${VISIT_HDF5_LIBDEP})
##
## Mili
......
......@@ -92,7 +92,6 @@ VISIT_OPTION_DEFAULT(VISIT_HDF5_LIBDEP ${VISITHOME}/szip/2.1/${VISITARCH}/lib sz
## H5Part
##
VISIT_OPTION_DEFAULT(VISIT_H5PART_DIR ${VISITHOME}/h5part/1.6.0/${VISITARCH})
VISIT_OPTION_DEFAULT(VISIT_H5PART_LIBDEP HDF5_LIBRARY_DIR hdf5 ${VISIT_HDF5_LIBDEP})
##
## Mili
......
......@@ -116,7 +116,6 @@ VISIT_OPTION_DEFAULT(VISIT_HDF5_LIBDEP ${VISITHOME}/szip/2.1/${VISITARCH}/lib sz
## H5Part
##
VISIT_OPTION_DEFAULT(VISIT_H5PART_DIR ${VISITHOME}/h5part/1.6.0/${VISITARCH})
VISIT_OPTION_DEFAULT(VISIT_H5PART_LIBDEP HDF5_LIBRARY_DIR hdf5 ${VISIT_HDF5_LIBDEP})
##
## NetCDF
......
......@@ -93,7 +93,6 @@ VISIT_OPTION_DEFAULT(VISIT_GDAL_DIR ${VISITHOME}/gdal/1.6.2/${VISITARCH})
## H5Part
##
VISIT_OPTION_DEFAULT(VISIT_H5PART_DIR ${VISITHOME}/h5part/1.6.0/${VISITARCH})
VISIT_OPTION_DEFAULT(VISIT_H5PART_LIBDEP HDF5_LIBRARY_DIR hdf5 ${VISIT_HDF5_LIBDEP})
##
## FastBit
......
......@@ -78,7 +78,6 @@ VISIT_OPTION_DEFAULT(VISIT_HDF5_LIBDEP ${VISITHOME}/szip/2.1/${VISITARCH}/lib sz
## H5Part
##
VISIT_OPTION_DEFAULT(VISIT_H5PART_DIR ${VISITHOME}/h5part/1.6.0/${VISITARCH})
VISIT_OPTION_DEFAULT(VISIT_H5PART_LIBDEP HDF5_LIBRARY_DIR hdf5 ${VISIT_HDF5_LIBDEP})
##
## SZIP
......
......@@ -85,7 +85,6 @@ VISIT_OPTION_DEFAULT(VISIT_HDF5_LIBDEP ${VISITHOME}/szip/2.1/${VISITARCH}/lib sz
## H5Part
##
VISIT_OPTION_DEFAULT(VISIT_H5PART_DIR ${VISITHOME}/h5part/1.6.0/${VISITARCH})
VISIT_OPTION_DEFAULT(VISIT_H5PART_LIBDEP HDF5_LIBRARY_DIR hdf5 ${VISIT_HDF5_LIBDEP})
##
## NetCDF
......
......@@ -70,7 +70,6 @@ VISIT_OPTION_DEFAULT(VISIT_BOXLIB3D_DIR ${VISITHOME}/boxlib/${VISITARCH})
## H5Part
##
VISIT_OPTION_DEFAULT(VISIT_H5PART_DIR ${VISITHOME}/h5part/1.6.0/${VISITARCH})
VISIT_OPTION_DEFAULT(VISIT_H5PART_LIBDEP HDF5_LIBRARY_DIR hdf5 ${VISIT_HDF5_LIBDEP})
##
## FastBit
......
......@@ -101,7 +101,6 @@ VISIT_OPTION_DEFAULT(VISIT_HDF5_LIBDEP ${VISITHOME}/szip/2.1/${VISITARCH}/lib sz
## H5Part
##
VISIT_OPTION_DEFAULT(VISIT_H5PART_DIR ${VISITHOME}/h5part/1.6.0/${VISITARCH})
VISIT_OPTION_DEFAULT(VISIT_H5PART_LIBDEP HDF5_LIBRARY_DIR hdf5 ${VISIT_HDF5_IBDEP})
##
## Mili
......
......@@ -74,7 +74,6 @@ VISIT_OPTION_DEFAULT(VISIT_HDF5_LIBDEP ${VISITHOME}/szip/2.1/${VISITARCH}/lib sz
## H5Part
##
VISIT_OPTION_DEFAULT(VISIT_H5PART_DIR ${VISITHOME}/h5part/1.6.0/${VISITARCH})
VISIT_OPTION_DEFAULT(VISIT_H5PART_LIBDEP HDF5_LIBRARY_DIR hdf5 ${VISIT_HDF5_LIBDEP})
##
## NetCDF
......
......@@ -108,7 +108,6 @@ VISIT_OPTION_DEFAULT(VISIT_HDF5_LIBDEP ${VISITHOME}/szip/2.1/${VISITARCH}/lib sz
## H5Part
##
VISIT_OPTION_DEFAULT(VISIT_H5PART_DIR ${VISITHOME}/h5part/1.6.0/${VISITARCH})
VISIT_OPTION_DEFAULT(VISIT_H5PART_LIBDEP HDF5_LIBRARY_DIR hdf5 ${VISIT_HDF5_LIBDEP})
##
## NetCDF
......
......@@ -24,8 +24,7 @@ avtXdmfFileFormat.C
INCLUDE_DIRECTORIES(
${CMAKE_CURRENT_SOURCE_DIR}
${XDMF_INCLUDE_DIR}
${XDMF_HDF5_INCLUDE}
${XDMF_INCLUDE_DIR} ${HDF5_INCLUDE_DIR}
${VISIT_COMMON_INCLUDES}
${VISIT_INCLUDE_DIR}/avt/DBAtts/MetaData
${VISIT_INCLUDE_DIR}/avt/DBAtts/SIL
......@@ -49,8 +48,11 @@ ${VISIT_INCLUDE_DIR}/visit_vtk/lightweight
${VTK_INCLUDE_DIRS}
)
IF(WIN32)
ADD_DEFINITIONS(-D_HDF5USEDLL_)
ENDIF(WIN32)
LINK_DIRECTORIES(${VISIT_LIBRARY_DIR} ${VTK_LIBRARY_DIRS} ${XDMF_LIBRARY_DIR} )
LINK_DIRECTORIES(${VISIT_LIBRARY_DIR} ${VTK_LIBRARY_DIRS} ${XDMF_LIBRARY_DIR} ${HDF5_LIBRARY_DIR} )
ADD_LIBRARY(IXdmfDatabase ${LIBI_SOURCES})
TARGET_LINK_LIBRARIES(IXdmfDatabase visitcommon)
......@@ -58,19 +60,19 @@ SET(INSTALLTARGETS IXdmfDatabase)
IF(NOT VISIT_ENGINE_ONLY AND NOT VISIT_DBIO_ONLY)
ADD_LIBRARY(MXdmfDatabase ${LIBM_SOURCES} )
TARGET_LINK_LIBRARIES(MXdmfDatabase visitcommon avtdbatts avtdatabase_ser ${XDMF_LIB} )
TARGET_LINK_LIBRARIES(MXdmfDatabase visitcommon avtdbatts avtdatabase_ser ${XDMF_LIB} ${HDF5_LIB} )
ADD_TARGET_DEFINITIONS(MXdmfDatabase MDSERVER)
SET(INSTALLTARGETS ${INSTALLTARGETS} MXdmfDatabase)
ENDIF(NOT VISIT_ENGINE_ONLY AND NOT VISIT_DBIO_ONLY)
ADD_LIBRARY(EXdmfDatabase_ser ${LIBE_SOURCES})
TARGET_LINK_LIBRARIES(EXdmfDatabase_ser visitcommon avtdatabase_ser avtpipeline_ser ${XDMF_LIB} )
TARGET_LINK_LIBRARIES(EXdmfDatabase_ser visitcommon avtdatabase_ser avtpipeline_ser ${XDMF_LIB} ${HDF5_LIB} )
ADD_TARGET_DEFINITIONS(EXdmfDatabase_ser ENGINE)
SET(INSTALLTARGETS ${INSTALLTARGETS} EXdmfDatabase_ser)
IF(VISIT_PARALLEL)
ADD_PARALLEL_LIBRARY(EXdmfDatabase_par ${LIBE_SOURCES})
TARGET_LINK_LIBRARIES(EXdmfDatabase_par visitcommon avtdatabase_par avtpipeline_par ${XDMF_LIB} )
TARGET_LINK_LIBRARIES(EXdmfDatabase_par visitcommon avtdatabase_par avtpipeline_par ${XDMF_LIB} ${HDF5_LIB} )
ADD_TARGET_DEFINITIONS(EXdmfDatabase_par ENGINE)
SET(INSTALLTARGETS ${INSTALLTARGETS} EXdmfDatabase_par)
ENDIF(VISIT_PARALLEL)
......
......@@ -2,12 +2,15 @@
<Plugin name="Xdmf" type="database" label="Extensible Data Model and Format" version="1.0" enabled="true" mdspecificcode="false" engspecificcode="false" onlyengine="false" noengine="false" dbtype="MTMD" haswriter="false" hasoptions="false" filePatternsStrict="false" opensWholeDirectory="false">
<CXXFLAGS>
${XDMF_INCLUDE_DIR}
${HDF5_INCLUDE_DIR}
</CXXFLAGS>
<LDFLAGS>
${XDMF_LIBRARY_DIR}
${HDF5_LIBRARY_DIR}
</LDFLAGS>
<LIBS>
${XDMF_LIB}
${HDF5_LIB}
</LIBS>
<FilePatterns>
*.xmf
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment