diff options
author | Allen Byrne <byrn@hdfgroup.org> | 2016-10-05 17:11:28 (GMT) |
---|---|---|
committer | Allen Byrne <byrn@hdfgroup.org> | 2016-10-05 17:11:28 (GMT) |
commit | 783f01f478f99711710b24d8c85b0555dcdcf1fc (patch) | |
tree | 2fce87a76b5dfc7012432d9ce45b0934404f0d51 | |
parent | 620bfd58ae44dcf876303efb99482019ebbb9b6a (diff) | |
parent | 8c49b6e05a7d40218b8129b29bd74bbd2b39758d (diff) | |
download | hdf5-783f01f478f99711710b24d8c85b0555dcdcf1fc.zip hdf5-783f01f478f99711710b24d8c85b0555dcdcf1fc.tar.gz hdf5-783f01f478f99711710b24d8c85b0555dcdcf1fc.tar.bz2 |
Merge pull request #57 in HDFFV/hdf5 from ~BYRN/hdf5_adb:develop to develop
All changes tested in Buildbot and locally.
* commit '8c49b6e05a7d40218b8129b29bd74bbd2b39758d':
HDFFV-9991: Remove uneeded file
Fix missing defines for standalone perf
Remove hanging property set
Revert clear objects for testfile removal
Merge test output file clearing into runTest.cmake
Move clear-objects inside runTest
24 files changed, 49 insertions, 306 deletions
diff --git a/CMakeInstallation.cmake b/CMakeInstallation.cmake index 8dcaf85..6817d5c 100644 --- a/CMakeInstallation.cmake +++ b/CMakeInstallation.cmake @@ -75,21 +75,6 @@ configure_package_config_file ( ) #----------------------------------------------------------------------------- -# Configure the FindHDF5.cmake file for the install directory -#----------------------------------------------------------------------------- -if (NOT HDF5_EXTERNALLY_CONFIGURED) - configure_file ( - ${HDF_RESOURCES_DIR}/FindHDF5.cmake.in - ${HDF5_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/FindHDF5${HDF_PACKAGE_EXT}.cmake @ONLY - ) - install ( - FILES ${HDF5_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/FindHDF5${HDF_PACKAGE_EXT}.cmake - DESTINATION ${HDF5_INSTALL_CMAKE_DIR} - COMPONENT configinstall - ) -endif (NOT HDF5_EXTERNALLY_CONFIGURED) - -#----------------------------------------------------------------------------- # Configure the hdf5-config.cmake file for the install directory #----------------------------------------------------------------------------- set (INCLUDE_INSTALL_DIR ${HDF5_INSTALL_INCLUDE_DIR}) @@ -2840,7 +2840,6 @@ ./config/cmake/ConfigureChecks.cmake ./config/cmake/CPack.Info.plist.in ./config/cmake/CTestCustom.cmake -./config/cmake/FindHDF5.cmake.in ./config/cmake/FindHDFJAVA.cmake.in ./config/cmake/FindJNI.cmake ./config/cmake/H5cxx_config.h.in diff --git a/config/cmake/FindHDF5.cmake.in b/config/cmake/FindHDF5.cmake.in deleted file mode 100644 index fbc49f1..0000000 --- a/config/cmake/FindHDF5.cmake.in +++ /dev/null @@ -1,86 +0,0 @@ -# -# To be used by projects that make use of Cmakeified hdf5-@HDF5_PACKAGE_VERSION@ -# - -# -# Find the HDF5 includes and get all installed hdf5 library settings from -# HDF5-config.cmake file : Requires a CMake compatible hdf5-1.8.5 or later -# for this feature to work. The following vars are set if hdf5 is found. -# -# HDF5_FOUND - True if found, otherwise all other vars are undefined -# HDF5_INCLUDE_DIR - The include dir for main *.h files -# HDF5_FORTRAN_INCLUDE_DIR - The include dir for fortran modules and headers -# HDF5_VERSION_STRING - full version (e.g. @HDF5_PACKAGE_VERSION@) -# HDF5_VERSION_MAJOR - major part of version (e.g. @HDF5_PACKAGE_VERSION_MAJOR@) -# HDF5_VERSION_MINOR - minor part (e.g. @HDF5_PACKAGE_VERSION_MINOR@) -# -# The following boolean vars will be defined -# HDF5_ENABLE_PARALLEL - 1 if HDF5 parallel supported -# HDF5_BUILD_FORTRAN - 1 if HDF5 was compiled with fortran on -# HDF5_BUILD_CPP_LIB - 1 if HDF5 was compiled with cpp on -# HDF5_BUILD_TOOLS - 1 if HDF5 was compiled with tools on -# HDF5_BUILD_HL_LIB - 1 if HDF5 was compiled with high level on -# HDF5_BUILD_HL_CPP_LIB - 1 if HDF5 was compiled with high level and cpp on -# -# Target names that are valid (depending on enabled options) -# will be the following -# -# hdf5 : HDF5 C library -# hdf5_tools : the tools library -# hdf5_f90cstub : used by Fortran to C interface -# hdf5_fortran : Fortran HDF5 library -# hdf5_cpp : HDF5 cpp interface library -# hdf5_hl : High Level library -# hdf5_hl_f90cstub : used by Fortran to C interface to High Level library -# hdf5_hl_fortran : Fortran High Level library -# hdf5_hl_cpp : High Level cpp interface library -# -# To aid in finding HDF5 as part of a subproject set -# HDF5_ROOT_DIR_HINT to the location where @HDF5_PACKAGE@@HDF_PACKAGE_EXT@-config.cmake lies - -include (SelectLibraryConfigurations) -include (FindPackageHandleStandardArgs) - -# The HINTS option should only be used for values computed from the system. -set (_HDF5_HINTS - $ENV{HOME}/.local - $ENV{HDF5_ROOT} - $ENV{HDF5_ROOT_DIR_HINT} -) -# Hard-coded guesses should still go in PATHS. This ensures that the user -# environment can always override hard guesses. -set (_HDF5_PATHS - $ENV{HOME}/.local - $ENV{HDF5_ROOT} - $ENV{HDF5_ROOT_DIR_HINT} - /usr/lib/@HDF5_PACKAGE@ - /usr/share/@HDF5_PACKAGE@ - /usr/local/@HDF5_PACKAGE@ - /usr/local/@HDF5_PACKAGE@/share -) - -FIND_PATH (HDF5_ROOT_DIR "@HDF5_PACKAGE@@HDF_PACKAGE_EXT@-config.cmake" - HINTS ${_HDF5_HINTS} - PATHS ${_HDF5_PATHS} - PATH_SUFFIXES - cmake/@HDF5_PACKAGE@ - lib/cmake/@HDF5_PACKAGE@ - share/cmake/@HDF5_PACKAGE@ -) - -FIND_PATH (HDF5_INCLUDE_DIRS "H5public.h" - HINTS ${_HDF5_HINTS} - PATHS ${_HDF5_PATHS} - PATH_SUFFIXES - include - Include -) - -# For backwards compatibility we set HDF5_INCLUDE_DIR to the value of -# HDF5_INCLUDE_DIRS -set ( HDF5_INCLUDE_DIR "${HDF5_INCLUDE_DIRS}" ) - -if (HDF5_INCLUDE_DIR) - set (HDF5_FOUND "YES") - include (${HDF5_ROOT_DIR}/@HDF5_PACKAGE@@HDF_PACKAGE_EXT@-config.cmake) -endif (HDF5_INCLUDE_DIR) diff --git a/config/cmake_ext_mod/runTest.cmake b/config/cmake_ext_mod/runTest.cmake index 21a65e6..8b47693 100644 --- a/config/cmake_ext_mod/runTest.cmake +++ b/config/cmake_ext_mod/runTest.cmake @@ -25,6 +25,14 @@ if (NOT TEST_SKIP_COMPARE AND NOT TEST_REFERENCE) message (FATAL_ERROR "Require TEST_REFERENCE to be defined") endif (NOT TEST_SKIP_COMPARE AND NOT TEST_REFERENCE) +if (EXISTS ${TEST_FOLDER}/${TEST_OUTPUT}) + file (REMOVE ${TEST_FOLDER}/${TEST_OUTPUT}) +endif (EXISTS ${TEST_FOLDER}/${TEST_OUTPUT}) + +if (EXISTS ${TEST_FOLDER}/${TEST_OUTPUT}.err) + file (REMOVE ${TEST_FOLDER}/${TEST_OUTPUT}.err) +endif (EXISTS ${TEST_FOLDER}/${TEST_OUTPUT}.err) + # if there is not an error reference file add the error output to the stdout file if (NOT TEST_ERRREF) set (ERROR_APPEND 1) diff --git a/hl/tools/gif2h5/CMakeTests.cmake b/hl/tools/gif2h5/CMakeTests.cmake index 1cffe55..1dda0f5 100644 --- a/hl/tools/gif2h5/CMakeTests.cmake +++ b/hl/tools/gif2h5/CMakeTests.cmake @@ -26,16 +26,21 @@ add_test ( image.gif image24.gif ) +set_tests_properties (HL_TOOLS-clear-objects PROPERTIES DEPENDS HL_TOOLS-clear-objects) add_test (NAME HL_TOOLS_gif2h5 COMMAND $<TARGET_FILE:gif2h5> testfiles/image1.gif image1.h5) +set_tests_properties (HL_TOOLS-clear-objects PROPERTIES DEPENDS HL_TOOLS-clear-objects) add_test (NAME HL_TOOLS_h52gif COMMAND $<TARGET_FILE:h52gif> testfiles/h52giftst.h5 image1.gif -i image) +set_tests_properties (HL_TOOLS-clear-objects PROPERTIES DEPENDS HL_TOOLS-clear-objects) add_test (NAME HL_TOOLS_h52gif_none COMMAND $<TARGET_FILE:h52gif> testfiles/h52giftst.h5 image.gif -i nosuch_image) set_tests_properties (HL_TOOLS_h52gif_none PROPERTIES WILL_FAIL "true") +set_tests_properties (HL_TOOLS-clear-objects PROPERTIES DEPENDS HL_TOOLS-clear-objects) #add_test (NAME HL_TOOLS_h52gifpal COMMAND $<TARGET_FILE:h52gif> testfiles/h52giftst.h5 image.gif -i palette) #set_tests_properties (HL_TOOLS_h52gifpal PROPERTIES WILL_FAIL "true") add_test (NAME HL_TOOLS_h52gif24bits COMMAND $<TARGET_FILE:h52gif> testfiles/ex_image2.h5 image24.gif -i image24bitpixel) set_tests_properties (HL_TOOLS_h52gif24bits PROPERTIES WILL_FAIL "true") +set_tests_properties (HL_TOOLS_h52gif24bits PROPERTIES DEPENDS HL_TOOLS-clear-objects) diff --git a/java/examples/datasets/CMakeLists.txt b/java/examples/datasets/CMakeLists.txt index 0ba2331..3a69359 100644 --- a/java/examples/datasets/CMakeLists.txt +++ b/java/examples/datasets/CMakeLists.txt @@ -108,8 +108,6 @@ if (BUILD_TESTING) -E remove ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5 ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.data - ${example}.out - ${example}.out.err ) else (${example} STREQUAL "H5Ex_D_External") add_test ( @@ -117,8 +115,6 @@ if (BUILD_TESTING) COMMAND ${CMAKE_COMMAND} -E remove ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5 - ${example}.out - ${example}.out.err ) endif (${example} STREQUAL "H5Ex_D_External") if (NOT "${last_test}" STREQUAL "") diff --git a/java/examples/datatypes/CMakeLists.txt b/java/examples/datatypes/CMakeLists.txt index 5ab513c..3eae115 100644 --- a/java/examples/datatypes/CMakeLists.txt +++ b/java/examples/datatypes/CMakeLists.txt @@ -96,8 +96,6 @@ if (BUILD_TESTING) COMMAND ${CMAKE_COMMAND} -E remove ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5 - ${example}.out - ${example}.out.err ) if (NOT "${last_test}" STREQUAL "") set_tests_properties (JAVA_datatypes-${example}-clear-objects PROPERTIES DEPENDS ${last_test}) diff --git a/java/examples/groups/CMakeLists.txt b/java/examples/groups/CMakeLists.txt index c23b7d3..2cab211 100644 --- a/java/examples/groups/CMakeLists.txt +++ b/java/examples/groups/CMakeLists.txt @@ -90,17 +90,6 @@ ENDMACRO (ADD_H5_TEST file) if (BUILD_TESTING) foreach (example ${HDF_JAVA_EXAMPLES}) - add_test ( - NAME JAVA_groups-${example}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove - ${example}.out - ${example}.out.err - ) - if (NOT "${last_test}" STREQUAL "") - set_tests_properties (JAVA_groups-${example}-clear-objects PROPERTIES DEPENDS ${last_test}) - endif (NOT "${last_test}" STREQUAL "") - set (last_test "JAVA_groups-${example}-clear-objects") if (NOT ${example} STREQUAL "H5Ex_G_Iterate" AND NOT ${example} STREQUAL "H5Ex_G_Visit") if (${example} STREQUAL "H5Ex_G_Compact") add_test ( diff --git a/java/examples/intro/CMakeLists.txt b/java/examples/intro/CMakeLists.txt index 6b77382..2d0c218 100644 --- a/java/examples/intro/CMakeLists.txt +++ b/java/examples/intro/CMakeLists.txt @@ -98,8 +98,6 @@ if (BUILD_TESTING) COMMAND ${CMAKE_COMMAND} -E remove ${HDFJAVA_EXAMPLES_BINARY_DIR}/${example}.h5 - ${example}.out - ${example}.out.err ) if (NOT "${last_test}" STREQUAL "") set_tests_properties (JAVA_intro-${example}-clear-objects PROPERTIES DEPENDS ${last_test}) diff --git a/tools/h5copy/CMakeTests.cmake b/tools/h5copy/CMakeTests.cmake index 96dc92b..a32c766 100644 --- a/tools/h5copy/CMakeTests.cmake +++ b/tools/h5copy/CMakeTests.cmake @@ -211,8 +211,6 @@ COMMAND ${CMAKE_COMMAND} -E remove ./testfiles/${testname}.out.h5 - ./testfiles/${testname}.out.out - ./testfiles/${testname}.out.out.err ) add_test ( NAME H5COPY-CMP-${testname} diff --git a/tools/h5diff/CMakeTests.cmake b/tools/h5diff/CMakeTests.cmake index a649b78..5d3d433 100644 --- a/tools/h5diff/CMakeTests.cmake +++ b/tools/h5diff/CMakeTests.cmake @@ -310,11 +310,6 @@ endif () else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5DIFF-${resultfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ./testfiles/${resultfile}.out ./testfiles/${resultfile}.out.err - ) - add_test ( NAME H5DIFF-${resultfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5diff>" @@ -326,7 +321,6 @@ -D "TEST_APPEND=EXIT CODE:" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5DIFF-${resultfile} PROPERTIES DEPENDS "H5DIFF-${resultfile}-clear-objects") endif (HDF5_ENABLE_USING_MEMCHECKER) if (H5_HAVE_PARALLEL) ADD_PH5_TEST (${resultfile} ${resultcode} ${ARGN}) @@ -346,11 +340,6 @@ endif () else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME PH5DIFF-${resultfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ./testfiles/${resultfile}_p.out ./testfiles/${resultfile}_p.out.err - ) - add_test ( NAME PH5DIFF-${resultfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=${MPIEXEC};${MPIEXEC_PREFLAGS};${MPIEXEC_NUMPROC_FLAG};${MPIEXEC_MAX_NUMPROCS};${MPIEXEC_POSTFLAGS};$<TARGET_FILE:ph5diff>" @@ -364,41 +353,9 @@ -D "TEST_SKIP_COMPARE=TRUE" -P "${HDF_RESOURCES_EXT_DIR}/prunTest.cmake" ) - set_tests_properties (PH5DIFF-${resultfile} PROPERTIES DEPENDS "PH5DIFF-${resultfile}-clear-objects") endif (HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (ADD_PH5_TEST file) - # ADD_H5_NO_OUTPUT_TEST - # Purpose to verify only exitcode without output comparison - # Don't use this if possible; this may be removed. - MACRO (ADD_H5_NO_OUTPUT_TEST testname resultcode) - # If using memchecker add tests without using scripts - if (NOT HDF5_ENABLE_USING_MEMCHECKER) - add_test ( - NAME H5DIFF-${testname}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ./testfiles/${testname}.out ./testfiles/${testname}.out.err - ) - # if there was a previous test - if (NOT "${last_test}" STREQUAL "") - set_tests_properties (H5DIFF-${testname}-clear-objects PROPERTIES DEPENDS ${last_test}) - endif () - endif (NOT HDF5_ENABLE_USING_MEMCHECKER) - - add_test (NAME H5DIFF-${testname} COMMAND $<TARGET_FILE:h5diff> ${ARGN}) - if (NOT ${resultcode} STREQUAL "0") - set_tests_properties (H5DIFF-${testname} PROPERTIES WILL_FAIL "true") - endif () - - if (HDF5_ENABLE_USING_MEMCHECKER) - if (NOT "${last_test}" STREQUAL "") - set_tests_properties (H5DIFF-${testname} PROPERTIES DEPENDS ${last_test}) - endif () - else (HDF5_ENABLE_USING_MEMCHECKER) - set_tests_properties (H5DIFF-${testname} PROPERTIES DEPENDS H5DIFF-${testname}-clear-objects) - endif (HDF5_ENABLE_USING_MEMCHECKER) - ENDMACRO (ADD_H5_NO_OUTPUT_TEST) - ############################################################################## ############################################################################## ### T H E T E S T S ### diff --git a/tools/h5dump/CMakeTests.cmake b/tools/h5dump/CMakeTests.cmake index e376b50..895855c 100644 --- a/tools/h5dump/CMakeTests.cmake +++ b/tools/h5dump/CMakeTests.cmake @@ -381,12 +381,6 @@ set (last_test "H5DUMP-${testname}") else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5DUMP-h5dump-${testname}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove h5dump-${testname}.out h5dump-${testname}.out.err - ) - set_tests_properties (H5DUMP-h5dump-${testname}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/std") - add_test ( NAME H5DUMP-h5dump-${testname} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5dump>" @@ -397,7 +391,6 @@ -D "TEST_REFERENCE=h5dump-${testname}.txt" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5DUMP-h5dump-${testname} PROPERTIES DEPENDS "H5DUMP-h5dump-${testname}-clear-objects") endif (HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (ADD_HELP_TEST) @@ -429,7 +422,7 @@ add_test ( NAME H5DUMP-${resultfile}-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove ${resultfile}.bin ${resultfile}.out ${resultfile}.out.err + -E remove ${resultfile}.bin ) set_tests_properties (H5DUMP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/std") add_test ( @@ -462,7 +455,7 @@ add_test ( NAME H5DUMP-N-${resultfile}-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove ${resultfile}-N.bin ${resultfile}-N.out ${resultfile}-N.out.err + -E remove ${resultfile}-N.bin ) set_tests_properties (H5DUMP-N-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/std") add_test ( @@ -495,7 +488,7 @@ add_test ( NAME H5DUMP-${resultfile}-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove ${resultfile}.txt ${resultfile}.out ${resultfile}.out.err + -E remove ${resultfile}.txt ) set_tests_properties (H5DUMP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/std") add_test ( @@ -535,7 +528,7 @@ add_test ( NAME H5DUMP-${resultfile}-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove ${ddlfile}.txt ${resultfile}.txt ${resultfile}.out ${resultfile}.out.err + -E remove ${ddlfile}.txt ${resultfile}.txt ) set_tests_properties (H5DUMP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/std") add_test ( @@ -594,12 +587,6 @@ MACRO (ADD_H5_MASK_TEST resultfile resultcode) if (NOT HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5DUMP-${resultfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ${resultfile}.out ${resultfile}.out.err - ) - set_tests_properties (H5DUMP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/std") - add_test ( NAME H5DUMP-${resultfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5dump>" @@ -611,19 +598,12 @@ -D "TEST_MASK_ERROR=true" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5DUMP-${resultfile} PROPERTIES DEPENDS "H5DUMP-${resultfile}-clear-objects") endif (NOT HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (ADD_H5_MASK_TEST file) MACRO (ADD_H5ERR_MASK_TEST resultfile resultcode) if (NOT HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5DUMP-${resultfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ${resultfile}.out ${resultfile}.out.err - ) - set_tests_properties (H5DUMP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/std") - add_test ( NAME H5DUMP-${resultfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5dump>" @@ -636,19 +616,12 @@ -D "TEST_MASK_ERROR=true" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5DUMP-${resultfile} PROPERTIES DEPENDS "H5DUMP-${resultfile}-clear-objects") endif (NOT HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (ADD_H5ERR_MASK_TEST file) MACRO (ADD_H5ERR_MASK_ENV_TEST resultfile resultcode envvar envval) if (NOT HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5DUMP-${resultfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ${resultfile}.out ${resultfile}.out.err - ) - set_tests_properties (H5DUMP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/std") - add_test ( NAME H5DUMP-${resultfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5dump>" @@ -663,7 +636,6 @@ -D "TEST_ENV_VALUE:STRING=${envval}" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5DUMP-${resultfile} PROPERTIES DEPENDS "H5DUMP-${resultfile}-clear-objects") endif (NOT HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (ADD_H5ERR_MASK_ENV_TEST) @@ -673,7 +645,7 @@ add_test ( NAME H5DUMP-IMPORT-${resultfile}-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove ${conffile}.out ${conffile}.out.err ${resultfile}.bin ${resultfile}.h5 + -E remove ${resultfile}.bin ${resultfile}.h5 ) set_tests_properties (H5DUMP-IMPORT-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/std") add_test ( diff --git a/tools/h5dump/CMakeTestsPBITS.cmake b/tools/h5dump/CMakeTestsPBITS.cmake index 28514fb..681479a 100644 --- a/tools/h5dump/CMakeTestsPBITS.cmake +++ b/tools/h5dump/CMakeTestsPBITS.cmake @@ -121,12 +121,6 @@ endif () else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5DUMP-${resultfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ${resultfile}.out ${resultfile}.out.err - ) - set_tests_properties (H5DUMP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/pbits") - add_test ( NAME H5DUMP-${resultfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5dump>" @@ -137,7 +131,6 @@ -D "TEST_REFERENCE=${resultfile}.ddl" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5DUMP-${resultfile} PROPERTIES DEPENDS "H5DUMP-${resultfile}-clear-objects") endif (HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (ADD_H5_PBITS_TEST file) diff --git a/tools/h5dump/CMakeTestsVDS.cmake b/tools/h5dump/CMakeTestsVDS.cmake index 68a62e8..32056db 100644 --- a/tools/h5dump/CMakeTestsVDS.cmake +++ b/tools/h5dump/CMakeTestsVDS.cmake @@ -100,12 +100,6 @@ endif () else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5DUMP-${resultfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ${resultfile}.out ${resultfile}.out.err - ) - set_tests_properties (H5DUMP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/vds") - add_test ( NAME H5DUMP-${resultfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5dump>" @@ -116,7 +110,6 @@ -D "TEST_REFERENCE=${resultfile}.ddl" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5DUMP-${resultfile} PROPERTIES DEPENDS "H5DUMP-${resultfile}-clear-objects") endif (HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (ADD_H5_VDS_TEST file) @@ -133,12 +126,6 @@ endif () else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5DUMP-${resultfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ${resultfile}.out ${resultfile}.out.err - ) - set_tests_properties (H5DUMP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/vds") - add_test ( NAME H5DUMP-${resultfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5dump>" diff --git a/tools/h5dump/CMakeTestsXML.cmake b/tools/h5dump/CMakeTestsXML.cmake index 6e8dd15..79d3ff8 100644 --- a/tools/h5dump/CMakeTestsXML.cmake +++ b/tools/h5dump/CMakeTestsXML.cmake @@ -169,12 +169,6 @@ endif () else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5DUMP-XML-${resultfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ${resultfile}.out ${resultfile}.out.err - ) - set_tests_properties (H5DUMP-XML-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles/xml") - add_test ( NAME H5DUMP-XML-${resultfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5dump>" @@ -185,7 +179,6 @@ -D "TEST_REFERENCE=${resultfile}.xml" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5DUMP-XML-${resultfile} PROPERTIES DEPENDS "H5DUMP-XML-${resultfile}-clear-objects") endif (HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (ADD_XML_H5_TEST file) diff --git a/tools/h5format_convert/CMakeTests.cmake b/tools/h5format_convert/CMakeTests.cmake index 37ee824..929230a 100644 --- a/tools/h5format_convert/CMakeTests.cmake +++ b/tools/h5format_convert/CMakeTests.cmake @@ -83,7 +83,7 @@ add_test ( NAME H5FC-${testname}-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove ./testfiles/${testname}.out ./testfiles/${testname}.out.err ./testfiles/outtmp.h5 + -E remove ./testfiles/outtmp.h5 ) if (NOT "${last_test}" STREQUAL "") set_tests_properties (H5FC-${testname}-clear-objects PROPERTIES DEPENDS ${last_test}) @@ -132,7 +132,7 @@ add_test ( NAME H5FC-${testname}-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove ./testfiles/${testname}.out ./testfiles/${testname}.out.err ./testfiles/tmp.h5 + -E remove ./testfiles/tmp.h5 ) if (NOT "${last_test}" STREQUAL "") set_tests_properties (H5FC-${testname}-clear-objects PROPERTIES DEPENDS ${last_test}) @@ -176,7 +176,7 @@ add_test ( NAME H5FC-${testname}-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove ./testfiles/${testname}.out ./testfiles/${testname}.out.err ./testfiles/chktmp.h5 + -E remove ./testfiles/chktmp.h5 ) if (NOT "${last_test}" STREQUAL "") set_tests_properties (H5FC-${testname}-clear-objects PROPERTIES DEPENDS ${last_test}) @@ -214,7 +214,7 @@ add_test ( NAME H5FC-${testname}-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove ./testfiles/${testname}.out ./testfiles/${testname}.out.err ./testfiles/dmptmp.h5 + -E remove ./testfiles/dmptmp.h5 ) if (NOT "${last_test}" STREQUAL "") set_tests_properties (H5FC-${testname}-clear-objects PROPERTIES DEPENDS ${last_test}) diff --git a/tools/h5import/CMakeTests.cmake b/tools/h5import/CMakeTests.cmake index ef029e9..0fdf9dd 100644 --- a/tools/h5import/CMakeTests.cmake +++ b/tools/h5import/CMakeTests.cmake @@ -93,10 +93,6 @@ COMMAND ${CMAKE_COMMAND} -E remove ${testfile} - ${testfile}.new - ${testfile}.new.err - ${testfile}.out - ${testfile}.out.err ) set_tests_properties (H5IMPORT-${testname}-clear-objects PROPERTIES DEPENDS H5IMPORT-h5importtest) @@ -141,12 +137,6 @@ -E remove d${testfile} d${testfile}.bin - d${testfile}.imp - d${testfile}.imp.err - d${testfile}.dmp - d${testfile}.dmp.err - d${testfile}.dff - d${testfile}.dff.err ) set_tests_properties (H5IMPORT-DUMP-${testname}-clear-objects PROPERTIES DEPENDS H5IMPORT-h5importtest) diff --git a/tools/h5jam/CMakeTests.cmake b/tools/h5jam/CMakeTests.cmake index 6752c9a..96061b0 100644 --- a/tools/h5jam/CMakeTests.cmake +++ b/tools/h5jam/CMakeTests.cmake @@ -49,13 +49,6 @@ endif (NOT "${resultcode}" STREQUAL "0") else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5JAM-${expectfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove - ${expectfile}.out - ${expectfile}.out.err - ) - add_test ( NAME H5JAM-${expectfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5jam>" @@ -66,7 +59,6 @@ -D "TEST_REFERENCE=testfiles/${expectfile}.txt" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5JAM-${expectfile} PROPERTIES DEPENDS H5JAM-${expectfile}-clear-objects) endif (HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (TEST_H5JAM_OUTPUT) @@ -83,13 +75,6 @@ endif (NOT "${resultcode}" STREQUAL "0") else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5JAM-UNJAM-${expectfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove - ${expectfile}.out - ${expectfile}.out.err - ) - add_test ( NAME H5JAM-UNJAM-${expectfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5unjam>" @@ -100,7 +85,6 @@ -D "TEST_REFERENCE=testfiles/${expectfile}.txt" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5JAM-UNJAM-${expectfile} PROPERTIES DEPENDS H5JAM-UNJAM-${expectfile}-clear-objects) endif (HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (TEST_H5UNJAM_OUTPUT) @@ -108,16 +92,6 @@ # If using memchecker add tests without using scripts if (NOT HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5JAM-${testname}-CHECKFILE-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove - ${actual}.new - ${actual}.new.err - ${actual}.out - ${actual}.out.err - ) - set_tests_properties (H5JAM-${testname}-CHECKFILE-clear-objects PROPERTIES DEPENDS ${testdepends}) - add_test ( NAME H5JAM-${testname}-CHECKFILE-H5DMP COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5dump>" @@ -129,7 +103,7 @@ -D "TEST_SKIP_COMPARE=TRUE" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5JAM-${testname}-CHECKFILE-H5DMP PROPERTIES DEPENDS H5JAM-${testname}-CHECKFILE-clear-objects) + set_tests_properties (H5JAM-${testname}-CHECKFILE-H5DMP PROPERTIES DEPENDS ${testdepends}) add_test ( NAME H5JAM-${testname}-CHECKFILE-H5DMP_CMP COMMAND "${CMAKE_COMMAND}" @@ -174,11 +148,6 @@ else (NOT "${ufile}" STREQUAL "NONE") if (NOT "${ARGN}" STREQUAL "--delete") add_test ( - NAME H5JAM-${testname}-UNJAM_D-clear-objects - COMMAND ${CMAKE_COMMAND} -E remove ${outfile}.ufile.txt ${outfile}.ufile.txt.err - ) - set_tests_properties (H5JAM-${testname}-UNJAM_D-clear-objects PROPERTIES DEPENDS H5JAM-${testname}-UNJAM-clear-objects) - add_test ( NAME H5JAM-${testname}-UNJAM COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5unjam>" @@ -189,7 +158,7 @@ -D "TEST_SKIP_COMPARE=TRUE" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5JAM-${testname}-UNJAM PROPERTIES DEPENDS H5JAM-${testname}-UNJAM_D-clear-objects) + set_tests_properties (H5JAM-${testname}-UNJAM PROPERTIES DEPENDS H5JAM-${testname}-UNJAM-clear-objects) set (compare_test "${outfile}.ufile.txt") else (NOT "${ARGN}" STREQUAL "--delete") add_test (NAME H5JAM-${testname}-UNJAM COMMAND $<TARGET_FILE:h5unjam> -i ${infile} -o ${outfile}) diff --git a/tools/h5ls/CMakeTests.cmake b/tools/h5ls/CMakeTests.cmake index 2367df8..816907c 100644 --- a/tools/h5ls/CMakeTests.cmake +++ b/tools/h5ls/CMakeTests.cmake @@ -120,11 +120,6 @@ endif () else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5LS-${resultfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ./testfiles/${resultfile}.out ./testfiles/${resultfile}.out.err - ) - add_test ( NAME H5LS-${resultfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5ls>" @@ -135,7 +130,6 @@ -D "TEST_REFERENCE=${resultfile}.ls" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5LS-${resultfile} PROPERTIES DEPENDS "H5LS-${resultfile}-clear-objects") endif (HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (ADD_H5_TEST file) diff --git a/tools/h5ls/CMakeTestsVDS.cmake b/tools/h5ls/CMakeTestsVDS.cmake index e6c216d..0c825cb 100644 --- a/tools/h5ls/CMakeTestsVDS.cmake +++ b/tools/h5ls/CMakeTestsVDS.cmake @@ -71,11 +71,6 @@ endif () else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5LS-${resultfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ./testfiles/vds/${resultfile}.out ./testfiles/vds/${resultfile}.out.err - ) - add_test ( NAME H5LS-${resultfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5ls>" @@ -86,7 +81,6 @@ -D "TEST_REFERENCE=${resultfile}.ls" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5LS-${resultfile} PROPERTIES DEPENDS "H5LS_VDS-${resultfile}-clear-objects") endif (HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (ADD_H5_VDS_TEST file) diff --git a/tools/h5repack/CMakeTests.cmake b/tools/h5repack/CMakeTests.cmake index d0aa6c8..666f28e 100644 --- a/tools/h5repack/CMakeTests.cmake +++ b/tools/h5repack/CMakeTests.cmake @@ -147,12 +147,6 @@ set (last_test "H5REPACK-${testname}") else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5REPACK-h5repack-${testname}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove h5repack-${testname}.out h5repack-${testname}.out.err - ) - set_tests_properties (H5REPACK-h5repack-${testname}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles") - add_test ( NAME H5REPACK-h5repack-${testname} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5repack>" @@ -163,7 +157,6 @@ -D "TEST_REFERENCE=h5repack-${testname}.txt" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5REPACK-h5repack-${testname} PROPERTIES DEPENDS "H5REPACK-h5repack-${testname}-clear-objects") endif (HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (ADD_HELP_TEST) @@ -442,10 +435,6 @@ COMMAND ${CMAKE_COMMAND} -E remove testfiles/out-${testname}.${resultfile} - testfiles/${testname}.${resultfile}.out - testfiles/${testname}.${resultfile}.out.err - testfiles/${resultfile}-${testname}.out - testfiles/${resultfile}-${testname}.out.err ) add_test ( NAME H5REPACK_UD-${testname} diff --git a/tools/h5stat/CMakeTests.cmake b/tools/h5stat/CMakeTests.cmake index a371b81..fea358a 100644 --- a/tools/h5stat/CMakeTests.cmake +++ b/tools/h5stat/CMakeTests.cmake @@ -75,11 +75,6 @@ endif (NOT "${last_test}" STREQUAL "") else (HDF5_ENABLE_USING_MEMCHECKER) add_test ( - NAME H5STAT-${resultfile}-clear-objects - COMMAND ${CMAKE_COMMAND} - -E remove ${resultfile}.out ${resultfile}.out.err - ) - add_test ( NAME H5STAT-${resultfile} COMMAND "${CMAKE_COMMAND}" -D "TEST_PROGRAM=$<TARGET_FILE:h5stat>" @@ -90,7 +85,6 @@ -D "TEST_REFERENCE=${resultfile}.ddl" -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake" ) - set_tests_properties (H5STAT-${resultfile} PROPERTIES DEPENDS "H5STAT-${resultfile}-clear-objects") endif (HDF5_ENABLE_USING_MEMCHECKER) ENDMACRO (ADD_H5_TEST file) diff --git a/tools/misc/CMakeTests.cmake b/tools/misc/CMakeTests.cmake index 6822be5..bc2760b 100644 --- a/tools/misc/CMakeTests.cmake +++ b/tools/misc/CMakeTests.cmake @@ -76,8 +76,6 @@ COMMAND ${CMAKE_COMMAND} -E remove ${resultfile}.h5 - ${resultfile}.out - ${resultfile}.out.err ) set_tests_properties (H5MKGRP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles") endif (NOT HDF5_ENABLE_USING_MEMCHECKER) @@ -118,8 +116,6 @@ COMMAND ${CMAKE_COMMAND} -E remove ${resultfile}.h5 - ${resultfile}.out - ${resultfile}.out.err ) set_tests_properties (H5MKGRP_CMP-${resultfile}-clear-objects PROPERTIES WORKING_DIRECTORY "${PROJECT_BINARY_DIR}/testfiles") add_test ( diff --git a/tools/perform/sio_standalone.h b/tools/perform/sio_standalone.h index 258eafb..63dc7b0 100644 --- a/tools/perform/sio_standalone.h +++ b/tools/perform/sio_standalone.h @@ -56,6 +56,14 @@ # define H5_INC_ENUM(TYPE,VAR) (VAR)=((TYPE)((VAR)+1)) #endif +#define H5_FLT_ABS_EQUAL(X,Y) (HDfabsf((X)-(Y)) < FLT_EPSILON) +#define H5_DBL_ABS_EQUAL(X,Y) (HDfabs ((X)-(Y)) < DBL_EPSILON) +#define H5_LDBL_ABS_EQUAL(X,Y) (HDfabsl((X)-(Y)) < LDBL_EPSILON) + +#define H5_FLT_REL_EQUAL(X,Y,M) (HDfabsf(((Y)-(X)) / (X)) < (M)) +#define H5_DBL_REL_EQUAL(X,Y,M) (HDfabs (((Y)-(X)) / (X)) < (M)) +#define H5_LDBL_REL_EQUAL(X,Y,M) (HDfabsl(((Y)-(X)) / (X)) < (M)) + /* * Redefine all the POSIX functions. We should never see a POSIX * function (or any other non-HDF5 function) in the source! @@ -183,20 +191,32 @@ H5_DLL int HDfprintf (FILE *stream, const char *fmt, ...); #define HDstat(S,B) _stati64(S,B) typedef struct _stati64 h5_stat_t; typedef __int64 h5_stat_size_t; + #define HDoff_t __int64 #elif H5_SIZEOF_OFF_T!=8 && H5_SIZEOF_OFF64_T==8 && defined(H5_HAVE_STAT64) #define HDfstat(F,B) fstat64(F,B) #define HDlstat(S,B) lstat64(S,B) #define HDstat(S,B) stat64(S,B) typedef struct stat64 h5_stat_t; typedef off64_t h5_stat_size_t; + #define HDoff_t off64_t #else #define HDfstat(F,B) fstat(F,B) #define HDlstat(S,B) lstat(S,B) #define HDstat(S,B) stat(S,B) typedef struct stat h5_stat_t; typedef off_t h5_stat_size_t; + #define HDoff_t off_t #endif +#ifndef H5_HAVE_WIN32_API +/* These definitions differ in Windows and are defined in + * H5win32defs for that platform. + */ +typedef struct stat h5_stat_t; +typedef off_t h5_stat_size_t; +#define HDoff_t off_t +#endif /* H5_HAVE_WIN32_API */ + #define HDftell(F) ftell(F) #define HDftruncate(F,L) ftruncate(F,L) #define HDfwrite(M,Z,N,F) fwrite(M,Z,N,F) @@ -402,6 +422,11 @@ H5_DLL void HDsrand(unsigned int seed); #define HDstrtol(S,R,N) strtol(S,R,N) H5_DLL int64_t HDstrtoll (const char *s, const char **rest, int base); #define HDstrtoul(S,R,N) strtoul(S,R,N) +#ifdef H5_HAVE_WIN32_API +#define HDstrtoull(S,R,N) _strtoui64(S,R,N) +#else +#define HDstrtoull(S,R,N) strtoull(S,R,N) +#endif #define HDstrxfrm(X,Y,Z) strxfrm(X,Y,Z) #define HDsysconf(N) sysconf(N) #define HDsystem(S) system(S) |