summaryrefslogtreecommitdiffstats
path: root/tools/h5diff
diff options
context:
space:
mode:
Diffstat (limited to 'tools/h5diff')
-rw-r--r--tools/h5diff/CMakeLists.txt404
-rw-r--r--tools/h5diff/Makefile.in20
-rw-r--r--tools/h5diff/h5diff_common.c24
-rw-r--r--tools/h5diff/testfiles/h5diff_10.txt24
-rw-r--r--tools/h5diff/testfiles/h5diff_484.txt11
-rw-r--r--tools/h5diff/testfiles/h5diff_600.txt24
-rw-r--r--tools/h5diff/testfiles/h5diff_603.txt24
-rw-r--r--tools/h5diff/testfiles/h5diff_606.txt24
-rw-r--r--tools/h5diff/testfiles/h5diff_612.txt24
-rw-r--r--tools/h5diff/testfiles/h5diff_615.txt24
-rw-r--r--tools/h5diff/testfiles/h5diff_621.txt24
-rw-r--r--tools/h5diff/testfiles/h5diff_622.txt24
-rw-r--r--tools/h5diff/testfiles/h5diff_623.txt24
-rw-r--r--tools/h5diff/testfiles/h5diff_624.txt24
-rwxr-xr-xtools/h5diff/testh5diff.sh6
15 files changed, 638 insertions, 67 deletions
diff --git a/tools/h5diff/CMakeLists.txt b/tools/h5diff/CMakeLists.txt
index 924c4ec..a784ae7 100644
--- a/tools/h5diff/CMakeLists.txt
+++ b/tools/h5diff/CMakeLists.txt
@@ -118,6 +118,7 @@ IF (BUILD_TESTING)
h5diff_481.txt
h5diff_482.txt
h5diff_483.txt
+ h5diff_484.txt
h5diff_50.txt
h5diff_51.txt
h5diff_52.txt
@@ -129,6 +130,7 @@ IF (BUILD_TESTING)
h5diff_58.txt
h5diff_500.txt
h5diff_501.txt
+ h5diff_502.txt
h5diff_503.txt
h5diff_504.txt
h5diff_505.txt
@@ -137,9 +139,14 @@ IF (BUILD_TESTING)
h5diff_508.txt
h5diff_509.txt
h5diff_510.txt
+ h5diff_511.txt
h5diff_512.txt
h5diff_513.txt
h5diff_514.txt
+ h5diff_515.txt
+ h5diff_516.txt
+ h5diff_517.txt
+ h5diff_518.txt
h5diff_600.txt
h5diff_601.txt
h5diff_603.txt
@@ -206,7 +213,7 @@ IF (BUILD_TESTING)
FOREACH (txt_file ${HDF5_REFERENCE_FILES})
SET (txtdest "${PROJECT_BINARY_DIR}/${txt_file}")
- #MESSAGE (STATUS " Translating ${txt_file}")
+ #MESSAGE (STATUS " Copying ${txt_file}")
ADD_CUSTOM_COMMAND (
TARGET h5diff
POST_BUILD
@@ -226,7 +233,7 @@ IF (BUILD_TESTING)
)
ENDFOREACH (h5_file ${HDF5_REFERENCE_TEST_FILES})
- IF (WIN32)
+ IF (WIN32 AND NOT CYGWIN)
ADD_CUSTOM_COMMAND (
TARGET h5diff
POST_BUILD
@@ -240,7 +247,7 @@ IF (BUILD_TESTING)
COMMAND ${CMAKE_COMMAND}
ARGS -E copy_if_different ${HDF5_TOOLS_H5DIFF_SOURCE_DIR}/testfiles/h5diff_102w.txt ${PROJECT_BINARY_DIR}/h5diff_102.txt
)
- ELSE (WIN32)
+ ELSE (WIN32 AND NOT CYGWIN)
ADD_CUSTOM_COMMAND (
TARGET h5diff
POST_BUILD
@@ -254,7 +261,7 @@ IF (BUILD_TESTING)
COMMAND ${CMAKE_COMMAND}
ARGS -E copy_if_different ${HDF5_TOOLS_H5DIFF_SOURCE_DIR}/testfiles/h5diff_102.txt ${PROJECT_BINARY_DIR}/h5diff_102.txt
)
- ENDIF (WIN32)
+ ENDIF (WIN32 AND NOT CYGWIN)
##############################################################################
##############################################################################
@@ -286,40 +293,314 @@ IF (BUILD_TESTING)
# --------------------------------------------------------------------
# test file names
# --------------------------------------------------------------------
-SET (FILE1 h5diff_basic1.h5)
-SET (FILE2 h5diff_basic2.h5)
-SET (FILE3 h5diff_types.h5)
-SET (FILE4 h5diff_dtypes.h5)
-SET (FILE5 h5diff_attr1.h5)
-SET (FILE6 h5diff_attr2.h5)
-SET (FILE7 h5diff_dset1.h5)
-SET (FILE8 h5diff_dset2.h5)
-SET (FILE9 h5diff_hyper1.h5)
-SET (FILE10 h5diff_hyper2.h5)
-SET (FILE11 h5diff_empty.h5)
-SET (FILE12 h5diff_links.h5)
-SET (FILE13 h5diff_softlinks.h5)
-SET (FILE14 h5diff_linked_softlink.h5)
-SET (FILE15 h5diff_extlink_src.h5)
-SET (FILE16 h5diff_extlink_trg.h5)
-SET (FILE17 h5diff_ext2softlink_src.h5)
-SET (FILE18 h5diff_ext2softlink_trg.h5)
-SET (DANGLE_LINK_FILE1 h5diff_danglelinks1.h5)
-SET (DANGLE_LINK_FILE2 h5diff_danglelinks2.h5)
-SET (GRP_RECURSE_FILE1 h5diff_grp_recurse1.h5)
-SET (GRP_RECURSE_FILE2 h5diff_grp_recurse2.h5)
-# group recursive - same structure via external links through files
-SET (GRP_RECURSE1_EXT h5diff_grp_recurse_ext1.h5)
-SET (GRP_RECURSE2_EXT1 h5diff_grp_recurse_ext2-1.h5)
-SET (GRP_RECURSE2_EXT2 h5diff_grp_recurse_ext2-2.h5)
-SET (GRP_RECURSE2_EXT3 h5diff_grp_recurse_ext2-3.h5)
-# same structure, same obj name with different value
-SET (EXCLUDE_FILE1_1 h5diff_exclude1-1.h5)
-SET (EXCLUDE_FILE1_2 h5diff_exclude1-2.h5)
-# different structure and obj names
-SET (EXCLUDE_FILE2_1 h5diff_exclude2-1.h5)
-SET (EXCLUDE_FILE2_2 h5diff_exclude2-2.h5)
-
+ SET (FILE1 h5diff_basic1.h5)
+ SET (FILE2 h5diff_basic2.h5)
+ SET (FILE3 h5diff_types.h5)
+ SET (FILE4 h5diff_dtypes.h5)
+ SET (FILE5 h5diff_attr1.h5)
+ SET (FILE6 h5diff_attr2.h5)
+ SET (FILE7 h5diff_dset1.h5)
+ SET (FILE8 h5diff_dset2.h5)
+ SET (FILE9 h5diff_hyper1.h5)
+ SET (FILE10 h5diff_hyper2.h5)
+ SET (FILE11 h5diff_empty.h5)
+ SET (FILE12 h5diff_links.h5)
+ SET (FILE13 h5diff_softlinks.h5)
+ SET (FILE14 h5diff_linked_softlink.h5)
+ SET (FILE15 h5diff_extlink_src.h5)
+ SET (FILE16 h5diff_extlink_trg.h5)
+ SET (FILE17 h5diff_ext2softlink_src.h5)
+ SET (FILE18 h5diff_ext2softlink_trg.h5)
+ SET (DANGLE_LINK_FILE1 h5diff_danglelinks1.h5)
+ SET (DANGLE_LINK_FILE2 h5diff_danglelinks2.h5)
+ SET (GRP_RECURSE_FILE1 h5diff_grp_recurse1.h5)
+ SET (GRP_RECURSE_FILE2 h5diff_grp_recurse2.h5)
+ # group recursive - same structure via external links through files
+ SET (GRP_RECURSE1_EXT h5diff_grp_recurse_ext1.h5)
+ SET (GRP_RECURSE2_EXT1 h5diff_grp_recurse_ext2-1.h5)
+ SET (GRP_RECURSE2_EXT2 h5diff_grp_recurse_ext2-2.h5)
+ SET (GRP_RECURSE2_EXT3 h5diff_grp_recurse_ext2-3.h5)
+ # same structure, same obj name with different value
+ SET (EXCLUDE_FILE1_1 h5diff_exclude1-1.h5)
+ SET (EXCLUDE_FILE1_2 h5diff_exclude1-2.h5)
+ # different structure and obj names
+ SET (EXCLUDE_FILE2_1 h5diff_exclude2-1.h5)
+ SET (EXCLUDE_FILE2_2 h5diff_exclude2-2.h5)
+
+ # Remove any output file left over from previous test run
+ ADD_TEST (
+ NAME H5DIFF-clearall-objects
+ COMMAND ${CMAKE_COMMAND}
+ -E remove
+ h5diff_10.out
+ h5diff_10.out.err
+ h5diff_100.out
+ h5diff_100.out.err
+ h5diff_101.out
+ h5diff_101.out.err
+ h5diff_102.out
+ h5diff_102.out.err
+ h5diff_11.out
+ h5diff_11.out.err
+ h5diff_12.out
+ h5diff_12.out.err
+ h5diff_13.out
+ h5diff_13.out.err
+ h5diff_14.out
+ h5diff_14.out.err
+ h5diff_15.out
+ h5diff_15.out.err
+ h5diff_16_1.out
+ h5diff_16_1.out.err
+ h5diff_16_2.out
+ h5diff_16_2.out.err
+ h5diff_16_3.out
+ h5diff_16_3.out.err
+ h5diff_17.out
+ h5diff_17.out.err
+ h5diff_171.out
+ h5diff_171.out.err
+ h5diff_172.out
+ h5diff_172.out.err
+ h5diff_18_1.out
+ h5diff_18_1.out.err
+ h5diff_18.out
+ h5diff_18.out.err
+ h5diff_20.out
+ h5diff_20.out.err
+ h5diff_200.out
+ h5diff_200.out.err
+ h5diff_201.out
+ h5diff_201.out.err
+ h5diff_202.out
+ h5diff_202.out.err
+ h5diff_203.out
+ h5diff_203.out.err
+ h5diff_204.out
+ h5diff_204.out.err
+ h5diff_205.out
+ h5diff_205.out.err
+ h5diff_206.out
+ h5diff_206.out.err
+ h5diff_207.out
+ h5diff_207.out.err
+ h5diff_21.out
+ h5diff_21.out.err
+ h5diff_22.out
+ h5diff_22.out.err
+ h5diff_23.out
+ h5diff_23.out.err
+ h5diff_24.out
+ h5diff_24.out.err
+ h5diff_25.out
+ h5diff_25.out.err
+ h5diff_26.out
+ h5diff_26.out.err
+ h5diff_27.out
+ h5diff_27.out.err
+ h5diff_28.out
+ h5diff_28.out.err
+ h5diff_300.out
+ h5diff_300.out.err
+ h5diff_400.out
+ h5diff_400.out.err
+ h5diff_401.out
+ h5diff_401.out.err
+ h5diff_402.out
+ h5diff_402.out.err
+ h5diff_403.out
+ h5diff_403.out.err
+ h5diff_404.out
+ h5diff_404.out.err
+ h5diff_405.out
+ h5diff_405.out.err
+ h5diff_406.out
+ h5diff_406.out.err
+ h5diff_407.out
+ h5diff_407.out.err
+ h5diff_408.out
+ h5diff_408.out.err
+ h5diff_409.out
+ h5diff_409.out.err
+ h5diff_410.out
+ h5diff_410.out.err
+ h5diff_411.out
+ h5diff_411.out.err
+ h5diff_412.out
+ h5diff_412.out.err
+ h5diff_413.out
+ h5diff_413.out.err
+ h5diff_414.out
+ h5diff_414.out.err
+ h5diff_415.out
+ h5diff_415.out.err
+ h5diff_416.out
+ h5diff_416.out.err
+ h5diff_417.out
+ h5diff_417.out.err
+ h5diff_418.out
+ h5diff_418.out.err
+ h5diff_419.out
+ h5diff_419.out.err
+ h5diff_420.out
+ h5diff_420.out.err
+ h5diff_421.out
+ h5diff_421.out.err
+ h5diff_422.out
+ h5diff_422.out.err
+ h5diff_423.out
+ h5diff_423.out.err
+ h5diff_424.out
+ h5diff_424.out.err
+ h5diff_425.out
+ h5diff_425.out.err
+ h5diff_450.out
+ h5diff_450.out.err
+ h5diff_451.out
+ h5diff_451.out.err
+ h5diff_452.out
+ h5diff_452.out.err
+ h5diff_453.out
+ h5diff_453.out.err
+ h5diff_454.out
+ h5diff_454.out.err
+ h5diff_455.out
+ h5diff_455.out.err
+ h5diff_456.out
+ h5diff_456.out.err
+ h5diff_457.out
+ h5diff_457.out.err
+ h5diff_458.out
+ h5diff_458.out.err
+ h5diff_459.out
+ h5diff_459.out.err
+ h5diff_480.out
+ h5diff_480.out.err
+ h5diff_481.out
+ h5diff_481.out.err
+ h5diff_482.out
+ h5diff_482.out.err
+ h5diff_483.out
+ h5diff_483.out.err
+ h5diff_484.out
+ h5diff_484.out.err
+ h5diff_50.out
+ h5diff_50.out.err
+ h5diff_51.out
+ h5diff_51.out.err
+ h5diff_52.out
+ h5diff_52.out.err
+ h5diff_53.out
+ h5diff_53.out.err
+ h5diff_54.out
+ h5diff_54.out.err
+ h5diff_55.out
+ h5diff_55.out.err
+ h5diff_56.out
+ h5diff_56.out.err
+ h5diff_57.out
+ h5diff_57.out.err
+ h5diff_58.out
+ h5diff_58.out.err
+ h5diff_500.out
+ h5diff_500.out.err
+ h5diff_501.out
+ h5diff_501.out.err
+ h5diff_502.out
+ h5diff_502.out.err
+ h5diff_503.out
+ h5diff_503.out.err
+ h5diff_504.out
+ h5diff_504.out.err
+ h5diff_505.out
+ h5diff_505.out.err
+ h5diff_506.out
+ h5diff_506.out.err
+ h5diff_507.out
+ h5diff_507.out.err
+ h5diff_508.out
+ h5diff_508.out.err
+ h5diff_509.out
+ h5diff_509.out.err
+ h5diff_510.out
+ h5diff_510.out.err
+ h5diff_511.out
+ h5diff_511.out.err
+ h5diff_512.out
+ h5diff_512.out.err
+ h5diff_513.out
+ h5diff_513.out.err
+ h5diff_514.out
+ h5diff_514.out.err
+ h5diff_515.out
+ h5diff_515.out.err
+ h5diff_516.out
+ h5diff_516.out.err
+ h5diff_517.out
+ h5diff_517.out.err
+ h5diff_518.out
+ h5diff_518.out.err
+ h5diff_600.out
+ h5diff_600.out.err
+ h5diff_601.out
+ h5diff_601.out.err
+ h5diff_603.out
+ h5diff_603.out.err
+ h5diff_604.out
+ h5diff_604.out.err
+ h5diff_605.out
+ h5diff_605.out.err
+ h5diff_606.out
+ h5diff_606.out.err
+ h5diff_607.out
+ h5diff_607.out.err
+ h5diff_608.out
+ h5diff_608.out.err
+ h5diff_609.out
+ h5diff_609.out.err
+ h5diff_610.out
+ h5diff_610.out.err
+ h5diff_612.out
+ h5diff_612.out.err
+ h5diff_613.out
+ h5diff_613.out.err
+ h5diff_614.out
+ h5diff_614.out.err
+ h5diff_615.out
+ h5diff_615.out.err
+ h5diff_616.out
+ h5diff_616.out.err
+ h5diff_617.out
+ h5diff_617.out.err
+ h5diff_618.out
+ h5diff_618.out.err
+ h5diff_619.out
+ h5diff_619.out.err
+ h5diff_621.out
+ h5diff_621.out.err
+ h5diff_622.out
+ h5diff_622.out.err
+ h5diff_623.out
+ h5diff_623.out.err
+ h5diff_624.out
+ h5diff_624.out.err
+ h5diff_625.out
+ h5diff_625.out.err
+ h5diff_626.out
+ h5diff_626.out.err
+ h5diff_627.out
+ h5diff_627.out.err
+ h5diff_628.out
+ h5diff_628.out.err
+ h5diff_629.out
+ h5diff_629.out.err
+ h5diff_70.out
+ h5diff_70.out.err
+ h5diff_80.out
+ h5diff_80.out.err
+ h5diff_90.out
+ h5diff_90.out.err
+ )
# ############################################################################
# # Common usage
@@ -395,7 +676,7 @@ ADD_H5_TEST (h5diff_24 0 -v ${FILE3} ${FILE3} t1 t1)
ADD_H5_TEST (h5diff_25 0 -v ${FILE3} ${FILE3} l1 l1)
# 2.6
-ADD_H5_TEST (h5diff_26 1 -v ${FILE3} ${FILE3} g1 g2)
+ADD_H5_TEST (h5diff_26 0 -v ${FILE3} ${FILE3} g1 g2)
# 2.7
ADD_H5_TEST (h5diff_27 1 -v ${FILE3} ${FILE3} t1 t2)
@@ -642,7 +923,7 @@ ADD_H5_TEST (h5diff_414 1 --follow-symlinks -v ${FILE14} ${FILE14} /target_group
ADD_H5_TEST (h5diff_415 1 --follow-symlinks -v ${FILE14} ${FILE14} /softlink3_to_slink2 /target_group)
# linked_softlink_to_group1 vs linked_softlink_to_group2"
-ADD_H5_TEST (h5diff_416 1 --follow-symlinks -v ${FILE14} ${FILE14} /softlink3_to_slink2 /softlink4_to_slink2)
+ADD_H5_TEST (h5diff_416 0 --follow-symlinks -v ${FILE14} ${FILE14} /softlink3_to_slink2 /softlink4_to_slink2)
# non-exist-softlink vs softlink"
ADD_H5_TEST (h5diff_417 1 --follow-symlinks -v ${FILE13} ${FILE13} /softlink_noexist /softlink_dset2)
@@ -709,37 +990,37 @@ ADD_H5_TEST (h5diff_459 2 --follow-symlinks -v --no-dangling-links ${FILE15} $
# # test for group diff recursivly
# ##############################################################################
# root
-ADD_H5_TEST (h5diff_500 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} / /)
-ADD_H5_TEST (h5diff_501 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} / /)
+ADD_H5_TEST (h5diff_500 1 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} / /)
+ADD_H5_TEST (h5diff_501 1 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} / /)
# root vs group
-ADD_H5_TEST (h5diff_502 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} / /grp1/grp2/grp3)
+ADD_H5_TEST (h5diff_502 1 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} / /grp1/grp2/grp3)
# group vs group (same name and structure)
-ADD_H5_TEST (h5diff_503 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp1 /grp1)
+ADD_H5_TEST (h5diff_503 0 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp1 /grp1)
# group vs group (different name and structure)
-ADD_H5_TEST (h5diff_504 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp1/grp2 /grp1/grp2/grp3)
+ADD_H5_TEST (h5diff_504 1 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp1/grp2 /grp1/grp2/grp3)
# groups vs soft-link
-ADD_H5_TEST (h5diff_505 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp1 /slink_grp1)
-ADD_H5_TEST (h5diff_506 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp1/grp2 /slink_grp2)
+ADD_H5_TEST (h5diff_505 0 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp1 /slink_grp1)
+ADD_H5_TEST (h5diff_506 0 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp1/grp2 /slink_grp2)
# groups vs ext-link
-ADD_H5_TEST (h5diff_507 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp1 /elink_grp1)
-ADD_H5_TEST (h5diff_508 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp1 /elink_grp1)
+ADD_H5_TEST (h5diff_507 0 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp1 /elink_grp1)
+ADD_H5_TEST (h5diff_508 0 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp1 /elink_grp1)
# soft-link vs ext-link
-ADD_H5_TEST (h5diff_509 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /slink_grp1 /elink_grp1)
-ADD_H5_TEST (h5diff_510 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /slink_grp1 /elink_grp1)
+ADD_H5_TEST (h5diff_509 0 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /slink_grp1 /elink_grp1)
+ADD_H5_TEST (h5diff_510 0 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /slink_grp1 /elink_grp1)
# circled ext links
-ADD_H5_TEST (h5diff_511 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp10 /grp11)
-ADD_H5_TEST (h5diff_512 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp10 /grp11)
+ADD_H5_TEST (h5diff_511 1 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp10 /grp11)
+ADD_H5_TEST (h5diff_512 1 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /grp10 /grp11)
# circled soft2ext-link vs soft2ext-link
-ADD_H5_TEST (h5diff_513 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /slink_grp10 /slink_grp11)
-ADD_H5_TEST (h5diff_514 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /slink_grp10 /slink_grp11)
+ADD_H5_TEST (h5diff_513 1 -v ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /slink_grp10 /slink_grp11)
+ADD_H5_TEST (h5diff_514 1 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_FILE2} /slink_grp10 /slink_grp11)
###############################################################################
# Test for group recursive diff via multi-linked external links
@@ -747,11 +1028,11 @@ ADD_H5_TEST (h5diff_514 -v --follow-symlinks ${GRP_RECURSE_FILE1} ${GRP_RECURSE_
# be same with the external links.
###############################################################################
# file vs file
-ADD_H5_TEST (h5diff_515 -v ${GRP_RECURSE1_EXT} ${GRP_RECURSE2_EXT1})
-ADD_H5_TEST (h5diff_516 -v --follow-symlinks ${GRP_RECURSE1_EXT} ${GRP_RECURSE2_EXT1})
+ADD_H5_TEST (h5diff_515 1 -v ${GRP_RECURSE1_EXT} ${GRP_RECURSE2_EXT1})
+ADD_H5_TEST (h5diff_516 0 -v --follow-symlinks ${GRP_RECURSE1_EXT} ${GRP_RECURSE2_EXT1})
# group vs group
-ADD_H5_TEST (h5diff_517 -v ${GRP_RECURSE1_EXT} ${GRP_RECURSE2_EXT1} /g1)
-ADD_H5_TEST (h5diff_518 -v --follow-symlinks ${GRP_RECURSE1_EXT} ${GRP_RECURSE2_EXT1} /g1)
+ADD_H5_TEST (h5diff_517 1 -v ${GRP_RECURSE1_EXT} ${GRP_RECURSE2_EXT1} /g1)
+ADD_H5_TEST (h5diff_518 0 -v --follow-symlinks ${GRP_RECURSE1_EXT} ${GRP_RECURSE2_EXT1} /g1)
# ##############################################################################
@@ -773,6 +1054,9 @@ ADD_H5_TEST (h5diff_482 0 -v --exclude-path "/group1" --exclude-path "/dset1" ${
# Exclude only some different objects. Expect return - diff
ADD_H5_TEST (h5diff_483 1 -v --exclude-path "/group1" ${EXCLUDE_FILE2_1} ${EXCLUDE_FILE2_2})
+# Exclude from group compare
+ADD_H5_TEST (h5diff_484 0 -v --exclude-path "/dset3" ${EXCLUDE_FILE1_1} ${EXCLUDE_FILE1_2} /group1)
+
ENDIF (BUILD_TESTING)
@@ -789,7 +1073,7 @@ INSTALL (
TARGETS
h5diff
RUNTIME DESTINATION
- bin/tools
+ ${HDF5_INSTALL_BIN_DIR}/tools
COMPONENT
toolsapplications
)
diff --git a/tools/h5diff/Makefile.in b/tools/h5diff/Makefile.in
index ce3acd9..3bfbf8e 100644
--- a/tools/h5diff/Makefile.in
+++ b/tools/h5diff/Makefile.in
@@ -348,14 +348,24 @@ LIBH5_HL = $(top_builddir)/hl/src/libhdf5_hl.la
LIBH5F_HL = $(top_builddir)/hl/fortran/src/libhdf5hl_fortran.la
LIBH5CPP_HL = $(top_builddir)/hl/c++/src/libhdf5_hl_cpp.la
+# Note that in svn revision 19400 the '/' after DESTDIR in H5* variables below
+# has been removed. According to the official description of DESTDIR by Gnu at
+# http://www.gnu.org/prep/standards/html_node/DESTDIR.html, DESTDIR is
+# prepended to the normal and complete install path that it precedes for the
+# purpose of installing in a temporary directory which is useful for building
+# rpms and other packages. The '/' after ${DESTDIR} will be followed by another
+# '/' at the beginning of the normal install path. When DESTDIR is empty the
+# path then begins with '//', which is incorrect and causes problems at least for
+# Cygwin.
+
# Scripts used to build examples
# If only shared libraries have been installed, have h5cc build examples with
# shared libraries instead of static libraries
-H5CC = $(bindir)/h5cc
-H5CC_PP = $(bindir)/h5pcc
-H5FC = $(bindir)/h5fc
-H5FC_PP = $(bindir)/h5pfc
-H5CPP = $(bindir)/h5c++
+H5CC = ${DESTDIR}$(bindir)/h5cc
+H5CC_PP = ${DESTDIR}$(bindir)/h5pcc
+H5FC = ${DESTDIR}$(bindir)/h5fc
+H5FC_PP = ${DESTDIR}$(bindir)/h5pfc
+H5CPP = ${DESTDIR}$(bindir)/h5c++
ACLOCAL_AMFLAGS = "-I m4"
# The trace script; this is used on source files from the C library to
diff --git a/tools/h5diff/h5diff_common.c b/tools/h5diff/h5diff_common.c
index a678b2f..84eb49a 100644
--- a/tools/h5diff/h5diff_common.c
+++ b/tools/h5diff/h5diff_common.c
@@ -453,6 +453,30 @@ void usage(void)
printf(" comparing floating point values.\n");
printf(" By default, strict equality is used. Use -p or -d to\n");
printf(" set specific tolerance.\n");
+ printf(" --exclude-path \"path\" Exclude the specified path to an object when\n");
+ printf(" comparing files or groups. If a group is excluded,\n");
+ printf(" all member objects will also be excluded.\n");
+ printf(" The specified path is excluded wherever it occurs.\n");
+ printf(" This flexibility enables the same option to exclude\n");
+ printf(" either objects that exist only in one file or\n");
+ printf(" common objects that are known to differ.\n");
+ printf("\n");
+ printf(" When comparing files, \"path\" is the absolute path to\n");
+ printf(" the excluded object; when comparing groups, \"path\" is\n");
+ printf(" similar to the relative path from the group to the\n");
+ printf(" excluded object. This \"path\" can be taken from the\n");
+ printf(" first section of the output of the --verbose option.\n");
+ printf(" For example, if you are comparing the group /groupA\n");
+ printf(" in two files and you want to exclude\n");
+ printf(" /groupA/groupB/groupC in both files, the exclude\n");
+ printf(" option would read as follows:\n");
+ printf(" --exclude-path \"/groupB/groupC\"\n");
+ printf("\n");
+ printf(" If there are multiple paths to an object, only the\n");
+ printf(" specified path(s) will be excluded; the comparison\n");
+ printf(" will include any path not explicitly excluded.\n");
+ printf(" This option can be used repeatedly to exclude\n");
+ printf(" multiple paths.\n");
printf("\n");
printf(" Modes of output:\n");
diff --git a/tools/h5diff/testfiles/h5diff_10.txt b/tools/h5diff/testfiles/h5diff_10.txt
index 224f9bc..4dae480 100644
--- a/tools/h5diff/testfiles/h5diff_10.txt
+++ b/tools/h5diff/testfiles/h5diff_10.txt
@@ -62,6 +62,30 @@ usage: h5diff [OPTIONS] file1 file2 [obj1[ obj2]]
comparing floating point values.
By default, strict equality is used. Use -p or -d to
set specific tolerance.
+ --exclude-path "path" Exclude the specified path to an object when
+ comparing files or groups. If a group is excluded,
+ all member objects will also be excluded.
+ The specified path is excluded wherever it occurs.
+ This flexibility enables the same option to exclude
+ either objects that exist only in one file or
+ common objects that are known to differ.
+
+ When comparing files, "path" is the absolute path to
+ the excluded object; when comparing groups, "path" is
+ similar to the relative path from the group to the
+ excluded object. This "path" can be taken from the
+ first section of the output of the --verbose option.
+ For example, if you are comparing the group /groupA
+ in two files and you want to exclude
+ /groupA/groupB/groupC in both files, the exclude
+ option would read as follows:
+ --exclude-path "/groupB/groupC"
+
+ If there are multiple paths to an object, only the
+ specified path(s) will be excluded; the comparison
+ will include any path not explicitly excluded.
+ This option can be used repeatedly to exclude
+ multiple paths.
Modes of output:
Default mode: print the number of differences found and where they occured
diff --git a/tools/h5diff/testfiles/h5diff_484.txt b/tools/h5diff/testfiles/h5diff_484.txt
new file mode 100644
index 0000000..87d9c7c
--- /dev/null
+++ b/tools/h5diff/testfiles/h5diff_484.txt
@@ -0,0 +1,11 @@
+
+group1 group2
+---------------------------------------
+ x x
+ x x /dset2
+
+group : </group1> and </group1>
+0 differences found
+dataset: </group1/dset2> and </group1/dset2>
+0 differences found
+EXIT CODE: 0
diff --git a/tools/h5diff/testfiles/h5diff_600.txt b/tools/h5diff/testfiles/h5diff_600.txt
index b096ab5..ea767fc 100644
--- a/tools/h5diff/testfiles/h5diff_600.txt
+++ b/tools/h5diff/testfiles/h5diff_600.txt
@@ -62,6 +62,30 @@ usage: h5diff [OPTIONS] file1 file2 [obj1[ obj2]]
comparing floating point values.
By default, strict equality is used. Use -p or -d to
set specific tolerance.
+ --exclude-path "path" Exclude the specified path to an object when
+ comparing files or groups. If a group is excluded,
+ all member objects will also be excluded.
+ The specified path is excluded wherever it occurs.
+ This flexibility enables the same option to exclude
+ either objects that exist only in one file or
+ common objects that are known to differ.
+
+ When comparing files, "path" is the absolute path to
+ the excluded object; when comparing groups, "path" is
+ similar to the relative path from the group to the
+ excluded object. This "path" can be taken from the
+ first section of the output of the --verbose option.
+ For example, if you are comparing the group /groupA
+ in two files and you want to exclude
+ /groupA/groupB/groupC in both files, the exclude
+ option would read as follows:
+ --exclude-path "/groupB/groupC"
+
+ If there are multiple paths to an object, only the
+ specified path(s) will be excluded; the comparison
+ will include any path not explicitly excluded.
+ This option can be used repeatedly to exclude
+ multiple paths.
Modes of output:
Default mode: print the number of differences found and where they occured
diff --git a/tools/h5diff/testfiles/h5diff_603.txt b/tools/h5diff/testfiles/h5diff_603.txt
index 2b37530..1c48c8b 100644
--- a/tools/h5diff/testfiles/h5diff_603.txt
+++ b/tools/h5diff/testfiles/h5diff_603.txt
@@ -63,6 +63,30 @@ usage: h5diff [OPTIONS] file1 file2 [obj1[ obj2]]
comparing floating point values.
By default, strict equality is used. Use -p or -d to
set specific tolerance.
+ --exclude-path "path" Exclude the specified path to an object when
+ comparing files or groups. If a group is excluded,
+ all member objects will also be excluded.
+ The specified path is excluded wherever it occurs.
+ This flexibility enables the same option to exclude
+ either objects that exist only in one file or
+ common objects that are known to differ.
+
+ When comparing files, "path" is the absolute path to
+ the excluded object; when comparing groups, "path" is
+ similar to the relative path from the group to the
+ excluded object. This "path" can be taken from the
+ first section of the output of the --verbose option.
+ For example, if you are comparing the group /groupA
+ in two files and you want to exclude
+ /groupA/groupB/groupC in both files, the exclude
+ option would read as follows:
+ --exclude-path "/groupB/groupC"
+
+ If there are multiple paths to an object, only the
+ specified path(s) will be excluded; the comparison
+ will include any path not explicitly excluded.
+ This option can be used repeatedly to exclude
+ multiple paths.
Modes of output:
Default mode: print the number of differences found and where they occured
diff --git a/tools/h5diff/testfiles/h5diff_606.txt b/tools/h5diff/testfiles/h5diff_606.txt
index 63a1d53..8f3bbd6 100644
--- a/tools/h5diff/testfiles/h5diff_606.txt
+++ b/tools/h5diff/testfiles/h5diff_606.txt
@@ -63,6 +63,30 @@ usage: h5diff [OPTIONS] file1 file2 [obj1[ obj2]]
comparing floating point values.
By default, strict equality is used. Use -p or -d to
set specific tolerance.
+ --exclude-path "path" Exclude the specified path to an object when
+ comparing files or groups. If a group is excluded,
+ all member objects will also be excluded.
+ The specified path is excluded wherever it occurs.
+ This flexibility enables the same option to exclude
+ either objects that exist only in one file or
+ common objects that are known to differ.
+
+ When comparing files, "path" is the absolute path to
+ the excluded object; when comparing groups, "path" is
+ similar to the relative path from the group to the
+ excluded object. This "path" can be taken from the
+ first section of the output of the --verbose option.
+ For example, if you are comparing the group /groupA
+ in two files and you want to exclude
+ /groupA/groupB/groupC in both files, the exclude
+ option would read as follows:
+ --exclude-path "/groupB/groupC"
+
+ If there are multiple paths to an object, only the
+ specified path(s) will be excluded; the comparison
+ will include any path not explicitly excluded.
+ This option can be used repeatedly to exclude
+ multiple paths.
Modes of output:
Default mode: print the number of differences found and where they occured
diff --git a/tools/h5diff/testfiles/h5diff_612.txt b/tools/h5diff/testfiles/h5diff_612.txt
index 6141495..e348caa 100644
--- a/tools/h5diff/testfiles/h5diff_612.txt
+++ b/tools/h5diff/testfiles/h5diff_612.txt
@@ -63,6 +63,30 @@ usage: h5diff [OPTIONS] file1 file2 [obj1[ obj2]]
comparing floating point values.
By default, strict equality is used. Use -p or -d to
set specific tolerance.
+ --exclude-path "path" Exclude the specified path to an object when
+ comparing files or groups. If a group is excluded,
+ all member objects will also be excluded.
+ The specified path is excluded wherever it occurs.
+ This flexibility enables the same option to exclude
+ either objects that exist only in one file or
+ common objects that are known to differ.
+
+ When comparing files, "path" is the absolute path to
+ the excluded object; when comparing groups, "path" is
+ similar to the relative path from the group to the
+ excluded object. This "path" can be taken from the
+ first section of the output of the --verbose option.
+ For example, if you are comparing the group /groupA
+ in two files and you want to exclude
+ /groupA/groupB/groupC in both files, the exclude
+ option would read as follows:
+ --exclude-path "/groupB/groupC"
+
+ If there are multiple paths to an object, only the
+ specified path(s) will be excluded; the comparison
+ will include any path not explicitly excluded.
+ This option can be used repeatedly to exclude
+ multiple paths.
Modes of output:
Default mode: print the number of differences found and where they occured
diff --git a/tools/h5diff/testfiles/h5diff_615.txt b/tools/h5diff/testfiles/h5diff_615.txt
index eaa2078..1bb0eb5 100644
--- a/tools/h5diff/testfiles/h5diff_615.txt
+++ b/tools/h5diff/testfiles/h5diff_615.txt
@@ -63,6 +63,30 @@ usage: h5diff [OPTIONS] file1 file2 [obj1[ obj2]]
comparing floating point values.
By default, strict equality is used. Use -p or -d to
set specific tolerance.
+ --exclude-path "path" Exclude the specified path to an object when
+ comparing files or groups. If a group is excluded,
+ all member objects will also be excluded.
+ The specified path is excluded wherever it occurs.
+ This flexibility enables the same option to exclude
+ either objects that exist only in one file or
+ common objects that are known to differ.
+
+ When comparing files, "path" is the absolute path to
+ the excluded object; when comparing groups, "path" is
+ similar to the relative path from the group to the
+ excluded object. This "path" can be taken from the
+ first section of the output of the --verbose option.
+ For example, if you are comparing the group /groupA
+ in two files and you want to exclude
+ /groupA/groupB/groupC in both files, the exclude
+ option would read as follows:
+ --exclude-path "/groupB/groupC"
+
+ If there are multiple paths to an object, only the
+ specified path(s) will be excluded; the comparison
+ will include any path not explicitly excluded.
+ This option can be used repeatedly to exclude
+ multiple paths.
Modes of output:
Default mode: print the number of differences found and where they occured
diff --git a/tools/h5diff/testfiles/h5diff_621.txt b/tools/h5diff/testfiles/h5diff_621.txt
index 8319db9..172cade 100644
--- a/tools/h5diff/testfiles/h5diff_621.txt
+++ b/tools/h5diff/testfiles/h5diff_621.txt
@@ -63,6 +63,30 @@ usage: h5diff [OPTIONS] file1 file2 [obj1[ obj2]]
comparing floating point values.
By default, strict equality is used. Use -p or -d to
set specific tolerance.
+ --exclude-path "path" Exclude the specified path to an object when
+ comparing files or groups. If a group is excluded,
+ all member objects will also be excluded.
+ The specified path is excluded wherever it occurs.
+ This flexibility enables the same option to exclude
+ either objects that exist only in one file or
+ common objects that are known to differ.
+
+ When comparing files, "path" is the absolute path to
+ the excluded object; when comparing groups, "path" is
+ similar to the relative path from the group to the
+ excluded object. This "path" can be taken from the
+ first section of the output of the --verbose option.
+ For example, if you are comparing the group /groupA
+ in two files and you want to exclude
+ /groupA/groupB/groupC in both files, the exclude
+ option would read as follows:
+ --exclude-path "/groupB/groupC"
+
+ If there are multiple paths to an object, only the
+ specified path(s) will be excluded; the comparison
+ will include any path not explicitly excluded.
+ This option can be used repeatedly to exclude
+ multiple paths.
Modes of output:
Default mode: print the number of differences found and where they occured
diff --git a/tools/h5diff/testfiles/h5diff_622.txt b/tools/h5diff/testfiles/h5diff_622.txt
index 1ccff92..beb04c5 100644
--- a/tools/h5diff/testfiles/h5diff_622.txt
+++ b/tools/h5diff/testfiles/h5diff_622.txt
@@ -63,6 +63,30 @@ usage: h5diff [OPTIONS] file1 file2 [obj1[ obj2]]
comparing floating point values.
By default, strict equality is used. Use -p or -d to
set specific tolerance.
+ --exclude-path "path" Exclude the specified path to an object when
+ comparing files or groups. If a group is excluded,
+ all member objects will also be excluded.
+ The specified path is excluded wherever it occurs.
+ This flexibility enables the same option to exclude
+ either objects that exist only in one file or
+ common objects that are known to differ.
+
+ When comparing files, "path" is the absolute path to
+ the excluded object; when comparing groups, "path" is
+ similar to the relative path from the group to the
+ excluded object. This "path" can be taken from the
+ first section of the output of the --verbose option.
+ For example, if you are comparing the group /groupA
+ in two files and you want to exclude
+ /groupA/groupB/groupC in both files, the exclude
+ option would read as follows:
+ --exclude-path "/groupB/groupC"
+
+ If there are multiple paths to an object, only the
+ specified path(s) will be excluded; the comparison
+ will include any path not explicitly excluded.
+ This option can be used repeatedly to exclude
+ multiple paths.
Modes of output:
Default mode: print the number of differences found and where they occured
diff --git a/tools/h5diff/testfiles/h5diff_623.txt b/tools/h5diff/testfiles/h5diff_623.txt
index 2c15d98..56c0b4c 100644
--- a/tools/h5diff/testfiles/h5diff_623.txt
+++ b/tools/h5diff/testfiles/h5diff_623.txt
@@ -63,6 +63,30 @@ usage: h5diff [OPTIONS] file1 file2 [obj1[ obj2]]
comparing floating point values.
By default, strict equality is used. Use -p or -d to
set specific tolerance.
+ --exclude-path "path" Exclude the specified path to an object when
+ comparing files or groups. If a group is excluded,
+ all member objects will also be excluded.
+ The specified path is excluded wherever it occurs.
+ This flexibility enables the same option to exclude
+ either objects that exist only in one file or
+ common objects that are known to differ.
+
+ When comparing files, "path" is the absolute path to
+ the excluded object; when comparing groups, "path" is
+ similar to the relative path from the group to the
+ excluded object. This "path" can be taken from the
+ first section of the output of the --verbose option.
+ For example, if you are comparing the group /groupA
+ in two files and you want to exclude
+ /groupA/groupB/groupC in both files, the exclude
+ option would read as follows:
+ --exclude-path "/groupB/groupC"
+
+ If there are multiple paths to an object, only the
+ specified path(s) will be excluded; the comparison
+ will include any path not explicitly excluded.
+ This option can be used repeatedly to exclude
+ multiple paths.
Modes of output:
Default mode: print the number of differences found and where they occured
diff --git a/tools/h5diff/testfiles/h5diff_624.txt b/tools/h5diff/testfiles/h5diff_624.txt
index 272b9fc..c0a95ed 100644
--- a/tools/h5diff/testfiles/h5diff_624.txt
+++ b/tools/h5diff/testfiles/h5diff_624.txt
@@ -63,6 +63,30 @@ usage: h5diff [OPTIONS] file1 file2 [obj1[ obj2]]
comparing floating point values.
By default, strict equality is used. Use -p or -d to
set specific tolerance.
+ --exclude-path "path" Exclude the specified path to an object when
+ comparing files or groups. If a group is excluded,
+ all member objects will also be excluded.
+ The specified path is excluded wherever it occurs.
+ This flexibility enables the same option to exclude
+ either objects that exist only in one file or
+ common objects that are known to differ.
+
+ When comparing files, "path" is the absolute path to
+ the excluded object; when comparing groups, "path" is
+ similar to the relative path from the group to the
+ excluded object. This "path" can be taken from the
+ first section of the output of the --verbose option.
+ For example, if you are comparing the group /groupA
+ in two files and you want to exclude
+ /groupA/groupB/groupC in both files, the exclude
+ option would read as follows:
+ --exclude-path "/groupB/groupC"
+
+ If there are multiple paths to an object, only the
+ specified path(s) will be excluded; the comparison
+ will include any path not explicitly excluded.
+ This option can be used repeatedly to exclude
+ multiple paths.
Modes of output:
Default mode: print the number of differences found and where they occured
diff --git a/tools/h5diff/testh5diff.sh b/tools/h5diff/testh5diff.sh
index df793f0..0696340 100755
--- a/tools/h5diff/testh5diff.sh
+++ b/tools/h5diff/testh5diff.sh
@@ -56,10 +56,10 @@ FILE19=h5diff_dset_idx1.h5
FILE20=h5diff_dset_idx2.h5
DANGLE_LINK_FILE1=h5diff_danglelinks1.h5
DANGLE_LINK_FILE2=h5diff_danglelinks2.h5
-/* group recursive */
+# group recursive
GRP_RECURSE_FILE1=h5diff_grp_recurse1.h5
GRP_RECURSE_FILE2=h5diff_grp_recurse2.h5
-/* group recursive - same structure via external links through files */
+# group recursive - same structure via external links through files
GRP_RECURSE1_EXT=h5diff_grp_recurse_ext1.h5
GRP_RECURSE2_EXT1=h5diff_grp_recurse_ext2-1.h5
GRP_RECURSE2_EXT2=h5diff_grp_recurse_ext2-2.h5
@@ -778,6 +778,8 @@ TOOLTEST h5diff_482.txt -v --exclude-path "/group1" --exclude-path "/dset1" $EXC
# Exclude only some different objects. Expect return - diff
TOOLTEST h5diff_483.txt -v --exclude-path "/group1" $EXCLUDE_FILE2_1 $EXCLUDE_FILE2_2
+# Exclude from group compare
+TOOLTEST h5diff_484.txt -v --exclude-path "/dset3" h5diff_exclude1-1.h5 h5diff_exclude1-2.h5 /group1
# ##############################################################################