summaryrefslogtreecommitdiffstats
path: root/tools/h5repack/h5repack.c
diff options
context:
space:
mode:
authorPedro Vicente Nunes <pvn@hdfgroup.org>2004-07-13 19:09:41 (GMT)
committerPedro Vicente Nunes <pvn@hdfgroup.org>2004-07-13 19:09:41 (GMT)
commitbc6ab7c0a6ff27d3d52707419385ccd0771ffa0c (patch)
treee21b848fed677413addbdf6bee7fd2240c66c577 /tools/h5repack/h5repack.c
parent803bb3e532c0c2ff26f6b7cc115a8c6f33ea00f5 (diff)
downloadhdf5-bc6ab7c0a6ff27d3d52707419385ccd0771ffa0c.zip
hdf5-bc6ab7c0a6ff27d3d52707419385ccd0771ffa0c.tar.gz
hdf5-bc6ab7c0a6ff27d3d52707419385ccd0771ffa0c.tar.bz2
[svn-r8869] Purpose:
h5repack changes Description: there were some requests to change some minor h5repack features h5repack only made a warning about a non available filter in verbose mode ( -v ) without -v it kept silent, and users sometimes missed this warning the request was that it should print this warning always. so, the new format, is e.g ./h5repack -i test_szip.h5 -o out.h5 Warning: dataset </dset_szip> cannot be read, SZIP filter is not available due to this, and to avoid a lot of these messages in the shell test script, I modified the script h5repack.sh so that it detects the presence of all filters in the environment (previously it only detected SZIP) the test files were also divided in more files , to make the script code easier to follow Solution: Platforms tested: linux AIX (no szip) solaris (no szip, no gzip ) Misc. update:
Diffstat (limited to 'tools/h5repack/h5repack.c')
-rw-r--r--tools/h5repack/h5repack.c29
1 files changed, 15 insertions, 14 deletions
diff --git a/tools/h5repack/h5repack.c b/tools/h5repack/h5repack.c
index cd7a31b..cfd9363 100644
--- a/tools/h5repack/h5repack.c
+++ b/tools/h5repack/h5repack.c
@@ -55,7 +55,7 @@ static void aux_initglb_filter(pack_opt_t *options)
*
* Return: 0, ok, -1, fail
*
- * Programmer: Pedro Vicente, pvn@ncsa.uiuc.edu
+ * Programmer: pvn@ncsa.uiuc.edu
*
* Date: September, 22, 2003
*
@@ -223,7 +223,7 @@ int h5repack_addlayout(const char* str,
*
* Return: void, return -1 on error
*
- * Programmer: Pedro Vicente, pvn@ncsa.uiuc.edu
+ * Programmer: pvn@ncsa.uiuc.edu
*
* Date: September, 22, 2003
*
@@ -243,9 +243,9 @@ static int check_options(pack_opt_t *options)
if (options->verbose)
{
printf("\n");
- printf("Objects to modify are...\n");
+ printf("Objects to modify layout are...\n");
if (options->all_layout==1) {
- printf("\tApply layout to all\n ");
+ printf(" Apply layout to all\n ");
if (H5D_CHUNKED==options->layout_g) {
printf("with dimension [");
for ( j = 0; j < options->chunk_g.rank; j++)
@@ -262,7 +262,7 @@ static int check_options(pack_opt_t *options)
if (options->op_tbl->objs[i].chunk.rank>0)
{
if (options->verbose){
- printf("\t<%s> with chunk size ",name);
+ printf(" <%s> with chunk size ",name);
for ( k = 0; k < options->op_tbl->objs[i].chunk.rank; k++)
printf("%d ",(int)options->op_tbl->objs[i].chunk.chunk_lengths[k]);
printf("\n");
@@ -272,7 +272,7 @@ static int check_options(pack_opt_t *options)
else if (options->op_tbl->objs[i].chunk.rank==-2)
{
if (options->verbose)
- printf("\t%s %s\n",name,"NONE");
+ printf(" <%s> %s\n",name,"NONE");
has_ck=1;
}
}
@@ -284,7 +284,7 @@ static int check_options(pack_opt_t *options)
}
/*-------------------------------------------------------------------------
- * objects to compress/uncompress
+ * objects to filter
*-------------------------------------------------------------------------
*/
@@ -297,10 +297,10 @@ static int check_options(pack_opt_t *options)
switch (filtn)
{
case H5Z_FILTER_NONE:
- printf("\tUncompress all %s\n",get_sfilter(filtn));
+ printf(" Uncompress all %s\n",get_sfilter(filtn));
break;
case H5Z_FILTER_SZIP:
- printf("\tCompress all with %s compression\n",get_sfilter(filtn));
+ printf(" Compress all with %s compression\n",get_sfilter(filtn));
break;
case H5Z_FILTER_DEFLATE:
printf("\tCompress all with %s compression, parameter %d\n",
@@ -314,15 +314,16 @@ static int check_options(pack_opt_t *options)
for ( i = 0; i < options->op_tbl->nelems; i++)
{
pack_info_t pack = options->op_tbl->objs[i];
- char* name = pack.path;
+ char* name = pack.path;
for ( j=0; j<pack.nfilters; j++)
{
if (options->verbose)
{
- printf("\t<%s> with %s filter",
+ printf(" <%s> with %s filter%s",
name,
- get_sfilter(pack.filter[j].filtn));
+ get_sfilter(pack.filter[j].filtn),
+ (i==options->op_tbl->nelems-1)? "" : "\n");
}
has_cp=1;
@@ -355,7 +356,7 @@ static int check_options(pack_opt_t *options)
options->op_tbl->objs[i].filter[j].filtn=-1;
options->op_tbl->objs[i].chunk.rank=-1;
- printf("\tObject <%s> cannot be filtered\n",name);
+ printf(" Object <%s> cannot be filtered\n",name);
}
@@ -380,7 +381,7 @@ static int check_options(pack_opt_t *options)
*
* Return: void, exit on error
*
- * Programmer: Pedro Vicente, pvn@ncsa.uiuc.edu
+ * Programmer: pvn@ncsa.uiuc.edu
*
* Date: September, 22, 2003
*