From 83f49851c103f7ec111452c805e24205fc5a0a3d Mon Sep 17 00:00:00 2001 From: Elena Pourmal Date: Thu, 23 Oct 2003 08:02:08 -0500 Subject: [svn-r7712] Purpose: Maintenance Description: h5createU8 utility was the old h5import utiltity. It was supposed to be gone for 1.6.1 but I forgot to delete it before the release. I am doing it now. Solution: Platforms tested: arabica Misc. update: --- tools/misc/Makefile.in | 7 +-- tools/misc/h5createU8.c | 152 ------------------------------------------------ 2 files changed, 2 insertions(+), 157 deletions(-) delete mode 100644 tools/misc/h5createU8.c diff --git a/tools/misc/Makefile.in b/tools/misc/Makefile.in index 9e98a73..4028d57 100644 --- a/tools/misc/Makefile.in +++ b/tools/misc/Makefile.in @@ -35,7 +35,7 @@ LIBTOOLS=../lib/libh5tools.la LIBHDF5=$(top_builddir)/src/libhdf5.la ## h5cc is generated by configure. Remove it only when distclean. -BUILD_PROGS=h5debug h5createU8 h5redeploy h5repart @PDB2HDF@ +BUILD_PROGS=h5debug h5redeploy h5repart @PDB2HDF@ PUB_PROGS=h5cc $(BUILD_PROGS) PROGS=$(BUILD_PROGS) $(TEST_PROGS) DISTCLEAN=h5cc @@ -48,7 +48,7 @@ PUB_LIB= ## Source and object files for programs... ## -PROG_SRC=h5debug.c h5createU8.c h5repart.c pdb2hdf.c +PROG_SRC=h5debug.c h5repart.c pdb2hdf.c PROG_OBJ=$(PROG_SRC:.c=.lo) PRIVATE_HDR= @@ -73,9 +73,6 @@ h5cc: h5cc.in h5debug: h5debug.lo @$(LT_LINK_EXE) $(CFLAGS) -o $@ h5debug.lo $(LIBTOOLS) $(LIBHDF5) $(LDFLAGS) $(LIBS) -h5createU8: h5createU8.lo - @$(LT_LINK_EXE) $(CFLAGS) -o $@ h5createU8.lo $(LIBTOOLS) $(LIBHDF5) $(LDFLAGS) $(LIBS) - h5redeploy: h5redeploy.in $(CP) $(srcdir)/$@.in $@ diff --git a/tools/misc/h5createU8.c b/tools/misc/h5createU8.c deleted file mode 100644 index 0fcc7ed..0000000 --- a/tools/misc/h5createU8.c +++ /dev/null @@ -1,152 +0,0 @@ -/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * - * 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://hdf.ncsa.uiuc.edu/HDF5/doc/Copyright.html. If you do not have * - * access to either file, you may request a copy from hdfhelp@ncsa.uiuc.edu. * - * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ - -/* - * Programmer: Robb Matzke - * Thursday, June 11, 1998 - * - * Purpose: Create an hdf5 file with a 1d dataset of uint8. - */ - -/* See H5private.h for how to include system headers */ -#include -#ifdef H5_STDC_HEADERS -# include -# include -# include -# include -#endif - -#ifdef H5_HAVE_UNISTD_H -# include -# include -#endif - -#ifdef H5_HAVE_SYS_STAT_H -# include -#endif - -#ifdef WIN32 -# include -#endif - - -/*------------------------------------------------------------------------- - * Function: usage - * - * Purpose: Print a usage message and exit with non-zero status - * - * Return: never returns - * - * Programmer: Robb Matzke - * Thursday, June 11, 1998 - * - * Modifications: - * - *------------------------------------------------------------------------- - */ -static void -usage (const char *argv0) -{ - fprintf (stderr, "Usage: %s -f HDF5-FILE FILES...\n", argv0); - exit (1); -} - - -/*------------------------------------------------------------------------- - * Function: main - * - * Purpose: - * - * Return: Success: 0 - * - * Failure: 1 - * - * Programmer: Robb Matzke - * Thursday, June 11, 1998 - * - * Modifications: - * - *------------------------------------------------------------------------- - */ -int -main (int argc, char *argv[]) -{ - hid_t file, space=-1, dset=-1; - const char *output_name, *dset_name; - int argno, fd=-1; - hsize_t size[1]; - struct stat sb; - - /* Parse arguments */ - if (argc<4) usage (argv[0]); - if (strcmp (argv[1], "-f")) usage (argv[0]); - output_name = argv[2]; - - /* create the file */ - H5E_BEGIN_TRY { - if ((file = H5Fcreate (output_name, H5F_ACC_EXCL, - H5P_DEFAULT, H5P_DEFAULT))<0 && - (file = H5Fopen (output_name, H5F_ACC_RDWR, H5P_DEFAULT)<0)) { - fprintf (stderr, "%s: unable to create or open hdf5 file\n", - output_name); - exit (1); - } - } H5E_END_TRY; - - /* process files from command-line */ - for (argno=3; argno=0) close (fd); - fd = -1; - H5E_BEGIN_TRY { - if (space>=0) { - H5Sclose (space); - space = -1; - } - if (dset>=0) { - H5Dclose (dset); - dset = -1; - } - } H5E_END_TRY; - } - - /* Close the file */ - H5Fclose (file); - return 0; -} -- cgit v0.12