diff options
author | Allen Byrne <byrn@hdfgroup.org> | 2011-10-20 18:50:19 (GMT) |
---|---|---|
committer | Allen Byrne <byrn@hdfgroup.org> | 2011-10-20 18:50:19 (GMT) |
commit | b15ebb546ee87bf7deae3c88687d1966b0e56aa5 (patch) | |
tree | 9fce548affb180d68414db095fdaf3daa740c4cf /tools | |
parent | cbed39d416ca66ec596ea76ab335c842fc1d6794 (diff) | |
download | hdf5-b15ebb546ee87bf7deae3c88687d1966b0e56aa5.zip hdf5-b15ebb546ee87bf7deae3c88687d1966b0e56aa5.tar.gz hdf5-b15ebb546ee87bf7deae3c88687d1966b0e56aa5.tar.bz2 |
[svn-r21621] Add H5_ff_F90.f90 file to legacy fortran projects
Replace contents of tnofilename.ddl with contents from tnofilename-with-packed-bits.ddl and use tnofilename.ddl in h5dump test scripts
Test local linux: cmake
Diffstat (limited to 'tools')
-rw-r--r-- | tools/h5dump/CMakeLists.txt | 5 | ||||
-rw-r--r-- | tools/h5dump/testh5dump.sh.in | 31 | ||||
-rw-r--r-- | tools/testfiles/tnofilename-with-packed-bits.ddl | 94 | ||||
-rw-r--r-- | tools/testfiles/tnofilename.ddl | 12 |
4 files changed, 27 insertions, 115 deletions
diff --git a/tools/h5dump/CMakeLists.txt b/tools/h5dump/CMakeLists.txt index aafd14d..9623118 100644 --- a/tools/h5dump/CMakeLists.txt +++ b/tools/h5dump/CMakeLists.txt @@ -404,7 +404,6 @@ IF (BUILD_TESTING) # -------------------------------------------------------------------- #-- Copy all the HDF5 files from the test directory into the source directory SET (HDF5_REFERENCE_PBITS - tnofilename-with-packed-bits.ddl tpbitsArray.ddl tpbitsCompound.ddl tpbitsIncomplete.ddl @@ -1266,8 +1265,6 @@ IF (BUILD_TESTING) NAME H5DUMP_PACKED_BITS-clearall-objects COMMAND ${CMAKE_COMMAND} -E remove - tnofilename-with-packed-bits.out - tnofilename-with-packed-bits.out.err tpbitsArray.out tpbitsArray.out.err tpbitsCompound.out @@ -1381,7 +1378,7 @@ IF (BUILD_TESTING) # test failure handling # Missing file name - ADD_H5_TEST (tnofilename-with-packed-bits 1) + ADD_H5_TEST (tnofilename 1) # Limits: # Maximum number of packed bits is 8 (for now). # Maximum integer size is 8*sizeof(long long). diff --git a/tools/h5dump/testh5dump.sh.in b/tools/h5dump/testh5dump.sh.in index 59786ce..3761005 100644 --- a/tools/h5dump/testh5dump.sh.in +++ b/tools/h5dump/testh5dump.sh.in @@ -280,7 +280,6 @@ $SRC_H5DUMP_TESTFILES/tvlstr.ddl $SRC_H5DUMP_TESTFILES/tvms.ddl $SRC_H5DUMP_TESTFILES/h5dump-help.txt $SRC_H5DUMP_TESTFILES/out3.h5import -$SRC_H5DUMP_TESTFILES/tnofilename-with-packed-bits.ddl $SRC_H5DUMP_TESTFILES/tpbitsArray.ddl $SRC_H5DUMP_TESTFILES/tpbitsCompound.ddl $SRC_H5DUMP_TESTFILES/tpbitsIncomplete.ddl @@ -482,8 +481,8 @@ TOOLTEST() { # Run test. TESTING $DUMPER $@ ( - cd $TESTDIR - $RUNSERIAL $DUMPER_BIN $@ + cd $TESTDIR + $RUNSERIAL $DUMPER_BIN $@ ) >$actual 2>$actual_err # save actual and actual_err in case they are needed later. @@ -493,7 +492,7 @@ TOOLTEST() { STDERR_FILTER $actual_err cat $actual_err >> $actual - if [ ! -f $expect ]; then + if [ ! -f $expect ]; then # Create the expect file if it doesn't yet exist. echo " CREATED" cp $actual $expect @@ -502,13 +501,13 @@ TOOLTEST() { else echo "*FAILED*" echo " Expected result (*.ddl) differs from actual result (*.out)" - nerrors="`expr $nerrors + 1`" - test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' + nerrors="`expr $nerrors + 1`" + test yes = "$verbose" && $DIFF $expect $actual |sed 's/^/ /' fi # Clean up output file if test -z "$HDF5_NOCLEANUP"; then - rm -f $actual $actual_err $actual_sav $actual_err_sav $actual_ext + rm -f $actual $actual_err $actual_sav $actual_err_sav $actual_ext fi } @@ -615,15 +614,15 @@ TOOLTEST3() { # Clean up output file if test -z "$HDF5_NOCLEANUP"; then - rm -f $actual $actual_err $actual_sav $actual_err_sav + rm -f $actual $actual_err $actual_sav $actual_err_sav fi } # Print a "SKIP" message SKIP() { - TESTING $DUMPER $@ - echo " -SKIP-" + TESTING $DUMPER $@ + echo " -SKIP-" } # Print a line-line message left justified in a field of 70 characters @@ -640,8 +639,8 @@ DIFFTEST() { PRINT_H5DIFF $@ ( - cd $TESTDIR - $RUNSERIAL $H5DIFF_BIN "$@" -q + cd $TESTDIR + $RUNSERIAL $H5DIFF_BIN "$@" -q ) RET=$? if [ $RET != 0 ] ; then @@ -673,8 +672,8 @@ IMPORTTEST() PRINT_H5IMPORT $@ ( - cd $TESTDIR - $RUNSERIAL $H5IMPORT_BIN "$@" + cd $TESTDIR + $RUNSERIAL $H5IMPORT_BIN "$@" ) RET=$? if [ $RET != 0 ] ; then @@ -689,7 +688,7 @@ IMPORTTEST() ############################################################################## ############################################################################## -### T H E T E S T S ### +### T H E T E S T S ### ############################################################################## ############################################################################## # prepare for test @@ -810,7 +809,7 @@ TOOLTEST tchar1.ddl -r tchar.h5 # test failure handling # Missing file name -TOOLTEST tnofilename-with-packed-bits.ddl +TOOLTEST tnofilename.ddl # rev. 2004 diff --git a/tools/testfiles/tnofilename-with-packed-bits.ddl b/tools/testfiles/tnofilename-with-packed-bits.ddl deleted file mode 100644 index 9083782..0000000 --- a/tools/testfiles/tnofilename-with-packed-bits.ddl +++ /dev/null @@ -1,94 +0,0 @@ -usage: h5dump [OPTIONS] file - OPTIONS - -h, --help Print a usage message and exit - -n, --contents Print a list of the file contents and exit - -B, --superblock Print the content of the super block - -H, --header Print the header only; no data is displayed - -A, --onlyattr Print the header and value of attributes - -i, --object-ids Print the object ids - -r, --string Print 1-byte integer datasets as ASCII - -e, --escape Escape non printing characters - -V, --version Print version number and exit - -a P, --attribute=P Print the specified attribute - -d P, --dataset=P Print the specified dataset - -y, --noindex Do not print array indices with the data - -p, --properties Print dataset filters, storage layout and fill value - -f D, --filedriver=D Specify which driver to open the file with - -g P, --group=P Print the specified group and all members - -l P, --soft-link=P Print the value(s) of the specified soft link - -o F, --output=F Output raw data into file F - -b B, --binary=B Binary file output, of form B - -t P, --datatype=P Print the specified named datatype - -w N, --width=N Set the number of columns of output. A value of 0 (zero) - sets the number of columns to the maximum (65535). - Default width is 80 columns. - -m T, --format=T Set the floating point output format - -q Q, --sort_by=Q Sort groups and attributes by index Q - -z Z, --sort_order=Z Sort groups and attributes by order Z - -M L, --packedbits=L Print packed bits as unsigned integers, using mask - format L for an integer dataset specified with - option -d. L is a list of offset,length values, - separated by commas. Offset is the beginning bit in - the data value and length is the number of bits of - the mask. - -R, --region Print dataset pointed by region references - -x, --xml Output in XML using Schema - -u, --use-dtd Output in XML using DTD - -D U, --xml-dtd=U Use the DTD or schema at U - -X S, --xml-ns=S (XML Schema) Use qualified names n the XML - ":": no namespace, default: "hdf5:" - E.g., to dump a file called `-f', use h5dump -- -f - --enable-error-stack Prints messages from the HDF5 error stack as they - occur. - - Subsetting is available by using the following options with a dataset - attribute. Subsetting is done by selecting a hyperslab from the data. - Thus, the options mirror those for performing a hyperslab selection. - One of the START, COUNT, STRIDE, or BLOCK parameters are mandatory if you do subsetting. - The STRIDE, COUNT, and BLOCK parameters are optional and will default to 1 in - each dimension. START is optional and will default to 0 in each dimension. - - -s START, --start=START Offset of start of subsetting selection - -S STRIDE, --stride=STRIDE Hyperslab stride - -c COUNT, --count=COUNT Number of blocks to include in selection - -k BLOCK, --block=BLOCK Size of block in hyperslab - START, COUNT, STRIDE, and BLOCK - is a list of integers the number of which are equal to the - number of dimensions in the dataspace being queried - - D - is the file driver to use in opening the file. Acceptable values - are "sec2", "family", "split", "multi", "direct", and "stream". Without - the file driver flag, the file will be opened with each driver in - turn and in the order specified above until one driver succeeds - in opening the file. - F - is a filename. - P - is the full path from the root group to the object. - N - is an integer greater than 1. - T - is a string containing the floating point format, e.g '%.3f' - U - is a URI reference (as defined in [IETF RFC 2396], - updated by [IETF RFC 2732]) - B - is the form of binary output: NATIVE for a memory type, FILE for the - file type, LE or BE for pre-existing little or big endian types. - Must be used with -o (output file) and it is recommended that - -d (dataset) is used. B is an optional argument, defaults to NATIVE - Q - is the sort index type. It can be "creation_order" or "name" (default) - Z - is the sort order type. It can be "descending" or "ascending" (default) - - Examples: - - 1) Attribute foo of the group /bar_none in file quux.h5 - - h5dump -a /bar_none/foo quux.h5 - - 2) Selecting a subset from dataset /foo in file quux.h5 - - h5dump -d /foo -s "0,1" -S "1,1" -c "2,3" -k "2,2" quux.h5 - - 3) Saving dataset 'dset' in file quux.h5 to binary file 'out.bin' - using a little-endian type - - h5dump -d /dset -b LE -o out.bin quux.h5 - - 4) Display two packed bits (bits 0-1 and bits 4-6) in the dataset /dset - - h5dump -d /dset -M 0,1,4,3 quux.h5 - diff --git a/tools/testfiles/tnofilename.ddl b/tools/testfiles/tnofilename.ddl index da79fbc..9083782 100644 --- a/tools/testfiles/tnofilename.ddl +++ b/tools/testfiles/tnofilename.ddl @@ -25,6 +25,12 @@ usage: h5dump [OPTIONS] file -m T, --format=T Set the floating point output format -q Q, --sort_by=Q Sort groups and attributes by index Q -z Z, --sort_order=Z Sort groups and attributes by order Z + -M L, --packedbits=L Print packed bits as unsigned integers, using mask + format L for an integer dataset specified with + option -d. L is a list of offset,length values, + separated by commas. Offset is the beginning bit in + the data value and length is the number of bits of + the mask. -R, --region Print dataset pointed by region references -x, --xml Output in XML using Schema -u, --use-dtd Output in XML using DTD @@ -71,7 +77,7 @@ usage: h5dump [OPTIONS] file 1) Attribute foo of the group /bar_none in file quux.h5 - h5dump -a /bar_none/foo quux.h5 + h5dump -a /bar_none/foo quux.h5 2) Selecting a subset from dataset /foo in file quux.h5 @@ -82,3 +88,7 @@ usage: h5dump [OPTIONS] file h5dump -d /dset -b LE -o out.bin quux.h5 + 4) Display two packed bits (bits 0-1 and bits 4-6) in the dataset /dset + + h5dump -d /dset -M 0,1,4,3 quux.h5 + |