From c194d4738ac6ed15475a9387272365265cec2ea5 Mon Sep 17 00:00:00 2001 From: Scot Breitenfeld Date: Sun, 30 Dec 2012 21:09:50 -0500 Subject: [svn-r23122] Brought revisions from the trunk into the branch: r23116-23118 : HDFFV-2686: Remove the ptExampleVL.c example from the source code HDFFV-422: Change extention of the binary files from hdf5 to h5 Tested: jam (gnu) --- MANIFEST | 12 ++-- configure | 2 +- hl/c++/examples/CMakeLists.txt | 11 ---- hl/c++/examples/Makefile.am | 5 +- hl/c++/examples/Makefile.in | 5 +- hl/c++/examples/ptExampleVL.cpp | 112 --------------------------------- hl/c++/examples/run-hlc++-ex.sh.in | 4 +- hl/examples/CMakeLists.txt | 1 - hl/examples/Makefile.am | 5 +- hl/examples/Makefile.in | 5 +- hl/examples/ptExampleVL.c | 126 ------------------------------------- hl/examples/run-hlc-ex.sh.in | 2 - hl/test/CMakeLists.txt | 2 +- hl/test/test_table.c | 6 +- hl/test/test_table_be.h5 | Bin 0 -> 55912 bytes hl/test/test_table_be.hdf5 | Bin 55912 -> 0 bytes hl/test/test_table_cray.h5 | Bin 0 -> 55912 bytes hl/test/test_table_cray.hdf5 | Bin 55912 -> 0 bytes hl/test/test_table_le.h5 | Bin 0 -> 53880 bytes hl/test/test_table_le.hdf5 | Bin 53880 -> 0 bytes test/CMakeLists.txt | 4 +- test/dsets.c | 18 +----- test/test_filters_be.h5 | Bin 0 -> 5720 bytes test/test_filters_be.hdf5 | Bin 5720 -> 0 bytes test/test_filters_le.h5 | Bin 0 -> 5720 bytes test/test_filters_le.hdf5 | Bin 5720 -> 0 bytes 26 files changed, 23 insertions(+), 297 deletions(-) delete mode 100644 hl/c++/examples/ptExampleVL.cpp delete mode 100644 hl/examples/ptExampleVL.c create mode 100644 hl/test/test_table_be.h5 delete mode 100644 hl/test/test_table_be.hdf5 create mode 100644 hl/test/test_table_cray.h5 delete mode 100644 hl/test/test_table_cray.hdf5 create mode 100644 hl/test/test_table_le.h5 delete mode 100644 hl/test/test_table_le.hdf5 create mode 100644 test/test_filters_be.h5 delete mode 100644 test/test_filters_be.hdf5 create mode 100644 test/test_filters_le.h5 delete mode 100644 test/test_filters_le.hdf5 diff --git a/MANIFEST b/MANIFEST index 85aafd4..0a9444a 100644 --- a/MANIFEST +++ b/MANIFEST @@ -951,8 +951,8 @@ ./test/tvltypes.c ./test/unlink.c ./test/vfd.c -./test/test_filters_le.hdf5 -./test/test_filters_be.hdf5 +./test/test_filters_le.h5 +./test/test_filters_be.h5 ./test/gen_filters.c ./test/testfiles/err_compat_1 @@ -1986,7 +1986,6 @@ ./hl/examples/image8.txt ./hl/examples/pal_rgb.h ./hl/examples/ptExampleFL.c -./hl/examples/ptExampleVL.c ./hl/examples/run-hl-ex.sh ./hl/examples/run-hlc-ex.sh.in ./hl/src/COPYING @@ -2039,9 +2038,9 @@ ./hl/test/test_table.c ./hl/test/test_ds_le.h5 ./hl/test/test_ds_be.h5 -./hl/test/test_table_le.hdf5 -./hl/test/test_table_be.hdf5 -./hl/test/test_table_cray.hdf5 +./hl/test/test_table_le.h5 +./hl/test/test_table_be.h5 +./hl/test/test_table_cray.h5 ./hl/test/usa.wri # tools @@ -2099,7 +2098,6 @@ ./hl/c++/examples/Makefile.am ./hl/c++/examples/Makefile.in ./hl/c++/examples/ptExampleFL.cpp -./hl/c++/examples/ptExampleVL.cpp ./hl/c++/examples/run-hlc++-ex.sh.in ./hl/c++/src/H5PacketTable.h ./hl/c++/src/H5PacketTable.cpp diff --git a/configure b/configure index 885de02..9735b06 100755 --- a/configure +++ b/configure @@ -1,5 +1,5 @@ #! /bin/sh -# From configure.ac Id: configure.ac 23072 2012-12-03 02:32:53Z hdftest . +# From configure.ac Id: configure.ac 23086 2012-12-10 03:36:10Z hdftest . # Guess values for system-dependent variables and create Makefiles. # Generated by GNU Autoconf 2.69 for HDF5 1.8.11-snap6. # diff --git a/hl/c++/examples/CMakeLists.txt b/hl/c++/examples/CMakeLists.txt index 3034a78..bba06e9 100644 --- a/hl/c++/examples/CMakeLists.txt +++ b/hl/c++/examples/CMakeLists.txt @@ -20,17 +20,6 @@ TARGET_LINK_LIBRARIES ( ) SET_TARGET_PROPERTIES (ptExampleFL PROPERTIES FOLDER examples/hl/cpp) -ADD_EXECUTABLE (ptExampleVL ${HDF5_HL_CPP_EXAMPLES_SOURCE_DIR}/ptExampleVL.cpp) -TARGET_NAMING (ptExampleVL ${LIB_TYPE}) -TARGET_LINK_LIBRARIES ( - ptExampleVL - ${HDF5_HL_CPP_LIB_TARGET} - ${HDF5_HL_LIB_TARGET} - ${HDF5_LIB_TARGET} -) -SET_TARGET_PROPERTIES (ptExampleVL PROPERTIES FOLDER examples/hl/cpp) - IF (BUILD_TESTING) ADD_TEST (NAME cpp_hl_ex_ptExampleFL COMMAND $) - ADD_TEST (NAME cpp_hl_ex_ptExampleVL COMMAND $) ENDIF (BUILD_TESTING) diff --git a/hl/c++/examples/Makefile.am b/hl/c++/examples/Makefile.am index 5dd5a75..df15257 100644 --- a/hl/c++/examples/Makefile.am +++ b/hl/c++/examples/Makefile.am @@ -23,10 +23,10 @@ include $(top_srcdir)/config/commence.am # These are the programs that 'make all' or 'make prog' will build and # which 'make check' will run. List them in the order they should be run. -EXAMPLE_PROG=ptExampleFL ptExampleVL +EXAMPLE_PROG=ptExampleFL # These are the example files to be installed -INSTALL_FILES=ptExampleFL.cpp ptExampleVL.cpp +INSTALL_FILES=ptExampleFL.cpp INSTALL_SCRIPT_FILES = run-hlc++-ex.sh # Tell conclude.am that these are C++ tests. @@ -45,7 +45,6 @@ $(EXTRA_PROG): $(H5CPP) # will try to build them with the normal C++ compiler, not h5c++. This is # an inelegant way of solving the problem, unfortunately. ptExampleFL: ptExampleFL.cpp -ptExampleVL: ptExampleVL.cpp include $(top_srcdir)/config/examples.am include $(top_srcdir)/config/conclude.am diff --git a/hl/c++/examples/Makefile.in b/hl/c++/examples/Makefile.in index bd0edf0..f617fec 100644 --- a/hl/c++/examples/Makefile.in +++ b/hl/c++/examples/Makefile.in @@ -390,10 +390,10 @@ CHECK_CLEANFILES = *.chkexe *.chklog *.clog *.h5 # These are the programs that 'make all' or 'make prog' will build and # which 'make check' will run. List them in the order they should be run. -EXAMPLE_PROG = ptExampleFL ptExampleVL +EXAMPLE_PROG = ptExampleFL # These are the example files to be installed -INSTALL_FILES = ptExampleFL.cpp ptExampleVL.cpp +INSTALL_FILES = ptExampleFL.cpp INSTALL_SCRIPT_FILES = run-hlc++-ex.sh # Tell conclude.am that these are C++ tests. @@ -651,7 +651,6 @@ $(EXTRA_PROG): $(H5CPP) # will try to build them with the normal C++ compiler, not h5c++. This is # an inelegant way of solving the problem, unfortunately. ptExampleFL: ptExampleFL.cpp -ptExampleVL: ptExampleVL.cpp # How to create EXAMPLEDIR if it doesn't already exist $(EXAMPLEDIR): diff --git a/hl/c++/examples/ptExampleVL.cpp b/hl/c++/examples/ptExampleVL.cpp deleted file mode 100644 index c3feccd..0000000 --- a/hl/c++/examples/ptExampleVL.cpp +++ /dev/null @@ -1,112 +0,0 @@ -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * Copyright by The HDF Group. * - * Copyright by the Board of Trustees of the University of Illinois. * - * All rights reserved. * - * * - * This file is part of HDF5. The full HDF5 copyright notice, including * - * terms governing use, modification, and redistribution, is contained in * - * the files COPYING and Copyright.html. COPYING can be found at the root * - * of the source code distribution tree; Copyright.html can be found at the * - * root level of an installed copy of the electronic HDF5 document set and * - * is linked from the top-level documents page. It can also be found at * - * http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have * - * access to either file, you may request a copy from help@hdfgroup.org. * - * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ - -#include "H5PacketTable.h" - -/*------------------------------------------------------------------------- - * Packet Table Variable-Length Example - * - * Example program that creates a packet table and performs - * writes and reads. - * - *------------------------------------------------------------------------- - */ - -int main(void) -{ -#ifdef VLPT_REMOVED - herr_t err; /* Return value from function calls */ - hid_t fileID; /* HDF5 identifier for file */ - hsize_t count; /* Number of records in table */ - int x; /* Loop variable */ - - /* This example has two different sizes of "record": longs and shorts */ - long longBuffer[5]; - short shortBuffer[5]; - - /* Buffer of hvl_t structs to read back records */ - hvl_t readBuffer[5]; - - /* Initialize buffers */ - for(x=0; x<5; x++) - { - longBuffer[x] = -x; - shortBuffer[x] = x; - } - - /* Create a new HDF5 file */ - fileID = H5Fcreate("PTcppexampleVL.h5", H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); - if(fileID <0) - fprintf(stderr, "Couldn't create file.\n"); - - /* Create a variable-length packet table. */ - VL_PacketTable ptable(fileID, "/examplePacketTable", 1); - - if(! ptable.IsValid()) - fprintf(stderr, "Unable to create packet table."); - - /* Append five packets to the packet table. */ - /* In C++, there is no need to package data into hvl_t structs. */ - err = ptable.AppendPacket( &(longBuffer[0]), sizeof(long)); - if(err < 0) - fprintf(stderr, "Error adding record."); - err = ptable.AppendPacket( &(shortBuffer[1]), sizeof(short)); - if(err < 0) - fprintf(stderr, "Error adding record."); - err = ptable.AppendPacket( &(longBuffer[2]), sizeof(long)); - if(err < 0) - fprintf(stderr, "Error adding record."); - err = ptable.AppendPacket( &(longBuffer[3]), sizeof(long)); - if(err < 0) - fprintf(stderr, "Error adding record."); - err = ptable.AppendPacket( &(shortBuffer[4]), sizeof(short)); - if(err < 0) - fprintf(stderr, "Error adding record."); - - /* Get the number of packets in the packet table. This should be five. */ - count = ptable.GetPacketCount(err); - if(err < 0) - fprintf(stderr, "Error getting packet count."); - - printf("Number of packets in packet table after five appends: %d\n", count); - - /* Initialize packet table's "current record" */ - ptable.ResetIndex(); - - /* Iterate through packets, read each one back */ - for(x=0; x<5; x++) - { - err = ptable.GetNextPacket( &(readBuffer[x]) ); - if(err < 0) - fprintf(stderr, "Error reading record."); - - printf("Packet %d's length is %d.\n", x, readBuffer[x].len); - if(readBuffer[x].len == sizeof(long)) - printf("Packet %d's value is %d.\n", x, *((long *) readBuffer[x].p) ); - else - printf("Packet %d's value is %d.\n", x, *((short *) readBuffer[x].p) ); - } - - /* The packet table will close automatically when its object goes */ - /* out of scope. */ - - err = H5Fclose(fileID); - if( err < 0 ) - fprintf(stderr, "Failed to close file.\n"); - -#endif /* VLPT_REMOVED */ - return 0; -} - diff --git a/hl/c++/examples/run-hlc++-ex.sh.in b/hl/c++/examples/run-hlc++-ex.sh.in index 7742f99..103dd76 100644 --- a/hl/c++/examples/run-hlc++-ex.sh.in +++ b/hl/c++/examples/run-hlc++-ex.sh.in @@ -64,9 +64,7 @@ RunTest() if [ $? -eq 0 ] then if (RunTest ptExampleFL &&\ - rm ptExampleFL &&\ - RunTest ptExampleVL &&\ - rm ptExampleVL); then + rm ptExampleFL); then EXIT_VALUE=${EXIT_SUCCESS} else EXIT_VALUE=${EXIT_FAILURE} diff --git a/hl/examples/CMakeLists.txt b/hl/examples/CMakeLists.txt index c95322c..f9c8922 100644 --- a/hl/examples/CMakeLists.txt +++ b/hl/examples/CMakeLists.txt @@ -23,7 +23,6 @@ SET (examples ex_lite2 ex_lite3 ptExampleFL - ptExampleVL ex_image1 ex_image2 ex_table_01 diff --git a/hl/examples/Makefile.am b/hl/examples/Makefile.am index 1c51f05..5108c5e 100644 --- a/hl/examples/Makefile.am +++ b/hl/examples/Makefile.am @@ -34,7 +34,7 @@ EXAMPLETOPDIR=${DESTDIR}$(exec_prefix)/share/hdf5_examples/hl # Don't tell automake about them, because if it knew they were programs, # it would try to compile them instead of using the h5cc script. # Use the boilerplate in config/examples.am instead. -EXAMPLE_PROG = ex_lite1 ex_lite2 ex_lite3 ptExampleFL ptExampleVL \ +EXAMPLE_PROG = ex_lite1 ex_lite2 ex_lite3 ptExampleFL \ ex_image1 ex_image2 \ ex_table_01 ex_table_02 ex_table_03 ex_table_04 \ ex_table_05 ex_table_06 ex_table_07 ex_table_08 \ @@ -43,7 +43,7 @@ EXAMPLE_PROG = ex_lite1 ex_lite2 ex_lite3 ptExampleFL ptExampleVL \ # Install files # List all file that should be installed in examples directory -INSTALL_FILES = ex_lite1.c ex_lite2.c ex_lite3.c ptExampleFL.c ptExampleVL.c \ +INSTALL_FILES = ex_lite1.c ex_lite2.c ex_lite3.c ptExampleFL.c \ ex_image1.c ex_image2.c \ ex_table_01.c ex_table_02.c ex_table_03.c ex_table_04.c \ ex_table_05.c ex_table_06.c ex_table_07.c ex_table_08.c \ @@ -75,7 +75,6 @@ ex_lite1: $(srcdir)/ex_lite1.c ex_lite2: $(srcdir)/ex_lite2.c ex_lite3: $(srcdir)/ex_lite3.c ptExampleFL: $(srcdir)/ptExampleFL.c -ptExampleVL: $(srcdir)/ptExampleVL.c ex_image1: $(srcdir)/ex_image1.c ex_image2: $(srcdir)/ex_image2.c ex_table01: $(srcdir)/ex_table01.c diff --git a/hl/examples/Makefile.in b/hl/examples/Makefile.in index 1794e38..f6126d4 100644 --- a/hl/examples/Makefile.in +++ b/hl/examples/Makefile.in @@ -398,7 +398,7 @@ EXAMPLETOPDIR = ${DESTDIR}$(exec_prefix)/share/hdf5_examples/hl # Don't tell automake about them, because if it knew they were programs, # it would try to compile them instead of using the h5cc script. # Use the boilerplate in config/examples.am instead. -EXAMPLE_PROG = ex_lite1 ex_lite2 ex_lite3 ptExampleFL ptExampleVL \ +EXAMPLE_PROG = ex_lite1 ex_lite2 ex_lite3 ptExampleFL \ ex_image1 ex_image2 \ ex_table_01 ex_table_02 ex_table_03 ex_table_04 \ ex_table_05 ex_table_06 ex_table_07 ex_table_08 \ @@ -408,7 +408,7 @@ EXAMPLE_PROG = ex_lite1 ex_lite2 ex_lite3 ptExampleFL ptExampleVL \ # Install files # List all file that should be installed in examples directory -INSTALL_FILES = ex_lite1.c ex_lite2.c ex_lite3.c ptExampleFL.c ptExampleVL.c \ +INSTALL_FILES = ex_lite1.c ex_lite2.c ex_lite3.c ptExampleFL.c \ ex_image1.c ex_image2.c \ ex_table_01.c ex_table_02.c ex_table_03.c ex_table_04.c \ ex_table_05.c ex_table_06.c ex_table_07.c ex_table_08.c \ @@ -677,7 +677,6 @@ ex_lite1: $(srcdir)/ex_lite1.c ex_lite2: $(srcdir)/ex_lite2.c ex_lite3: $(srcdir)/ex_lite3.c ptExampleFL: $(srcdir)/ptExampleFL.c -ptExampleVL: $(srcdir)/ptExampleVL.c ex_image1: $(srcdir)/ex_image1.c ex_image2: $(srcdir)/ex_image2.c ex_table01: $(srcdir)/ex_table01.c diff --git a/hl/examples/ptExampleVL.c b/hl/examples/ptExampleVL.c deleted file mode 100644 index 310aa07..0000000 --- a/hl/examples/ptExampleVL.c +++ /dev/null @@ -1,126 +0,0 @@ -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * Copyright by The HDF Group. * - * Copyright by the Board of Trustees of the University of Illinois. * - * All rights reserved. * - * * - * This file is part of HDF5. The full HDF5 copyright notice, including * - * terms governing use, modification, and redistribution, is contained in * - * the files COPYING and Copyright.html. COPYING can be found at the root * - * of the source code distribution tree; Copyright.html can be found at the * - * root level of an installed copy of the electronic HDF5 document set and * - * is linked from the top-level documents page. It can also be found at * - * http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have * - * access to either file, you may request a copy from help@hdfgroup.org. * - * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ - -#include "hdf5.h" -#include "hdf5_hl.h" -#include - -/*------------------------------------------------------------------------- - * Packet Table Variable-Length Example - * - * Example program that creates a variable-length packet table and performs - * writes and reads. - * - *------------------------------------------------------------------------- - */ - -int main(void) -{ -#ifdef VLPT_REMOVED - hid_t fid; /* File identifier */ - hid_t ptable; /* Packet table identifier */ - - herr_t err; /* Function return status */ - hsize_t count; /* Number of records in the table */ - int x; /* Loop variable */ - - /* Buffers to hold data */ - hvl_t writeBuffer[5]; - hvl_t readBuffer[5]; - - /* This example has two different sizes of "record": longs and shorts */ - long longBuffer[5]; - short shortBuffer[5]; - - /* Initialize buffers */ - for(x=0; x<5; x++) - { - longBuffer[x] = -x; - shortBuffer[x] = x; - } - - /* Fill the write buffer with a mix of longs and shorts */ - /* We need to supply the length of each record and a pointer to */ - /* the beginning of each record. */ - writeBuffer[0].len = sizeof(long); - writeBuffer[0].p = &(longBuffer[0]); - writeBuffer[1].len = sizeof(short); - writeBuffer[1].p = &(shortBuffer[1]); - writeBuffer[2].len = sizeof(long); - writeBuffer[2].p = &(longBuffer[2]); - writeBuffer[3].len = sizeof(long); - writeBuffer[3].p = &(longBuffer[3]); - writeBuffer[4].len = sizeof(short); - writeBuffer[4].p = &(shortBuffer[4]); - - /* Create a file using default properties */ - fid=H5Fcreate("packet_table_VLexample.h5",H5F_ACC_TRUNC,H5P_DEFAULT,H5P_DEFAULT); - - /* Create a variable-length packet table within the file */ - ptable = H5PTcreate_vl(fid, "Packet Test Dataset", (hsize_t)1); - if(ptable == H5I_INVALID_HID) - goto out; - - /* Write the entire buffer to the packet table */ - err = H5PTappend(ptable, (hsize_t)5, writeBuffer ); - if(err < 0) - goto out; - - /* Get the number of packets in the packet table. This should be five. */ - err = H5PTget_num_packets(ptable, &count); - if(err < 0) - goto out; - - printf("Number of packets in packet table after five appends: %d\n", count); - - /* Read all five packets back */ - err = H5PTread_packets(ptable, (hsize_t)0, (hsize_t)5, readBuffer ); - if(err < 0) - goto out; - - for(x=0; x<5; x++) - { - printf("Packet %d's length is %d\n", x, readBuffer[x].len); - if(readBuffer[x].len == sizeof(long)) - printf("Packet %d's value is %d\n", x, *( (long *) readBuffer[x].p) ); - else - printf("Packet %d's value is %d\n", x, *( (short *) readBuffer[x].p) ); - } - - /* Before we close the packet table, we must free the memory that */ - /* the pointers in readBuffer point to. */ - err = H5PTfree_vlen_readbuff(ptable, (hsize_t)5, readBuffer); - if(err < 0) - goto out; - - /* Close the packet table */ - err = H5PTclose(ptable); - if(err < 0) - goto out; - - /* Close the file */ - H5Fclose(fid); -#endif /* VLPT_REMOVED */ - - return 0; - -#ifdef VLPT_REMOVED - out: /* An error has occurred. Clean up and exit. */ - fprintf(stderr, "An error has occurred!\n"); - H5PTclose(ptable); - H5Fclose(fid); - return -1; -#endif /* VLPT_REMOVED */ -} diff --git a/hl/examples/run-hlc-ex.sh.in b/hl/examples/run-hlc-ex.sh.in index a82e591..a79f67a 100644 --- a/hl/examples/run-hlc-ex.sh.in +++ b/hl/examples/run-hlc-ex.sh.in @@ -76,8 +76,6 @@ then rm ex_lite3 &&\ RunTest ptExampleFL &&\ rm ptExampleFL &&\ - RunTest ptExampleVL &&\ - rm ptExampleVL &&\ RunTest ex_image1 &&\ rm ex_image1 &&\ RunTest ex_image2 &&\ diff --git a/hl/test/CMakeLists.txt b/hl/test/CMakeLists.txt index 89baac4..f3e42af 100644 --- a/hl/test/CMakeLists.txt +++ b/hl/test/CMakeLists.txt @@ -79,7 +79,7 @@ HL_ADD_TEST (test_ds "dsdata.txt;dslat.txt;dslon.txt;test_ds_be.h5;test_ds_le.h5 HL_ADD_TEST (test_image "image8.txt;sepia.pal;earth.pal;image24pixel.txt;image24plane.txt;usa.wri") HL_ADD_TEST (test_lite "dtype_file.txt") HL_ADD_TEST (test_packet "") -HL_ADD_TEST (test_table "test_table_be.hdf5;test_table_cray.hdf5;test_table_le.hdf5") +HL_ADD_TEST (test_table "test_table_be.h5;test_table_cray.h5;test_table_le.h5") # -------------------------------------------------------------------- # This executable is used to generate test files for the test_ds test. diff --git a/hl/test/test_table.c b/hl/test/test_table.c index ff717cc..4b62ac5 100644 --- a/hl/test/test_table.c +++ b/hl/test/test_table.c @@ -19,9 +19,9 @@ #include "H5srcdir.h" #include "H5TBpublic.h" -#define TEST_FILE_BE "test_table_be.hdf5" -#define TEST_FILE_LE "test_table_le.hdf5" -#define TEST_FILE_CRAY "test_table_cray.hdf5" +#define TEST_FILE_BE "test_table_be.h5" +#define TEST_FILE_LE "test_table_le.h5" +#define TEST_FILE_CRAY "test_table_cray.h5" /*------------------------------------------------------------------------- diff --git a/hl/test/test_table_be.h5 b/hl/test/test_table_be.h5 new file mode 100644 index 0000000..3639695 Binary files /dev/null and b/hl/test/test_table_be.h5 differ diff --git a/hl/test/test_table_be.hdf5 b/hl/test/test_table_be.hdf5 deleted file mode 100644 index 3639695..0000000 Binary files a/hl/test/test_table_be.hdf5 and /dev/null differ diff --git a/hl/test/test_table_cray.h5 b/hl/test/test_table_cray.h5 new file mode 100644 index 0000000..d22dce3 Binary files /dev/null and b/hl/test/test_table_cray.h5 differ diff --git a/hl/test/test_table_cray.hdf5 b/hl/test/test_table_cray.hdf5 deleted file mode 100644 index d22dce3..0000000 Binary files a/hl/test/test_table_cray.hdf5 and /dev/null differ diff --git a/hl/test/test_table_le.h5 b/hl/test/test_table_le.h5 new file mode 100644 index 0000000..6c330fd Binary files /dev/null and b/hl/test/test_table_le.h5 differ diff --git a/hl/test/test_table_le.hdf5 b/hl/test/test_table_le.hdf5 deleted file mode 100644 index 6c330fd..0000000 Binary files a/hl/test/test_table_le.hdf5 and /dev/null differ diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index d6ffe42..03d311b 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -106,8 +106,8 @@ SET (HDF5_REFERENCE_TEST_FILES tarrold.h5 tbad_msg_count.h5 tbogus.h5 - test_filters_be.hdf5 - test_filters_le.hdf5 + test_filters_be.h5 + test_filters_le.h5 th5s.h5 tlayouto.h5 tmtimen.h5 diff --git a/test/dsets.c b/test/dsets.c index 3b0d25d..7283aae 100644 --- a/test/dsets.c +++ b/test/dsets.c @@ -6584,8 +6584,7 @@ test_filters_endianess(void) hid_t dsid=-1; /* dataset ID */ hid_t sid=-1; /* dataspace ID */ hid_t dcpl=-1; /* dataset creation property list ID */ - char *srcdir = getenv("srcdir"); /* the source directory */ - char data_file[512]=""; /* buffer to hold name of existing file */ + const char *data_file = H5_get_srcdir_filename("test_filters_le.h5"); /* Corrected test file name */ TESTING("filters with big-endian/little-endian data"); @@ -6595,14 +6594,6 @@ test_filters_endianess(void) *------------------------------------------------------------------------- */ - /* compose the name of the file to open, using the srcdir, if appropriate */ - HDstrcpy(data_file, ""); - if(srcdir) { - HDstrcpy(data_file, srcdir); - HDstrcat(data_file, "/"); - } - HDstrcat(data_file, "test_filters_le.hdf5"); - /* open */ if((fid = H5Fopen(data_file, H5F_ACC_RDONLY, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR @@ -6618,12 +6609,7 @@ test_filters_endianess(void) */ /* compose the name of the file to open, using the srcdir, if appropriate */ - HDstrcpy(data_file, ""); - if(srcdir) { - HDstrcpy(data_file, srcdir); - HDstrcat(data_file, "/"); - } - HDstrcat(data_file, "test_filters_be.hdf5"); + data_file = H5_get_srcdir_filename("test_filters_be.h5"); /* Corrected test file name */ /* open */ if((fid = H5Fopen(data_file, H5F_ACC_RDONLY, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR diff --git a/test/test_filters_be.h5 b/test/test_filters_be.h5 new file mode 100644 index 0000000..c4c127b Binary files /dev/null and b/test/test_filters_be.h5 differ diff --git a/test/test_filters_be.hdf5 b/test/test_filters_be.hdf5 deleted file mode 100644 index c4c127b..0000000 Binary files a/test/test_filters_be.hdf5 and /dev/null differ diff --git a/test/test_filters_le.h5 b/test/test_filters_le.h5 new file mode 100644 index 0000000..ff8b846 Binary files /dev/null and b/test/test_filters_le.h5 differ diff --git a/test/test_filters_le.hdf5 b/test/test_filters_le.hdf5 deleted file mode 100644 index ff8b846..0000000 Binary files a/test/test_filters_le.hdf5 and /dev/null differ -- cgit v0.12