From 7a52d6ce9b3e61cfdd3ded845b23daae440a7cfb Mon Sep 17 00:00:00 2001 From: Robb Matzke Date: Fri, 21 Apr 2000 14:28:09 -0500 Subject: [svn-r2180] ./src/tools/h5tools.c Added hyphen to version printf format. ./src/tools/h5ls.c Calls print_version() instead of doing it by hand. --- tools/Dependencies | 110 +++++++++++++++++++++++++++++------------------------ tools/h5ls.c | 8 +--- tools/h5tools.c | 13 +++---- 3 files changed, 67 insertions(+), 64 deletions(-) diff --git a/tools/Dependencies b/tools/Dependencies index f849e01..307a20f 100644 --- a/tools/Dependencies +++ b/tools/Dependencies @@ -1,6 +1,42 @@ ## This file is machine generated on GNU systems. ## Only temporary changes may be made here. +h5tools.lo: \ + $(srcdir)/h5tools.c \ + $(srcdir)/h5tools.h \ + $(top_srcdir)/src/hdf5.h \ + $(top_srcdir)/src/H5public.h \ + $(top_builddir)/src/H5pubconf.h \ + $(top_srcdir)/src/H5api_adpt.h \ + $(top_srcdir)/src/H5Ipublic.h \ + $(top_srcdir)/src/H5Apublic.h \ + $(top_srcdir)/src/H5ACpublic.h \ + $(top_srcdir)/src/H5Bpublic.h \ + $(top_srcdir)/src/H5Dpublic.h \ + $(top_srcdir)/src/H5Epublic.h \ + $(top_srcdir)/src/H5Fpublic.h \ + $(top_srcdir)/src/H5FDpublic.h \ + $(top_srcdir)/src/H5Gpublic.h \ + $(top_srcdir)/src/H5HGpublic.h \ + $(top_srcdir)/src/H5HLpublic.h \ + $(top_srcdir)/src/H5MMpublic.h \ + $(top_srcdir)/src/H5Opublic.h \ + $(top_srcdir)/src/H5Ppublic.h \ + $(top_srcdir)/src/H5Zpublic.h \ + $(top_srcdir)/src/H5Rpublic.h \ + $(top_srcdir)/src/H5RApublic.h \ + $(top_srcdir)/src/H5Spublic.h \ + $(top_srcdir)/src/H5Tpublic.h \ + $(top_srcdir)/src/H5FDcore.h \ + $(top_srcdir)/src/H5FDfamily.h \ + $(top_srcdir)/src/H5FDmpio.h \ + $(top_srcdir)/src/H5FDsec2.h \ + $(top_srcdir)/src/H5FDstdio.h \ + $(top_srcdir)/src/H5FDgass.h \ + $(top_srcdir)/src/H5FDdpss.h \ + $(top_srcdir)/src/H5FDmulti.h \ + $(top_srcdir)/src/H5private.h \ + $(top_builddir)/src/H5config.h h5findshd.lo: \ $(srcdir)/h5findshd.c \ $(top_srcdir)/src/hdf5.h \ @@ -32,6 +68,7 @@ h5findshd.lo: \ $(top_srcdir)/src/H5FDsec2.h \ $(top_srcdir)/src/H5FDstdio.h \ $(top_srcdir)/src/H5FDgass.h \ + $(top_srcdir)/src/H5FDdpss.h \ $(top_srcdir)/src/H5FDmulti.h \ $(top_srcdir)/src/H5private.h \ $(top_builddir)/src/H5config.h @@ -100,6 +137,7 @@ h5import.lo: \ $(top_srcdir)/src/H5FDsec2.h \ $(top_srcdir)/src/H5FDstdio.h \ $(top_srcdir)/src/H5FDgass.h \ + $(top_srcdir)/src/H5FDdpss.h \ $(top_srcdir)/src/H5FDmulti.h h5ls.lo: \ $(srcdir)/h5ls.c \ @@ -134,7 +172,8 @@ h5ls.lo: \ $(top_srcdir)/src/H5FDmpio.h \ $(top_srcdir)/src/H5FDsec2.h \ $(top_srcdir)/src/H5FDstdio.h \ - $(top_srcdir)/src/H5FDgass.h + $(top_srcdir)/src/H5FDgass.h \ + $(top_srcdir)/src/H5FDdpss.h h5repart.lo: \ $(srcdir)/h5repart.c \ $(top_srcdir)/src/hdf5.h \ @@ -166,9 +205,10 @@ h5repart.lo: \ $(top_srcdir)/src/H5FDsec2.h \ $(top_srcdir)/src/H5FDstdio.h \ $(top_srcdir)/src/H5FDgass.h \ + $(top_srcdir)/src/H5FDdpss.h \ $(top_srcdir)/src/H5FDmulti.h -h5dumputil.lo: \ - $(srcdir)/h5dumputil.c \ +h5dump.lo: \ + $(srcdir)/h5dump.c \ $(srcdir)/h5dump.h \ $(top_srcdir)/src/hdf5.h \ $(top_srcdir)/src/H5public.h \ @@ -199,10 +239,13 @@ h5dumputil.lo: \ $(top_srcdir)/src/H5FDsec2.h \ $(top_srcdir)/src/H5FDstdio.h \ $(top_srcdir)/src/H5FDgass.h \ - $(top_srcdir)/src/H5FDmulti.h -h5toh4.lo: \ - $(srcdir)/h5toh4.c \ - $(srcdir)/h5toh4.h \ + $(top_srcdir)/src/H5FDdpss.h \ + $(top_srcdir)/src/H5FDmulti.h \ + $(top_srcdir)/src/H5private.h \ + $(top_builddir)/src/H5config.h +h5dumputil.lo: \ + $(srcdir)/h5dumputil.c \ + $(srcdir)/h5dump.h \ $(top_srcdir)/src/hdf5.h \ $(top_srcdir)/src/H5public.h \ $(top_builddir)/src/H5pubconf.h \ @@ -232,9 +275,11 @@ h5toh4.lo: \ $(top_srcdir)/src/H5FDsec2.h \ $(top_srcdir)/src/H5FDstdio.h \ $(top_srcdir)/src/H5FDgass.h \ + $(top_srcdir)/src/H5FDdpss.h \ $(top_srcdir)/src/H5FDmulti.h -pdb2hdf.lo: \ - $(srcdir)/pdb2hdf.c \ +h5toh4.lo: \ + $(srcdir)/h5toh4.c \ + $(srcdir)/h5toh4.h \ $(top_srcdir)/src/hdf5.h \ $(top_srcdir)/src/H5public.h \ $(top_builddir)/src/H5pubconf.h \ @@ -264,6 +309,7 @@ pdb2hdf.lo: \ $(top_srcdir)/src/H5FDsec2.h \ $(top_srcdir)/src/H5FDstdio.h \ $(top_srcdir)/src/H5FDgass.h \ + $(top_srcdir)/src/H5FDdpss.h \ $(top_srcdir)/src/H5FDmulti.h h5dumptst.lo: \ $(srcdir)/h5dumptst.c \ @@ -296,47 +342,12 @@ h5dumptst.lo: \ $(top_srcdir)/src/H5FDsec2.h \ $(top_srcdir)/src/H5FDstdio.h \ $(top_srcdir)/src/H5FDgass.h \ + $(top_srcdir)/src/H5FDdpss.h \ $(top_srcdir)/src/H5FDmulti.h \ $(top_srcdir)/src/H5private.h \ $(top_builddir)/src/H5config.h -h5tools.lo: \ - $(srcdir)/h5tools.c \ - $(srcdir)/h5tools.h \ - $(top_srcdir)/src/hdf5.h \ - $(top_srcdir)/src/H5public.h \ - $(top_builddir)/src/H5pubconf.h \ - $(top_srcdir)/src/H5api_adpt.h \ - $(top_srcdir)/src/H5Ipublic.h \ - $(top_srcdir)/src/H5Apublic.h \ - $(top_srcdir)/src/H5ACpublic.h \ - $(top_srcdir)/src/H5Bpublic.h \ - $(top_srcdir)/src/H5Dpublic.h \ - $(top_srcdir)/src/H5Epublic.h \ - $(top_srcdir)/src/H5Fpublic.h \ - $(top_srcdir)/src/H5FDpublic.h \ - $(top_srcdir)/src/H5Gpublic.h \ - $(top_srcdir)/src/H5HGpublic.h \ - $(top_srcdir)/src/H5HLpublic.h \ - $(top_srcdir)/src/H5MMpublic.h \ - $(top_srcdir)/src/H5Opublic.h \ - $(top_srcdir)/src/H5Ppublic.h \ - $(top_srcdir)/src/H5Zpublic.h \ - $(top_srcdir)/src/H5Rpublic.h \ - $(top_srcdir)/src/H5RApublic.h \ - $(top_srcdir)/src/H5Spublic.h \ - $(top_srcdir)/src/H5Tpublic.h \ - $(top_srcdir)/src/H5FDcore.h \ - $(top_srcdir)/src/H5FDfamily.h \ - $(top_srcdir)/src/H5FDmpio.h \ - $(top_srcdir)/src/H5FDsec2.h \ - $(top_srcdir)/src/H5FDstdio.h \ - $(top_srcdir)/src/H5FDgass.h \ - $(top_srcdir)/src/H5FDmulti.h \ - $(top_srcdir)/src/H5private.h \ - $(top_builddir)/src/H5config.h -h5dump.lo: \ - $(srcdir)/h5dump.c \ - $(srcdir)/h5dump.h \ +pdb2hdf.lo: \ + $(srcdir)/pdb2hdf.c \ $(top_srcdir)/src/hdf5.h \ $(top_srcdir)/src/H5public.h \ $(top_builddir)/src/H5pubconf.h \ @@ -366,6 +377,5 @@ h5dump.lo: \ $(top_srcdir)/src/H5FDsec2.h \ $(top_srcdir)/src/H5FDstdio.h \ $(top_srcdir)/src/H5FDgass.h \ - $(top_srcdir)/src/H5FDmulti.h \ - $(top_srcdir)/src/H5private.h \ - $(top_builddir)/src/H5config.h + $(top_srcdir)/src/H5FDdpss.h \ + $(top_srcdir)/src/H5FDmulti.h diff --git a/tools/h5ls.c b/tools/h5ls.c index 3692802..d523cf0 100644 --- a/tools/h5ls.c +++ b/tools/h5ls.c @@ -1986,9 +1986,7 @@ main (int argc, char *argv[]) } else if (!strcmp(argv[argno], "--verbose")) { verbose_g++; } else if (!strcmp(argv[argno], "--version")) { - printf("This is %s version %u.%u release %u%s\n", - progname, H5_VERS_MAJOR, H5_VERS_MINOR, H5_VERS_RELEASE, - H5_VERS_SUBRELEASE); + print_version(progname); exit(0); } else if (!strcmp(argv[argno], "--hexdump")) { hexdump_g = TRUE; @@ -2046,9 +2044,7 @@ main (int argc, char *argv[]) verbose_g++; break; case 'V': /* --version */ - printf("This is %s version %u.%u release %u\n", - progname, H5_VERS_MAJOR, H5_VERS_MINOR, - H5_VERS_RELEASE); + print_version(progname); exit(0); case 'x': /* --hexdump */ hexdump_g = TRUE; diff --git a/tools/h5tools.c b/tools/h5tools.c index 8c6391e..9328a44 100644 --- a/tools/h5tools.c +++ b/tools/h5tools.c @@ -1846,17 +1846,14 @@ void indentation(int x) { } } - - - - /* Print the program name and the version information which is */ /* defined the same as the HDF5 library version. */ -void print_version(char *program_name) +void +print_version(char *program_name) { - printf("%s: Version %u.%u.%u%s\n", - program_name, H5_VERS_MAJOR, H5_VERS_MINOR, H5_VERS_RELEASE, - H5_VERS_SUBRELEASE); + printf("%s: Version %u.%u.%u%s%s\n", + program_name, H5_VERS_MAJOR, H5_VERS_MINOR, H5_VERS_RELEASE, + H5_VERS_SUBRELEASE[0]?"-":"", H5_VERS_SUBRELEASE); } -- cgit v0.12