From 76d7d3cb976feced595c978575f1e46a7b67b223 Mon Sep 17 00:00:00 2001 From: Scot Breitenfeld Date: Mon, 24 Aug 2015 14:22:55 -0500 Subject: [svn-r27570] Fixed issue with REAL max detection. tested: h5committest --- config/cmake/HDF5UseFortran.cmake | 24 +++++++++++++----------- 1 file changed, 13 insertions(+), 11 deletions(-) diff --git a/config/cmake/HDF5UseFortran.cmake b/config/cmake/HDF5UseFortran.cmake index f445f54..8ca10a7 100644 --- a/config/cmake/HDF5UseFortran.cmake +++ b/config/cmake/HDF5UseFortran.cmake @@ -227,9 +227,9 @@ message ( " ........MAX DECIMAL PRECISION ${H5_PAC_FC_MAX_REAL_PRECISION}") # ********** # INTEGERS # ********** -string(REGEX REPLACE "," ";" VAR_KIND "${pac_validIntKinds}") +string(REGEX REPLACE "," ";" VAR "${pac_validIntKinds}") -foreach( KIND ${VAR_KIND} ) +foreach( KIND ${VAR} ) set(PROG_SRC " PROGRAM main @@ -262,14 +262,14 @@ message("...FOUND SIZEOF for INTEGER KINDs ${PAC_FC_ALL_INTEGER_KINDS_SIZEOF}") # ********** # REALS # ********** -string(REGEX REPLACE "," ";" VAR_KIND "${pac_validRealKinds}") +string(REGEX REPLACE "," ";" VAR "${pac_validRealKinds}") #find the maximum kind of the real -list(LENGTH VAR_KIND LEN_VAR_KIND) -MATH (EXPR _LEN "${LEN_VAR_KIND} - 1") -list(GET VAR_KIND ${_LEN} max_real_fortran_kind) +list(LENGTH VAR LEN_VAR) +MATH (EXPR _LEN "${LEN_VAR}-1") +list(GET VAR ${_LEN} max_real_fortran_kind) -foreach( KIND ${VAR_KIND} ) +foreach( KIND ${VAR} ) set(PROG_SRC " PROGRAM main @@ -299,12 +299,14 @@ set(H5CONFIG_F_RKIND_SIZEOF "INTEGER, DIMENSION(1:num_rkinds) :: rkind_sizeof = message("...FOUND SIZEOF for REAL KINDs \{${pack_real_sizeof}\}") +set(PAC_FC_ALL_REAL_KINDS_SIZEOF "\{${pack_real_sizeof}\}") + #find the maximum kind of the real -list(LENGTH VAR_KIND LEN_VAR_KIND) -MATH (EXPR _LEN "${LEN_VAR_KIND} - 1") -list(GET VAR_KIND ${_LEN} max_real_fortran_sizeof) +string(REGEX REPLACE "," ";" VAR "${pack_real_sizeof}") +list(LENGTH VAR LEN_VAR) +MATH (EXPR _LEN "${LEN_VAR}-1") +list(GET VAR ${_LEN} max_real_fortran_sizeof) -set(PAC_FC_ALL_REAL_KINDS_SIZEOF "\{${pack_real_sizeof}\}") #----------------------------------------------------------------------------- # Find sizeof of native kinds #----------------------------------------------------------------------------- -- cgit v0.12 From 2e6100fb23e496cab62ce81a3e08719563c61dc1 Mon Sep 17 00:00:00 2001 From: Dana Robinson Date: Mon, 24 Aug 2015 15:19:39 -0500 Subject: [svn-r27572] Removed VMS-specific code from the library. The only remaining code consists of a few floating-point tests that rely on pre-generated and checked-in VMS files. These have been left alone, even though they will not be possible to recreate, since testing VMS float behavior is still important. Tested on: h5committest --- MANIFEST | 1 - README.txt | 2 +- bin/chkcopyright | 43 --------------- c++/src/H5IdComponent.cpp | 6 --- c++/test/tfile.cpp | 12 ++--- c++/test/tlinks.cpp | 61 --------------------- fortran/src/H5f90proto.h | 3 -- release_docs/INSTALL_VMS.txt | 77 --------------------------- src/H5FDcore.c | 22 -------- src/H5FDdirect.c | 15 ------ src/H5FDlog.c | 24 +-------- src/H5FDsec2.c | 22 +------- src/H5FDstdio.c | 15 ------ src/H5Lexternal.c | 2 - src/H5Tconv.c | 7 ++- src/H5private.h | 35 ++---------- src/H5system.c | 62 +--------------------- test/H5srcdir.h | 16 ------ test/dt_arith.c | 118 ++--------------------------------------- test/dtypes.c | 4 -- test/fheap.c | 2 - test/flush2.c | 4 -- test/gen_cross.c | 4 ++ test/getname.c | 2 - test/lheap.c | 4 -- test/links.c | 29 +--------- test/links_env.c | 4 -- test/objcopy.c | 2 - test/stab.c | 2 - test/tconfig.c | 9 ---- test/tfile.c | 14 +---- test/th5o.c | 2 - test/tsohm.c | 3 -- tools/lib/h5diff_array.c | 22 -------- tools/lib/h5tools_str.c | 4 -- tools/perform/sio_standalone.h | 11 ---- tools/perform/zip_perf.c | 9 ---- 37 files changed, 27 insertions(+), 647 deletions(-) delete mode 100644 release_docs/INSTALL_VMS.txt diff --git a/MANIFEST b/MANIFEST index b506522..b18c4ee 100644 --- a/MANIFEST +++ b/MANIFEST @@ -422,7 +422,6 @@ ./release_docs/INSTALL_CMake.txt ./release_docs/INSTALL_Cygwin.txt ./release_docs/INSTALL_parallel -./release_docs/INSTALL_VMS.txt ./release_docs/INSTALL_Windows.txt ./release_docs/RELEASE.txt ./release_docs/USING_HDF5_CMake.txt diff --git a/README.txt b/README.txt index 4d1b59a..a78bec1 100644 --- a/README.txt +++ b/README.txt @@ -8,7 +8,7 @@ specific to this release of the library. Several INSTALL* files can also be found in the release_docs/ directory: INSTALL contains instructions for compiling and installing the library; INSTALL_parallel contains instructions for installing the parallel version of the library; similarly-named files -contain instructions for VMS and several environments on MS Windows systems. +contain instructions for several environments on MS Windows systems. Documentation for this release can be found at the following URL: http://www.hdfgroup.org/HDF5/doc/. diff --git a/bin/chkcopyright b/bin/chkcopyright index fe9fe49..07fcb24 100755 --- a/bin/chkcopyright +++ b/bin/chkcopyright @@ -56,7 +56,6 @@ HTM_COPYRIGHT=/tmp/h5chkright_HTM.$$ # HTML style copyright SH_COPYRIGHT=/tmp/h5chkright_SH.$$ # SHELL style copyright SH_COPYRIGHT2=/tmp/h5chkright_SH2.$$ # SHELL style copyright, 2nd style. WINBAT_COPYRIGHT=/tmp/h5chkright_WINBAT.$$ # Windows Batch file Copyright notice -VMSCMD_COPYRIGHT=/tmp/h5chkright_VMSCMD.$$ # VMS command file Copyright notice CONFIGURE_AC_COPYRIGHT=/tmp/h5chkright_CONFIGURE_AC.$$ # configure.ac file Copyright notice tmpfixfile=/tmp/h5chkright_fix.$$ # Temporary fixed copy of file @@ -223,22 +222,6 @@ dnl http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have dnl access to either file, you may request a copy from help@hdfgroup.org. EOF - # VMS command file Copyright notice - cat > ${VMSCMD_COPYRIGHT} << \EOF -$!# 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. -EOF - } # Initialization @@ -611,28 +594,6 @@ BATCH_FILE() } -# Check Windows Batch files -# -VMSCMD_FILE() -{ - f=$1 - case `MATCH_COPYRIGHT $VMSCMD_COPYRIGHT $f` in - PASSED) - PASSED $f - return - ;; - FAILED) - # show the difference - FAILED $f - $DIFF ${EXTRACTEDFILE} ${VMSCMD_COPYRIGHT} - if [ -n "$FIXIT" ]; then - FIX_COPYRIGHT $VMSCMD_COPYRIGHT $f - fi - ;; - esac -} - - # Check Configure.in type files # CONFIGURE_AC_FILE() @@ -834,10 +795,6 @@ while read file; do # Windows Batch files BATCH_FILE ${file} ;; - *.com ) - # VMS Command files - VMSCMD_FILE ${file} - ;; *.h5 | *.hdf5 ) # Ignore HDF5 data files continue diff --git a/c++/src/H5IdComponent.cpp b/c++/src/H5IdComponent.cpp index c01d41e..bcd69c4 100644 --- a/c++/src/H5IdComponent.cpp +++ b/c++/src/H5IdComponent.cpp @@ -285,15 +285,9 @@ IdComponent::~IdComponent() {} //-------------------------------------------------------------------------- H5std_string IdComponent::inMemFunc(const char* func_name) const { -#ifdef H5_VMS - H5std_string full_name = fromClass(); - full_name.append("::"); - full_name.append(func_name); -#else H5std_string full_name = func_name; full_name.insert(0, "::"); full_name.insert(0, fromClass()); -#endif /*H5_VMS*/ return (full_name); } diff --git a/c++/test/tfile.cpp b/c++/test/tfile.cpp index f3bbb16..f84ce3a 100644 --- a/c++/test/tfile.cpp +++ b/c++/test/tfile.cpp @@ -109,9 +109,7 @@ static void test_file_create() file1 = new H5File (FILE1, H5F_ACC_EXCL); // Try to create the same file with H5F_ACC_TRUNC. This should fail - // because file1 is the same file and is currently open. Skip it on - // OpenVMS because it creates another version of the file. -#ifndef H5_HAVE_FILE_VERSIONS + // because file1 is the same file and is currently open. try { H5File file2 (FILE1, H5F_ACC_TRUNC); // should throw E @@ -120,7 +118,6 @@ static void test_file_create() } catch( FileIException E ) // catch truncating existing file {} // do nothing, FAIL expected -#endif // H5_HAVE_FILE_VERSIONS // Close file1 delete file1; @@ -141,9 +138,7 @@ static void test_file_create() file1 = new H5File (FILE1, H5F_ACC_TRUNC); // Try to create first file again. This should fail because file1 - // is the same file and is currently open. Skip it on OpenVMS because - // it creates another version of the file. -#ifndef H5_HAVE_FILE_VERSIONS + // is the same file and is currently open. try { H5File file2 (FILE1, H5F_ACC_TRUNC); // should throw E @@ -154,7 +149,7 @@ static void test_file_create() {} // do nothing, FAIL expected // Try with H5F_ACC_EXCL. This should fail too because the file already - // exists. Skip it on OpenVMS because it creates another version of the file. + // exists. try { H5File file3 (FILE1, H5F_ACC_EXCL); // should throw E @@ -163,7 +158,6 @@ static void test_file_create() } catch( FileIException E ) // catching H5F_ACC_EXCL on existing file {} // do nothing, FAIL expected -#endif /*H5_HAVE_FILE_VERSIONS*/ // Get the file-creation template FileCreatPropList tmpl1 = file1->getCreatePlist(); diff --git a/c++/test/tlinks.cpp b/c++/test/tlinks.cpp index 291b649..33d10ea 100644 --- a/c++/test/tlinks.cpp +++ b/c++/test/tlinks.cpp @@ -58,60 +58,6 @@ /* File for external link test. Created with gen_udlinks.c */ #define LINKED_FILE "be_extlink2.h5" -#ifdef H5_VMS -#if 0 -const char *FILENAME[] = { - "links0", - "links1", - "links2", - "links3", - "links4a", /* 4 */ - "links4b", /* 5 */ - "links4c", /* 6 */ - "links4d", /* 7 */ - "links5", /* 8 */ - "links6", /* 9 */ - "links7", /* 10 */ - "links8", /* 11 */ - "extlinks0", /* 12: main files */ - "[.tmp]extlinks0", /* 13: */ - "extlinks1", /* 14: target files */ - "[.tmp]extlinks1", /* 15: */ - "extlinks2", /* 16: */ - "[.tmp]extlinks2", /* 17: */ - "extlinks3", /* 18: */ - "[.tmp]extlinks3", /* 19: */ - "extlinks4", /* 20: */ - "[.tmp]extlinks4", /* 21: */ - "extlinks5", /* 22: */ - "[.tmp]extlinks6", /* 23: */ - "extlinks7", /* 24: */ - "[.tmp]extlinks7", /* 25: */ - "[.tmp]extlinks8", /* 26: */ - "extlinks9", /* 27: */ - "[.tmp]extlinks9", /* 28: */ - "extlinks10", /* 29: */ /* TESTS for windows */ - "[.tmp]extlinks10", /* 30: */ - "[.tmp]extlinks11", /* 31: */ - "[.tmp]extlinks12", /* 32: */ - "extlinks13", /* 33: */ - "[.tmp]extlinks13", /* 34: */ - "[.tmp]extlinks14", /* 35: */ - "[.tmp]extlinks15", /* 36: */ - "extlinks16A", /* 37: */ /* TESTS for H5P_set_elink_fapl */ - "extlinks16B", /* 38: */ - "extlinks17", /* 39: */ - "extlinks18A", /* 40: */ - "extlinks18B", /* 41: */ - "extlinks19A", /* 42: */ - "extlinks19B", /* 43: */ - "extlinks20", /* 44: */ - NULL -}; -#endif // 0 - -#define TMPDIR "[.tmp]" -#else #if 0 const char *FILENAME[] = { "links0", @@ -165,7 +111,6 @@ const char *FILENAME[] = { #endif // 0 #define TMPDIR "tmp" -#endif #define FAMILY_SIZE 1024 #define CORE_INCREMENT 1024 @@ -574,16 +519,12 @@ void test_links() #ifndef H5_NO_DEPRECATED_SYMBOLS nerrors += test_deprec(my_fapl, new_format); #endif /* H5_NO_DEPRECATED_SYMBOLS */ -#ifndef H5_CANNOT_OPEN_TWICE nerrors += external_link_root(my_fapl, new_format) < 0 ? 1 : 0; -#endif /* H5_CANNOT_OPEN_TWICE */ nerrors += external_link_path(my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_mult(my_fapl, new_format) < 0 ? 1 : 0; -#ifndef H5_CANNOT_OPEN_TWICE nerrors += external_link_self(envval, my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_pingpong(envval, my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_toomany(my_fapl, new_format) < 0 ? 1 : 0; -#endif /* H5_CANNOT_OPEN_TWICE */ nerrors += external_link_dangling(my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_recursive(my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_query(my_fapl, new_format) < 0 ? 1 : 0; @@ -591,9 +532,7 @@ void test_links() nerrors += external_link_unlink_dense(my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_move(my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_ride(my_fapl, new_format) < 0 ? 1 : 0; -#ifndef H5_CANNOT_OPEN_TWICE nerrors += external_link_closing(envval, my_fapl, new_format) < 0 ? 1 : 0; -#endif /* H5_CANNOT_OPEN_TWICE */ nerrors += external_link_endian(new_format) < 0 ? 1 : 0; nerrors += external_link_strong(my_fapl, new_format) < 0 ? 1 : 0; diff --git a/fortran/src/H5f90proto.h b/fortran/src/H5f90proto.h index b26e985..a07db22 100644 --- a/fortran/src/H5f90proto.h +++ b/fortran/src/H5f90proto.h @@ -23,9 +23,6 @@ H5_FCDLL char * HD5f2cstring (_fcd fdesc, size_t len); H5_FCDLL void HD5packFstring(char *src, char *dest, size_t len); -#ifdef H5_VMS -#define H5_FC_FUNC_(name, NAME) NAME -#endif /*H5_VMS*/ /* * Storage info struct used by H5O_info_t and H5F_info_t diff --git a/release_docs/INSTALL_VMS.txt b/release_docs/INSTALL_VMS.txt deleted file mode 100644 index c2a1463..0000000 --- a/release_docs/INSTALL_VMS.txt +++ /dev/null @@ -1,77 +0,0 @@ - Building and installation instructions for Alpha Open VMS - HDF5 1.8.6 release - 18 February 2011 - - - - CONTENTS - -------- - - 1. Obtaining HDF5 - 2. Building and testing HDF5 C, Fortran and C++ libraries, - and utilities - 3. Installing HDF5 libraries - 4. Known problems - - - 1.Obtaining HDF5 - - Please see INSTALL file in this directory for downloading instructions. - - 2. Building and testing HDF5 C, Fortran and C++ libraries and utilities. - - IMPORTANT: This version REQUIRES GNU ZLIB library to be installed - on a system. You may download the source code from - http://www.zlib.net/ - - - Use tar command to untar HDF5 source ball - - tar -xvf .tar - - - Change default directory to [..vms] - - Specify top HDF5 source directory in the build.com file - - Edit make.com: - specify path to ZLIB library - if necessary, modify compilation flags - Do NOT REMOVE /define=H5_VMS and /standard=strict_ansi qualifiers. - - Run build.com command file - @build - We recommend using batch queue to build and test this distribution. - The command file runs make.com and builds - C library, tests, and utilities - Fortran library and tests - C++ library and tests - It also runs test scripts to test C, Fortran and C++ libraries, and - h5dump, h5diff, h5ls, h5repack and h5import utilities. - - 3. Installing HDF5 libraries - - Modify install.com file to specify installation directory and run - @install - to install HDF5 C, Fortran, and C++ libraries, and utilities. - The script will create the directories shown below in the - installation directory: - - [.HDF5]... - [.HDF5.INCLUDE] - [.HDF5.LIB] - [.HDF5.BIN] - [.HDF5.EXAMPLES] - [.HDF5.EXAMPLES.C] - [.HDF5.EXAMPLES.F90] - [.HDF5.EXAMPLES.CXX] - - [.HDF5.EXAMPLES.*] directories contain make.com and check.com files - to build examples against the installed libraries and to verify - the installation. - - 3. Known problems - - - dsets test fails for test_scleoffset_double and - test_scleoffset_double_2 tests when G_FLOAT double is used - - There is no support for szip compression filter. - - Fortran multifile driver test fails; similar C test passes. - - - For help contact help@hdfgroup.org - diff --git a/src/H5FDcore.c b/src/H5FDcore.c index 32f23fb..e553f6b 100644 --- a/src/H5FDcore.c +++ b/src/H5FDcore.c @@ -65,11 +65,7 @@ typedef struct H5FD_core_t { * identify a file. */ dev_t device; /*file device number */ -#ifdef H5_VMS - ino_t inode[3]; /*file i-node number */ -#else ino_t inode; /*file i-node number */ -#endif /*H5_VMS*/ #else /* Files in windows are uniquely identified by the volume serial * number and the file index (both low and high parts). @@ -741,14 +737,7 @@ H5FD_core_open(const char *name, unsigned flags, hid_t fapl_id, haddr_t maxaddr) file->dwVolumeSerialNumber = fileinfo.dwVolumeSerialNumber; #else /* H5_HAVE_WIN32_API */ file->device = sb.st_dev; -#ifdef H5_VMS - file->inode[0] = sb.st_ino[0]; - file->inode[1] = sb.st_ino[1]; - file->inode[2] = sb.st_ino[2]; -#else file->inode = sb.st_ino; -#endif /* H5_VMS */ - #endif /* H5_HAVE_WIN32_API */ } /* end if */ @@ -981,13 +970,8 @@ H5FD_core_cmp(const H5FD_t *_f1, const H5FD_t *_f2) if(HDmemcmp(&(f1->device),&(f2->device),sizeof(dev_t))>0) HGOTO_DONE(1) #endif /* H5_DEV_T_IS_SCALAR */ -#ifndef H5_VMS if (f1->inode < f2->inode) HGOTO_DONE(-1) if (f1->inode > f2->inode) HGOTO_DONE(1) -#else - if(HDmemcmp(&(f1->inode),&(f2->inode),3*sizeof(ino_t))<0) HGOTO_DONE(-1) - if(HDmemcmp(&(f1->inode),&(f2->inode),3*sizeof(ino_t))>0) HGOTO_DONE(1) -#endif /* H5_VMS */ #endif /*H5_HAVE_WIN32_API*/ } /* end if */ @@ -1523,12 +1507,6 @@ H5FD_core_truncate(H5FD_t *_file, hid_t H5_ATTR_UNUSED dxpl_id, hbool_t closing) if(0 == bError) HGOTO_ERROR(H5E_IO, H5E_SEEKERROR, FAIL, "unable to extend file properly") #else /* H5_HAVE_WIN32_API */ -#ifdef H5_VMS - /* Reset seek offset to the beginning of the file, so that the file isn't - * re-extended later. This may happen on Open VMS. */ - if(-1 == HDlseek(file->fd, (HDoff_t)0, SEEK_SET)) - HSYS_GOTO_ERROR(H5E_IO, H5E_SEEKERROR, FAIL, "unable to seek to proper position") -#endif /* H5_VMS */ if(-1 == HDftruncate(file->fd, (HDoff_t)new_eof)) HSYS_GOTO_ERROR(H5E_IO, H5E_SEEKERROR, FAIL, "unable to extend file properly") #endif /* H5_HAVE_WIN32_API */ diff --git a/src/H5FDdirect.c b/src/H5FDdirect.c index e9fd1ea..f4ee910 100644 --- a/src/H5FDdirect.c +++ b/src/H5FDdirect.c @@ -83,11 +83,7 @@ typedef struct H5FD_direct_t { * identify a file. */ dev_t device; /*file device number */ -#ifdef H5_VMS - ino_t inode[3]; /*file i-node number */ -#else ino_t inode; /*file i-node number */ -#endif /*H5_VMS*/ #else /* * On H5_HAVE_WIN32_API the low-order word of a unique identifier associated with the @@ -525,13 +521,7 @@ H5FD_direct_open(const char *name, unsigned flags, hid_t fapl_id, haddr_t maxadd file->fileindexlo = fileinfo.nFileIndexLow; #else file->device = sb.st_dev; -#ifdef H5_VMS - file->inode[0] = sb.st_ino[0]; - file->inode[1] = sb.st_ino[1]; - file->inode[2] = sb.st_ino[2]; -#else file->inode = sb.st_ino; -#endif /*H5_VMS*/ #endif /*H5_HAVE_WIN32_API*/ file->fa.mboundary = fa->mboundary; file->fa.fbsize = fa->fbsize; @@ -673,13 +663,8 @@ H5FD_direct_cmp(const H5FD_t *_f1, const H5FD_t *_f2) if(HDmemcmp(&(f1->device),&(f2->device),sizeof(dev_t))>0) HGOTO_DONE(1) #endif /* H5_DEV_T_IS_SCALAR */ -#ifndef H5_VMS if (f1->inode < f2->inode) HGOTO_DONE(-1) if (f1->inode > f2->inode) HGOTO_DONE(1) -#else - if(HDmemcmp(&(f1->inode),&(f2->inode),3*sizeof(ino_t))<0) HGOTO_DONE(-1) - if(HDmemcmp(&(f1->inode),&(f2->inode),3*sizeof(ino_t))>0) HGOTO_DONE(1) -#endif /*H5_VMS*/ #endif diff --git a/src/H5FDlog.c b/src/H5FDlog.c index d2289fd..e8695c5 100644 --- a/src/H5FDlog.c +++ b/src/H5FDlog.c @@ -92,11 +92,7 @@ typedef struct H5FD_log_t { * Windows code further below. */ dev_t device; /* file device number */ -#ifdef H5_VMS - ino_t inode[3]; /* file i-node number */ -#else ino_t inode; /* file i-node number */ -#endif /*H5_VMS*/ #else /* Files in windows are uniquely identified by the volume serial * number and the file index (both low and high parts). @@ -587,14 +583,7 @@ H5FD_log_open(const char *name, unsigned flags, hid_t fapl_id, haddr_t maxaddr) file->dwVolumeSerialNumber = fileinfo.dwVolumeSerialNumber; #else /* H5_HAVE_WIN32_API */ file->device = sb.st_dev; -#ifdef H5_VMS - file->inode[0] = sb.st_ino[0]; - file->inode[1] = sb.st_ino[1]; - file->inode[2] = sb.st_ino[2]; -#else file->inode = sb.st_ino; -#endif /*H5_VMS*/ - #endif /* H5_HAVE_WIN32_API */ /* Retain a copy of the name used to open the file, for possible error reporting */ @@ -867,13 +856,8 @@ H5FD_log_cmp(const H5FD_t *_f1, const H5FD_t *_f2) if(HDmemcmp(&(f1->device),&(f2->device),sizeof(dev_t)) > 0) HGOTO_DONE(1) #endif /* H5_DEV_T_IS_SCALAR */ -#ifndef H5_VMS if(f1->inode < f2->inode) HGOTO_DONE(-1) if(f1->inode > f2->inode) HGOTO_DONE(1) -#else - if(HDmemcmp(&(f1->inode), &(f2->inode), 3 * sizeof(ino_t)) < 0) HGOTO_DONE(-1) - if(HDmemcmp(&(f1->inode), &(f2->inode), 3 * sizeof(ino_t)) > 0) HGOTO_DONE(1) -#endif /*H5_VMS*/ #endif @@ -1553,13 +1537,6 @@ H5FD_log_truncate(H5FD_t *_file, hid_t H5_ATTR_UNUSED dxpl_id, hbool_t H5_ATTR_U if(0 == bError) HGOTO_ERROR(H5E_IO, H5E_SEEKERROR, FAIL, "unable to extend file properly") #else /* H5_HAVE_WIN32_API */ -#ifdef H5_VMS - /* Reset seek offset to the beginning of the file, so that the file isn't - * re-extended later. This may happen on Open VMS. */ - if(-1 == HDlseek(file->fd, (HDoff_t)0, SEEK_SET)) - HSYS_GOTO_ERROR(H5E_IO, H5E_SEEKERROR, FAIL, "unable to seek to proper position") -#endif - if(-1 == HDftruncate(file->fd, (HDoff_t)file->eoa)) HSYS_GOTO_ERROR(H5E_IO, H5E_SEEKERROR, FAIL, "unable to extend file properly") #endif /* H5_HAVE_WIN32_API */ @@ -1579,3 +1556,4 @@ H5FD_log_truncate(H5FD_t *_file, hid_t H5_ATTR_UNUSED dxpl_id, hbool_t H5_ATTR_U done: FUNC_LEAVE_NOAPI(ret_value) } /* end H5FD_log_truncate() */ + diff --git a/src/H5FDsec2.c b/src/H5FDsec2.c index 73dd7a0..10e2a66 100644 --- a/src/H5FDsec2.c +++ b/src/H5FDsec2.c @@ -69,11 +69,7 @@ typedef struct H5FD_sec2_t { * Windows code further below. */ dev_t device; /* file device number */ -#ifdef H5_VMS - ino_t inode[3]; /* file i-node number */ -#else ino_t inode; /* file i-node number */ -#endif /* H5_VMS */ #else /* Files in windows are uniquely identified by the volume serial * number and the file index (both low and high parts). @@ -374,13 +370,7 @@ H5FD_sec2_open(const char *name, unsigned flags, hid_t fapl_id, haddr_t maxaddr) file->dwVolumeSerialNumber = fileinfo.dwVolumeSerialNumber; #else /* H5_HAVE_WIN32_API */ file->device = sb.st_dev; -#ifdef H5_VMS - file->inode[0] = sb.st_ino[0]; - file->inode[1] = sb.st_ino[1]; - file->inode[2] = sb.st_ino[2]; -#else /* H5_VMS */ file->inode = sb.st_ino; -#endif /* H5_VMS */ #endif /* H5_HAVE_WIN32_API */ /* Retain a copy of the name used to open the file, for possible error reporting */ @@ -501,13 +491,8 @@ H5FD_sec2_cmp(const H5FD_t *_f1, const H5FD_t *_f2) if(HDmemcmp(&(f1->device),&(f2->device),sizeof(dev_t)) < 0) HGOTO_DONE(-1) if(HDmemcmp(&(f1->device),&(f2->device),sizeof(dev_t)) > 0) HGOTO_DONE(1) #endif /* H5_DEV_T_IS_SCALAR */ -#ifdef H5_VMS - if(HDmemcmp(&(f1->inode), &(f2->inode), 3 * sizeof(ino_t)) < 0) HGOTO_DONE(-1) - if(HDmemcmp(&(f1->inode), &(f2->inode), 3 * sizeof(ino_t)) > 0) HGOTO_DONE(1) -#else /* H5_VMS */ if(f1->inode < f2->inode) HGOTO_DONE(-1) if(f1->inode > f2->inode) HGOTO_DONE(1) -#endif /* H5_VMS */ #endif /* H5_HAVE_WIN32_API */ done: @@ -901,12 +886,6 @@ H5FD_sec2_truncate(H5FD_t *_file, hid_t H5_ATTR_UNUSED dxpl_id, hbool_t H5_ATTR_ if(0 == bError) HGOTO_ERROR(H5E_IO, H5E_SEEKERROR, FAIL, "unable to extend file properly") #else /* H5_HAVE_WIN32_API */ -#ifdef H5_VMS - /* Reset seek offset to the beginning of the file, so that the file isn't - * re-extended later. This may happen on Open VMS. */ - if(-1 == HDlseek(file->fd, (HDoff_t)0, SEEK_SET)) - HSYS_GOTO_ERROR(H5E_IO, H5E_SEEKERROR, FAIL, "unable to seek to proper position") -#endif if(-1 == HDftruncate(file->fd, (HDoff_t)file->eoa)) HSYS_GOTO_ERROR(H5E_IO, H5E_SEEKERROR, FAIL, "unable to extend file properly") #endif /* H5_HAVE_WIN32_API */ @@ -922,3 +901,4 @@ H5FD_sec2_truncate(H5FD_t *_file, hid_t H5_ATTR_UNUSED dxpl_id, hbool_t H5_ATTR_ done: FUNC_LEAVE_NOAPI(ret_value) } /* end H5FD_sec2_truncate() */ + diff --git a/src/H5FDstdio.c b/src/H5FDstdio.c index 8e7eaf4..65b75a3 100644 --- a/src/H5FDstdio.c +++ b/src/H5FDstdio.c @@ -97,11 +97,7 @@ typedef struct H5FD_stdio_t { * Windows code further below. */ dev_t device; /* file device number */ -#ifdef H5_VMS - ino_t inode[3]; /* file i-node number */ -#else ino_t inode; /* file i-node number */ -#endif /* H5_VMS */ #else /* Files in windows are uniquely identified by the volume serial * number and the file index (both low and high parts). @@ -450,13 +446,7 @@ H5FD_stdio_open( const char *name, unsigned flags, hid_t fapl_id, H5Epush_ret(func, H5E_ERR_CLS, H5E_FILE, H5E_BADFILE, "unable to fstat file", NULL) } /* end if */ file->device = sb.st_dev; -#ifdef H5_VMS - file->inode[0] = sb.st_ino[0]; - file->inode[1] = sb.st_ino[1]; - file->inode[2] = sb.st_ino[2]; -#else /* H5_VMS */ file->inode = sb.st_ino; -#endif /* H5_VMS */ #endif /* H5_HAVE_WIN32_API */ return (H5FD_t*)file; @@ -542,13 +532,8 @@ H5FD_stdio_cmp(const H5FD_t *_f1, const H5FD_t *_f2) if(memcmp(&(f1->device),&(f2->device),sizeof(dev_t)) < 0) return -1; if(memcmp(&(f1->device),&(f2->device),sizeof(dev_t)) > 0) return 1; #endif /* H5_DEV_T_IS_SCALAR */ -#ifdef H5_VMS - if(memcmp(&(f1->inode), &(f2->inode), 3 * sizeof(ino_t)) < 0) return -1; - if(memcmp(&(f1->inode), &(f2->inode), 3 * sizeof(ino_t)) > 0) return 1; -#else /* H5_VMS */ if(f1->inode < f2->inode) return -1; if(f1->inode > f2->inode) return 1; -#endif /* H5_VMS */ #endif /* H5_HAVE_WIN32_API */ return 0; diff --git a/src/H5Lexternal.c b/src/H5Lexternal.c index ae13e6b..08d401e 100644 --- a/src/H5Lexternal.c +++ b/src/H5Lexternal.c @@ -125,8 +125,6 @@ H5L_getenv_prefix_name(char **env_prefix/*in,out*/) * * Programmer: Vailin Choi, April 2, 2008 * - * Modification: Raymond Lu, 14 Jan. 2009 - * Added support for OpenVMS pathname --------------------------------------------------------------------------*/ static herr_t H5L_build_name(char *prefix, char *file_name, char **full_name/*out*/) diff --git a/src/H5Tconv.c b/src/H5Tconv.c index b14f6e5..6847e68 100644 --- a/src/H5Tconv.c +++ b/src/H5Tconv.c @@ -4255,7 +4255,11 @@ H5T__conv_f_f(hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata, size_t nelmts, HGOTO_ERROR(H5E_DATATYPE, H5E_CANTCONVERT, FAIL, "can't handle conversion exception") goto padding; -#ifndef H5_VMS /*Temporary solution to handle VAX special values*/ + /* Temporary solution to handle VAX special values. + * Note that even though we don't support VAX anymore, we + * still need to handle legacy VAX files so this code must + * remain in place. + */ } else if (H5T__bit_find (s, src.u.f.epos, src.u.f.esize, H5T_BIT_LSB, FALSE)<0) { /* NaN */ @@ -4280,7 +4284,6 @@ H5T__conv_f_f(hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata, size_t nelmts, HGOTO_ERROR(H5E_DATATYPE, H5E_CANTCONVERT, FAIL, "can't handle conversion exception") goto padding; -#endif /*H5_VMS*/ } /* diff --git a/src/H5private.h b/src/H5private.h index 9efd145..65726da 100644 --- a/src/H5private.h +++ b/src/H5private.h @@ -1130,22 +1130,9 @@ H5_DLL int HDfprintf (FILE *stream, const char *fmt, ...); #ifndef HDrealpath #define HDrealpath(F1,F2) realpath(F1,F2) #endif /* HDrealloc */ -#ifdef H5_VMS - #ifdef __cplusplus - extern "C" { - #endif /* __cplusplus */ - int HDremove_all(const char * fname); - #ifdef __cplusplus - } - #endif /* __cplusplus */ - #ifndef HDremove - #define HDremove(S) HDremove_all(S) - #endif /* HDremove */ -#else /* H5_VMS */ - #ifndef HDremove - #define HDremove(S) remove(S) - #endif /* HDremove */ -#endif /*H5_VMS*/ +#ifndef HDremove + #define HDremove(S) remove(S) +#endif /* HDremove */ #ifndef HDrename #define HDrename(OLD,NEW) rename(OLD,NEW) #endif /* HDrename */ @@ -1562,19 +1549,7 @@ extern char *strdup(const char *s); (ptr = slash); \ } -#elif defined(H5_HAVE_VMS_PATH) - -/* OpenVMS pathname: $:[path] - * i.g. SYS$SYSUSERS:[LU.HDF5.SRC]H5system.c */ -#define H5_DIR_SEPC ']' -#define H5_DIR_SEPS "]" -#define H5_CHECK_DELIMITER(SS) (SS == H5_DIR_SEPC) -#define H5_CHECK_ABSOLUTE(NAME) (HDstrrchr(NAME, ':') && HDstrrchr(NAME, '[')) -#define H5_CHECK_ABS_DRIVE(NAME) (0) -#define H5_CHECK_ABS_PATH(NAME) (0) -#define H5_GET_LAST_DELIMITER(NAME, ptr) ptr = HDstrrchr(NAME, H5_DIR_SEPC); - -#else +#else /* H5_HAVE_WINDOW_PATH */ #define H5_DIR_SEPC '/' #define H5_DIR_SEPS "/" @@ -1584,7 +1559,7 @@ extern char *strdup(const char *s); #define H5_CHECK_ABS_PATH(NAME) (0) #define H5_GET_LAST_DELIMITER(NAME, ptr) ptr = HDstrrchr(NAME, H5_DIR_SEPC); -#endif +#endif /* H5_HAVE_WINDOW_PATH */ #define H5_COLON_SEPC ':' diff --git a/src/H5system.c b/src/H5system.c index 56db380..e00e5a5 100644 --- a/src/H5system.c +++ b/src/H5system.c @@ -582,45 +582,8 @@ void HDsrand(unsigned int seed) { g_seed = seed; } -#endif +#endif /* H5_HAVE_RAND_R */ - -/*------------------------------------------------------------------------- - * Function: HDremove_all - * - * Purpose: Wrapper function for remove on VMS systems - * - * This function deletes all versions of a file - * - * Return: Success: 0; - * - * Failure: -1 - * - * Programmer: Elena Pourmal - * March 22, 2006 - * - *------------------------------------------------------------------------- - */ -#ifdef H5_VMS -int -HDremove_all(const char *fname) -{ - int ret_value = -1; - size_t fname_len; - char *_fname; - - fname_len = HDstrlen(fname) + 3; /* to accomodate ";*" and null terminator */ - _fname = (char *)H5MM_malloc(fname_len); - if(_fname) { - HDsnprintf(_fname, fname_len, "%s;*", fname); - /* Do not use HDremove; function becomes recursive (see H5private.h file)*/ - remove(_fname); - H5MM_xfree(_fname); - ret_value = 0; - } - return ret_value; -} -#endif /*------------------------------------------------------------------------- * Function: Wgettimeofday @@ -764,8 +727,6 @@ H5_build_extpath(const char *name, char **extpath/*out*/) /* * Unix: name[0] is a "/" * Windows: name[0-2] is ":\" or ":/" - * OpenVMS: $:[path] - * i.g. SYS$SYSUSERS:[LU.HDF5.SRC]H5system.c */ if(H5_CHECK_ABSOLUTE(name)) { if(NULL == (full_path = (char *)H5MM_strdup(name))) @@ -786,7 +747,6 @@ H5_build_extpath(const char *name, char **extpath/*out*/) * Windows: name[0-1] is ":" * Get current working directory on the drive specified in NAME * Unix: does not apply - * OpenVMS: does not apply */ if(H5_CHECK_ABS_DRIVE(name)) { drive = name[0] - 'A' + 1; @@ -797,14 +757,13 @@ H5_build_extpath(const char *name, char **extpath/*out*/) * Windows: name[0] is a '/' or '\' * Get current drive * Unix: does not apply - * OpenVMS: does not apply */ else if(H5_CHECK_ABS_PATH(name) && (0 != (drive = HDgetdrive()))) { HDsnprintf(cwdpath, MAX_PATH_LEN, "%c:%c", (drive + 'A' - 1), name[0]); retcwd = cwdpath; HDstrncpy(new_name, &name[1], name_len); } - /* totally relative for Unix, Windows, and OpenVMS: get current working directory */ + /* totally relative for Unix and Windows: get current working directory */ else { retcwd = HDgetcwd(cwdpath, MAX_PATH_LEN); HDstrncpy(new_name, name, name_len); @@ -823,26 +782,9 @@ H5_build_extpath(const char *name, char **extpath/*out*/) HGOTO_ERROR(H5E_INTERNAL, H5E_NOSPACE, FAIL, "memory allocation failed") HDstrncpy(full_path, cwdpath, cwdlen + 1); -#ifdef H5_VMS - /* If the file name contains relative path, cut off the beginning bracket. Also cut off the - * ending bracket of CWDPATH to combine the full path name. i.g. - * cwdpath = SYS$SYSUSERS:[LU.HDF5.TEST] - * new_name = [.tmp]extlinks.h5 - * full_path = SYS$SYSUSERS:[LU.HDF5.TEST.tmp]extlinks.h5 - */ - if(new_name[0] == '[') { - char *tmp = new_name; - - full_path[cwdlen - 1] = '\0'; - HDstrncat(full_path, ++tmp, HDstrlen(tmp)); - } /* end if */ - else - HDstrncat(full_path, new_name, HDstrlen(new_name)); -#else if(!H5_CHECK_DELIMITER(cwdpath[cwdlen - 1])) HDstrncat(full_path, H5_DIR_SEPS, HDstrlen(H5_DIR_SEPS)); HDstrncat(full_path, new_name, HDstrlen(new_name)); -#endif } /* end if */ } /* end else */ diff --git a/test/H5srcdir.h b/test/H5srcdir.h index 4f0f439..81624d8 100644 --- a/test/H5srcdir.h +++ b/test/H5srcdir.h @@ -32,11 +32,7 @@ static char srcdir_path[1024] = ""; static char srcdir_testpath[1024] = ""; /* Append the test file name to the srcdir path and return the whole string */ -#ifdef H5_VMS -static const char *H5_get_srcdir_filename(char *filename) -#else static const char *H5_get_srcdir_filename(const char *filename) -#endif { const char *srcdir = HDgetenv("srcdir"); @@ -46,19 +42,7 @@ static const char *H5_get_srcdir_filename(const char *filename) /* Build path to test file */ if((HDstrlen(srcdir) + HDstrlen(filename) + 2) < sizeof(srcdir_testpath)) { -#ifdef H5_VMS - HDstrcpy(srcdir_testpath, srcdir); - if(filename[0] == '[') { - char *tmp = filename; - - srcdir_testpath[HDstrlen(srcdir) - 1] = '\0'; - HDstrcat(srcdir_testpath, ++tmp); - } /* end if */ - else - HDstrcat(srcdir_testpath, filename); -#else HDsnprintf(srcdir_testpath, sizeof(srcdir_testpath), "%s/%s", srcdir, filename); -#endif return(srcdir_testpath); } /* end if */ else diff --git a/test/dt_arith.c b/test/dt_arith.c index b3f5cad..eb201d0 100644 --- a/test/dt_arith.c +++ b/test/dt_arith.c @@ -58,10 +58,9 @@ const char *FILENAME[] = { }; /* - * Count up or down depending on whether the machine is big endian, little - * endian, or VAX (OpenVMS). If local variable `endian' is H5T_ORDER_BE then - * the result will be I, otherwise the result will be Z-(I+1). VAX is printed - * as little endian. + * Count up or down depending on whether the machine is big endian or little + * endian. If local variable `endian' is H5T_ORDER_BE then the result will + * be I, otherwise the result will be Z-(I+1). */ #define ENDIAN(Z,I,E) (H5T_ORDER_BE==E?(I):(Z)-((I)+1)) @@ -88,11 +87,6 @@ static int skip_overflow_tests_g = 0; #define HANDLE_SIGFPE #endif -/* OpenVMS doesn't have this feature. Make sure to disable it*/ -#ifdef H5_VMS -#undef HANDLE_SIGFPE -#endif - /* * Decide what values of floating-point number we want to test. They are * 1 - normalized; 2 - denormalized; 3 - special. @@ -2740,24 +2734,6 @@ my_isnan(dtype_t type, void *val) retval = 1; } -#ifdef H5_VMS - /* For "float" and "double" on OpenVMS/Alpha, NaN is - * actually a valid value of maximal value.*/ - if(!retval) { - if (FLT_FLOAT==type) { - float x; - HDmemcpy(&x, val, sizeof(float)); - retval = (x==FLT_MAX || x==-FLT_MAX); - } else if (FLT_DOUBLE==type) { - double x; - HDmemcpy(&x, val, sizeof(double)); - retval = (x==DBL_MAX || x==-DBL_MAX); - } else { - return 0; - } - } -#endif /*H5_VMS*/ - return retval; } @@ -2786,23 +2762,8 @@ my_isinf(int endian, unsigned char *val, size_t size, bits = (unsigned char*)HDcalloc((size_t)1, size); -#ifdef H5_VMS - if(H5T_ORDER_VAX==endian) { - for (i = 0; i < size; i += 4) { - bits[i] = val[(size-2)-i]; - bits[i+1] = val[(size-1)-i]; - - bits[(size-2)-i] = val[i]; - bits[(size-1)-i] = val[i+1]; - } - } else { - for (i=0; i FLT_MAX; -#ifdef H5_VMS - maximal = HDfabs(*((double*)aligned)) == FLT_MAX; -#endif } else if (FLT_DOUBLE==dst_type) { hw_d = *((double*)aligned); hw = (unsigned char*)&hw_d; @@ -3149,17 +3074,11 @@ test_conv_flt_1 (const char *name, int run_test, hid_t src, hid_t dst) hw = (unsigned char*)&hw_f; underflow = HDfabsl(*((long double*)aligned)) < FLT_MIN; overflow = HDfabsl(*((long double*)aligned)) > FLT_MAX; -#ifdef H5_VMS - maximal = HDfabs(*((long double*)aligned)) == FLT_MAX; -#endif } else if (FLT_DOUBLE==dst_type) { hw_d = *((long double*)aligned); hw = (unsigned char*)&hw_d; underflow = HDfabsl(*((long double*)aligned)) < DBL_MIN; overflow = HDfabsl(*((long double*)aligned)) > DBL_MAX; -#ifdef H5_VMS - maximal = HDfabs(*((long double*)aligned)) == DBL_MAX; -#endif } else { hw_ld = *((long double*)aligned); hw = (unsigned char*)&hw_ld; @@ -3194,17 +3113,6 @@ test_conv_flt_1 (const char *name, int run_test, hid_t src, hid_t dst) if (k==dst_size) continue; /*no error*/ -#ifdef H5_VMS - /* For "float" and "double" on OpenVMS/Alpha, NaN is - * a valid value of maximal value.*/ - if (FLT_FLOAT==src_type && - my_isnan(src_type, saved+j*sizeof(float))) { - continue; - } else if (FLT_DOUBLE==src_type && - my_isnan(src_type, saved+j*sizeof(double))) { - continue; - } -#endif /*H5_VMS*/ /* * Assume same if both results are NaN. There are many NaN bit @@ -3262,11 +3170,6 @@ test_conv_flt_1 (const char *name, int run_test, hid_t src, hid_t dst) if (overflow && my_isinf(dendian, buf+j*sizeof(float), dst_size, dst_mpos, dst_msize, dst_epos, dst_esize)) continue; /* all overflowed, no error */ -#ifdef H5_VMS - if (maximal && my_isinf(dendian, buf+j*sizeof(float), - dst_size, dst_mpos, dst_msize, dst_epos, dst_esize)) - continue; /* maximal value, no error */ -#endif /*H5_VMS*/ check_mant[0] = HDfrexpf(x, check_expo+0); check_mant[1] = HDfrexpf(hw_f, check_expo+1); } else if (FLT_DOUBLE==dst_type) { @@ -3278,11 +3181,6 @@ test_conv_flt_1 (const char *name, int run_test, hid_t src, hid_t dst) if (overflow && my_isinf(dendian, buf+j*sizeof(double), dst_size, dst_mpos, dst_msize, dst_epos, dst_esize)) continue; /* all overflowed, no error */ -#ifdef H5_VMS - if (maximal && my_isinf(dendian, buf+j*sizeof(double), - dst_size, dst_mpos, dst_msize, dst_epos, dst_esize)) - continue; /* maximal value, no error */ -#endif /*H5_VMS*/ check_mant[0] = HDfrexp(x, check_expo+0); check_mant[1] = HDfrexp(hw_d, check_expo+1); #if H5_SIZEOF_LONG_DOUBLE !=0 && (H5_SIZEOF_LONG_DOUBLE!=H5_SIZEOF_DOUBLE) @@ -4924,7 +4822,6 @@ run_fp_tests(const char *name) nerrors += test_conv_flt_1(name, TEST_NORMAL, H5T_NATIVE_LDOUBLE, H5T_NATIVE_DOUBLE); #endif -#ifndef H5_VMS /*Test denormalized values. TEST_DENORM indicates denormalized values.*/ nerrors += test_conv_flt_1(name, TEST_DENORM, H5T_NATIVE_FLOAT, H5T_NATIVE_DOUBLE); nerrors += test_conv_flt_1(name, TEST_DENORM, H5T_NATIVE_DOUBLE, H5T_NATIVE_FLOAT); @@ -4944,7 +4841,6 @@ run_fp_tests(const char *name) nerrors += test_conv_flt_1(name, TEST_SPECIAL, H5T_NATIVE_LDOUBLE, H5T_NATIVE_FLOAT); nerrors += test_conv_flt_1(name, TEST_SPECIAL, H5T_NATIVE_LDOUBLE, H5T_NATIVE_DOUBLE); #endif -#endif /*H5_VMS*/ done: return nerrors; @@ -5085,11 +4981,7 @@ run_fp_int_conv(const char *name) int nerrors = 0; int test_values; -#ifdef H5_VMS - test_values = TEST_NORMAL; -#else for(test_values = TEST_NORMAL; test_values <= TEST_SPECIAL; test_values++) { -#endif /*H5_VMS*/ nerrors += test_conv_int_fp(name, test_values, H5T_NATIVE_FLOAT, H5T_NATIVE_SCHAR); nerrors += test_conv_int_fp(name, test_values, H5T_NATIVE_DOUBLE, H5T_NATIVE_SCHAR); @@ -5194,9 +5086,7 @@ run_fp_int_conv(const char *name) #endif /*H5_LDOUBLE_TO_LLONG_ACCURATE*/ #endif #endif -#ifndef H5_VMS } /* end for */ -#endif /* H5_VMS */ return nerrors; } @@ -5248,10 +5138,8 @@ main(void) * for user-defined integer types */ nerrors += test_derived_integer(); -#ifndef H5_VMS /* Does floating point overflow generate a SIGFPE? */ generates_sigfpe(); -#endif /* Test degenerate cases */ nerrors += run_fp_tests("noop"); diff --git a/test/dtypes.c b/test/dtypes.c index 59cf000..88bbce0 100644 --- a/test/dtypes.c +++ b/test/dtypes.c @@ -3233,11 +3233,7 @@ test_compound_18(void) /* Open Generated File */ /* (generated with gen_bad_compound.c) */ -#ifdef H5_VMS - if((file = H5Fopen(TESTFILE, H5F_ACC_RDONLY, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR -#else if((file = H5Fopen(testfile, H5F_ACC_RDONLY, H5P_DEFAULT)) < 0) FAIL_STACK_ERROR -#endif /* Try to open the datatype */ H5E_BEGIN_TRY { diff --git a/test/fheap.c b/test/fheap.c index fee6fdf..c300028 100644 --- a/test/fheap.c +++ b/test/fheap.c @@ -16418,9 +16418,7 @@ curr_test = FHEAP_TEST_NORMAL; nerrors += test_id_limits(fapl, &small_cparam); nerrors += test_filtered_create(fapl, &small_cparam); nerrors += test_size(fapl, &small_cparam); -#ifndef H5_CANNOT_OPEN_TWICE nerrors += test_reopen_hdr(fapl, &small_cparam); -#endif /*H5_CANNOT_OPEN_TWICE*/ #else /* QAK */ HDfprintf(stderr, "Uncomment tests!\n"); #endif /* QAK */ diff --git a/test/flush2.c b/test/flush2.c index 28ce41e..0ee299e 100644 --- a/test/flush2.c +++ b/test/flush2.c @@ -189,8 +189,6 @@ main(void) #if defined H5_HAVE_WIN32_API && !defined (hdf5_EXPORTS) SKIPPED(); puts(" DLL will flush the file even when calling _exit, skip this test temporarily"); -#elif defined H5_VMS - SKIPPED(); #else H5_FAILED() goto error; @@ -212,8 +210,6 @@ main(void) #if defined H5_HAVE_WIN32_API && !defined (hdf5_EXPORTS) SKIPPED(); puts(" DLL will flush the file even when calling _exit, skip this test temporarily"); -#elif defined H5_VMS - SKIPPED(); #else H5_FAILED() goto error; diff --git a/test/gen_cross.c b/test/gen_cross.c index 1c73016..2d4b788 100644 --- a/test/gen_cross.c +++ b/test/gen_cross.c @@ -22,6 +22,10 @@ * Run it on an OpenVMS, a little-endian, and a big-endian machine. Change the * output file names to vms_data.h5, le_data.h5, and be_data.h5, and put them * under hdf5/test/ directory. + * + * Note that we no longer support OpenVMS. The OpenVMS file will eventually + * have to go away since we won't be able to re-create it but it's probably + * worth keeping around for now. */ #include diff --git a/test/getname.c b/test/getname.c index dc1ddbe..e1bbc6b 100644 --- a/test/getname.c +++ b/test/getname.c @@ -2995,9 +2995,7 @@ main(void) nerrors += test_main(file_id, fapl); nerrors += test_obj_ref(fapl); nerrors += test_reg_ref(fapl); -#ifndef H5_CANNOT_OPEN_TWICE nerrors += test_elinks(fapl); -#endif /*H5_CANNOT_OPEN_TWICE*/ /* Close file */ H5Fclose(file_id); diff --git a/test/lheap.c b/test/lheap.c index bdb6360..492316e 100644 --- a/test/lheap.c +++ b/test/lheap.c @@ -179,11 +179,7 @@ main(void) { const char *testfile = H5_get_srcdir_filename(TESTFILE); /* Corrected test file name */ hid_t dset = -1; -#ifdef H5_VMS - file = H5Fopen(TESTFILE, H5F_ACC_RDONLY, H5P_DEFAULT); -#else file = H5Fopen(testfile, H5F_ACC_RDONLY, H5P_DEFAULT); -#endif if(file >= 0){ if((dset = H5Dopen2(file, "/Dataset1", H5P_DEFAULT)) < 0) TEST_ERROR diff --git a/test/links.c b/test/links.c index cfbc4a1..ef71be7 100644 --- a/test/links.c +++ b/test/links.c @@ -36,13 +36,8 @@ /* File for external link test. Created with gen_udlinks.c */ #define LINKED_FILE "be_extlink2.h5" -#ifdef H5_VMS -#define TMPDIR "[.tmp]" -#define TMPDIR2 "[.tmp2]" -#else /* H5_VMS */ #define TMPDIR "tmp/" #define TMPDIR2 "tmp2/" -#endif /* H5_VMS */ /* Symlinks for external link symlink test */ #define SYMLINK1 TMPDIR "sym1.h5" @@ -320,7 +315,7 @@ typedef struct { * Function: fix_ext_filename * * Purpose: Internal function to append path to file name. It handles - * path name of Unix, Windows, and OpenVMS. + * path name of Unix and Windows. * * Return: void * @@ -333,17 +328,8 @@ fix_ext_filename(char *path_name, char *cwd, const char *file_name) { HDstrcpy(path_name, cwd); -#ifdef H5_VMS - if(file_name[0] == '[') { - char *tmp = file_name; - path_name[strlen(cwd)-1] = '\0'; - HDstrcat(path_name, ++tmp); - } else - HDstrcat(path_name, file_name); -#else HDstrcat(path_name, "/"); HDstrcat(path_name, file_name); -#endif } @@ -2877,7 +2863,6 @@ external_link_abs_mainpath(hid_t fapl, hbool_t new_format) * set up name for main file: * Linux: "/CWD/tmp/extlinks0" * Window: ":/CWD/tmp/extlinks0" - * OpenVMS: "$:[CWD.tmp]extlinks0" */ fix_ext_filename(tmpname, cwdpath, FILENAME[13]); h5_fixname(tmpname, fapl, filename1, sizeof filename1); @@ -6943,7 +6928,6 @@ external_file_cache(hid_t fapl, hbool_t new_format) /* Verify that all files are now closed */ H5F_sfile_assert_num(0); -#ifndef H5_CANNOT_OPEN_TWICE /* * Test 5: 3 file cycle */ @@ -7045,7 +7029,6 @@ external_file_cache(hid_t fapl, hbool_t new_format) /* Verify that all files are now closed */ H5F_sfile_assert_num(0); -#endif /* H5_CANNOT_OPEN_TWICE */ /* Close fapl */ H5Pclose(my_fapl); @@ -14580,15 +14563,11 @@ main(void) printf("\n---Testing without external file cache---\n"); } /* end else */ -#ifndef H5_CANNOT_OPEN_TWICE nerrors += external_link_root(my_fapl, new_format) < 0 ? 1 : 0; -#endif /* H5_CANNOT_OPEN_TWICE */ nerrors += external_link_path(my_fapl, new_format) < 0 ? 1 : 0; -#ifndef H5_CANNOT_OPEN_TWICE nerrors += external_link_self(my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_pingpong(my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_toomany(my_fapl, new_format) < 0 ? 1 : 0; -#endif /* H5_CANNOT_OPEN_TWICE */ nerrors += external_link_dangling(my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_recursive(my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_query(my_fapl, new_format) < 0 ? 1 : 0; @@ -14596,9 +14575,7 @@ main(void) nerrors += external_link_unlink_dense(my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_move(my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_link_ride(my_fapl, new_format) < 0 ? 1 : 0; -#ifndef H5_CANNOT_OPEN_TWICE nerrors += external_link_closing(my_fapl, new_format) < 0 ? 1 : 0; -#endif /* H5_CANNOT_OPEN_TWICE */ nerrors += external_link_endian(new_format) < 0 ? 1 : 0; nerrors += external_link_strong(my_fapl, new_format) < 0 ? 1 : 0; @@ -14628,9 +14605,7 @@ main(void) nerrors += external_symlink(env_h5_drvr, my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_copy_invalid_object(my_fapl, new_format) < 0 ? 1 : 0; nerrors += external_dont_fail_to_source(my_fapl, new_format) < 0 ? 1 : 0; -#ifndef H5_CANNOT_OPEN_TWICE nerrors += external_open_twice(my_fapl, new_format) < 0 ? 1 : 0; -#endif /* H5_CANNOT_OPEN_TWICE */ } /* end for */ /* These tests assume that external links are a form of UD links, @@ -14654,9 +14629,7 @@ main(void) nerrors += obj_visit_by_name(my_fapl, new_format) < 0 ? 1 : 0; nerrors += obj_visit_stop(my_fapl, new_format) < 0 ? 1 : 0; nerrors += link_filters(my_fapl, new_format) < 0 ? 1 : 0; -#ifndef H5_CANNOT_OPEN_TWICE nerrors += obj_exists(my_fapl, new_format) < 0 ? 1 : 0; -#endif /* H5_CANNOT_OPEN_TWICE */ /* Keep this test last, it's testing files that are used above */ /* do not do this for files used by external link tests */ diff --git a/test/links_env.c b/test/links_env.c index 308d562..6e47667 100644 --- a/test/links_env.c +++ b/test/links_env.c @@ -25,11 +25,7 @@ #include "H5Iprivate.h" /* IDs */ #include "H5Lprivate.h" /* Links */ -#ifdef H5_VMS -#define TMPDIR "[.tmp]" -#else /* H5_VMS */ #define TMPDIR "tmp/" -#endif /* H5_VMS */ #define NAME_BUF_SIZE 1024 const char *FILENAME[] = { diff --git a/test/objcopy.c b/test/objcopy.c index e84e70c..a73beb3 100644 --- a/test/objcopy.c +++ b/test/objcopy.c @@ -12276,9 +12276,7 @@ main(void) nerrors += test_copy_group_wide_loop(fcpl_src, fcpl_dst, src_fapl, dst_fapl); nerrors += test_copy_group_links(fcpl_src, fcpl_dst, src_fapl, dst_fapl); nerrors += test_copy_soft_link(fcpl_src, fcpl_dst, src_fapl, dst_fapl); -#ifndef H5_CANNOT_OPEN_TWICE nerrors += test_copy_ext_link(fcpl_src, fcpl_dst, src_fapl, dst_fapl); -#endif /* H5_CANNOT_OPEN_TWICE */ nerrors += test_copy_exist(fcpl_src, fcpl_dst, src_fapl, dst_fapl); nerrors += test_copy_path(fcpl_src, fcpl_dst, src_fapl, dst_fapl); diff --git a/test/stab.c b/test/stab.c index 48b58b1..95e9722 100644 --- a/test/stab.c +++ b/test/stab.c @@ -57,8 +57,6 @@ const char *FILENAME[] = { /* The group_old.h5 is generated from gen_old_fill.c in HDF5 'test' directory * for version 1.6. To get this data file, simply compile gen_old_group.c with * the HDF5 library in that branch and run it. */ -/* I changed the name "group_old.h5.copy" to "group_old_copy.h5" because OpenVMS - * doesn't like any file name with more than one ".". SLU 2010/12/13 */ #define FILE_OLD_GROUPS "group_old.h5" #define FILE_OLD_GROUPS_COPY "group_old_copy.h5" diff --git a/test/tconfig.c b/test/tconfig.c index f3ac242..14c863e 100644 --- a/test/tconfig.c +++ b/test/tconfig.c @@ -60,13 +60,6 @@ void test_exit_definitions(void); * Programmer: Albert Cheng * September 25, 2001 * - * Modifications: - * Raymond Lu - * 16 Dec 2009 - * On Boeing's OpenVMS, the value of EXIT_FAILURE is 268435458. - * (The test is in test_exit_definitions.) Their document says - * it's supposed to be 2. I commented it out for OpenVMS for - * further consideration. *------------------------------------------------------------------------- */ void @@ -75,9 +68,7 @@ test_configure(void) /* Output message about test being performed */ MESSAGE(5, ("Testing configure definitions\n")); test_config_ctypes(); -#ifndef H5_VMS test_exit_definitions(); -#endif } diff --git a/test/tfile.c b/test/tfile.c index 52c8fd9..4913a15 100644 --- a/test/tfile.c +++ b/test/tfile.c @@ -181,19 +181,15 @@ test_file_create(void) * try to create the same file with H5F_ACC_TRUNC. This should fail * because fid1 is the same file and is currently open. */ -#ifndef H5_HAVE_FILE_VERSIONS fid2 = H5Fcreate(FILE1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); VERIFY(fid2, FAIL, "H5Fcreate"); -#endif /*H5_DONT_HAVE_FILE_VERSIONS*/ /* Close all files */ ret = H5Fclose(fid1); CHECK(ret, FAIL, "H5Fclose"); -#ifndef H5_HAVE_FILE_VERSIONS ret = H5Fclose(fid2); VERIFY(ret, FAIL, "H5Fclose"); /*file should not have been open */ -#endif /*H5_HAVE_FILE_VERSIONS*/ /* * Try again with H5F_ACC_EXCL. This should fail because the file already @@ -206,7 +202,6 @@ test_file_create(void) fid1 = H5Fcreate(FILE1, H5F_ACC_TRUNC, H5P_DEFAULT, H5P_DEFAULT); CHECK(fid1, FAIL, "H5Fcreate"); -#ifndef H5_HAVE_FILE_VERSIONS /* * Try to truncate first file again. This should fail because fid1 is the * same file and is currently open. @@ -220,7 +215,6 @@ test_file_create(void) */ fid2 = H5Fcreate(FILE1, H5F_ACC_EXCL, H5P_DEFAULT, H5P_DEFAULT); VERIFY(fid2, FAIL, "H5Fcreate"); -#endif /*H5_HAVE_FILE_VERSIONS*/ /* Get the file-creation template */ tmpl1 = H5Fget_create_plist(fid1); @@ -1370,7 +1364,6 @@ test_file_perm(void) ret = H5Dclose(dset); CHECK(ret, FAIL, "H5Dclose"); -#ifndef H5_CANNOT_OPEN_TWICE /* Open the file (with read-only permission) */ filero = H5Fopen(FILE2, H5F_ACC_RDONLY, H5P_DEFAULT); CHECK(filero, FAIL, "H5Fopen"); @@ -1387,7 +1380,6 @@ test_file_perm(void) ret = H5Fclose(filero); CHECK(ret, FAIL, "H5Fclose"); -#endif /*H5_CANNOT_OPEN_TWICE*/ ret = H5Fclose(file); CHECK(ret, FAIL, "H5Fclose"); @@ -2364,7 +2356,7 @@ test_rw_noupdate(void) /* Check That Timestamps Are Equal */ if(diff > 0.0F) { /* Output message about test being performed */ - MESSAGE(1, ("Testing to verify that nothing is written if nothing is changed: This test is skipped on this system because the modification time from stat is the same as the last access time (We know OpenVMS behaves in this way).\n")); + MESSAGE(1, ("Testing to verify that nothing is written if nothing is changed: This test is skipped on this system because the modification time from stat is the same as the last access time.\n")); } /* end if */ else { hid_t file_id; /* HDF5 File ID */ @@ -3660,16 +3652,12 @@ test_file(void) test_file_freespace(); /* Test file free space information */ test_file_ishdf5(); /* Test detecting HDF5 files correctly */ test_file_open_dot(); /* Test opening objects with "." for a name */ -#ifndef H5_CANNOT_OPEN_TWICE test_file_open_overlap(); /* Test opening files in an overlapping manner */ -#endif /*H5_CANNOT_OPEN_TWICE*/ test_file_getname(); /* Test basic H5Fget_name() functionality */ -#ifndef H5_CANNOT_OPEN_TWICE test_file_double_root_open(); /* Test opening root group from two files works properly */ test_file_double_group_open(); /* Test opening same group from two files works properly */ test_file_double_dataset_open(); /* Test opening same dataset from two files works properly */ test_file_double_datatype_open(); /* Test opening same named datatype from two files works properly */ -#endif /*H5_CANNOT_OPEN_TWICE*/ test_userblock_file_size(); /* Tests that files created with a userblock have the correct size */ test_cached_stab_info(); /* Tests that files are created with cached stab info in the superblock */ test_rw_noupdate(); /* Test to ensure that RW permissions don't write the file unless dirtied */ diff --git a/test/th5o.c b/test/th5o.c index be3b4ab..40844fa 100644 --- a/test/th5o.c +++ b/test/th5o.c @@ -1355,9 +1355,7 @@ test_h5o(void) test_h5o_link(); /* Test object link routine */ test_h5o_comment(); /* Test routines for comment */ test_h5o_comment_by_name(); /* Test routines for comment by name */ -#ifndef H5_CANNOT_OPEN_TWICE /* OpenVMS can't open a file twice */ test_h5o_getinfo_same_file(); /* Test info for objects in the same file */ -#endif /* H5_CANNOT_OPEN_TWICE */ } /* test_h5o() */ diff --git a/test/tsohm.c b/test/tsohm.c index 9da655e..e22940f 100644 --- a/test/tsohm.c +++ b/test/tsohm.c @@ -3988,10 +3988,7 @@ test_sohm(void) test_sohm_delete(); /* Test deleting shared messages */ test_sohm_delete_revert(); /* Test that a file with SOHMs becomes an * empty file again when they are deleted. */ -#ifndef H5_CANNOT_OPEN_TWICE /* On VMS this test fails since it tries to - open target file the second time */ test_sohm_extlink(); /* Test SOHMs when external links are used */ -#endif /* H5_CANNOT_OPEN_TWICE */ test_sohm_extend_dset(); /* Test extending shared datasets */ test_sohm_external_dtype(); /* Test using datatype in another file */ diff --git a/tools/lib/h5diff_array.c b/tools/lib/h5diff_array.c index cfd171a..71ada53 100644 --- a/tools/lib/h5diff_array.c +++ b/tools/lib/h5diff_array.c @@ -6090,28 +6090,6 @@ my_isnan(dtype_t type, void *val) } } -#ifdef H5_VMS - /* For "float" and "double" on OpenVMS/Alpha, NaN is - * actually a valid value of maximal value.*/ - if(!retval) - { - if (FLT_FLOAT==type) - { - float x; - - HDmemcpy(&x, val, sizeof(float)); - retval = (x==FLT_MAX || x==-FLT_MAX); - } else if (FLT_DOUBLE==type) { - double x; - - HDmemcpy(&x, val, sizeof(double)); - retval = (x==DBL_MAX || x==-DBL_MAX); - } else - { - return FALSE; - } - } -#endif /*H5_VMS*/ h5difftrace("my_isnan finish\n"); return retval; diff --git a/tools/lib/h5tools_str.c b/tools/lib/h5tools_str.c index 470620f..b61ed34 100644 --- a/tools/lib/h5tools_str.c +++ b/tools/lib/h5tools_str.c @@ -860,11 +860,7 @@ h5tools_str_sprint(h5tools_str_t *str, const h5tool_format_t *info, hid_t contai else tempchar = (tempchar >> packed_data_offset) & packed_data_mask; } - #ifdef H5_VMS - h5tools_str_append(str, OPT(info->fmt_schar, "%hd"), tempchar); - #else h5tools_str_append(str, OPT(info->fmt_schar, "%hhd"), tempchar); - #endif } } /* end if (sizeof(char) == nsize) */ else if (sizeof(int) == nsize) { diff --git a/tools/perform/sio_standalone.h b/tools/perform/sio_standalone.h index 4eb1ded..8f52eba 100644 --- a/tools/perform/sio_standalone.h +++ b/tools/perform/sio_standalone.h @@ -322,18 +322,7 @@ H5_DLL int HDrand(void); #define HDread(F,M,Z) read(F,M,Z) #define HDreaddir(D) readdir(D) #define HDrealloc(M,Z) realloc(M,Z) -#ifdef H5_VMS -#ifdef __cplusplus -extern "C" { -#endif -int HDremove_all(const char * fname); -#ifdef __cplusplus -} -#endif -#define HDremove(S) HDremove_all(S) -#else #define HDremove(S) remove(S) -#endif /*H5_VMS*/ #define HDrename(OLD,NEW) rename(OLD,NEW) #define HDrewind(F) rewind(F) #define HDrewinddir(D) rewinddir(D) diff --git a/tools/perform/zip_perf.c b/tools/perform/zip_perf.c index f73ba40..d025602 100644 --- a/tools/perform/zip_perf.c +++ b/tools/perform/zip_perf.c @@ -30,15 +30,6 @@ #include -#ifdef VMS -# define unlink delete -#endif /* VMS */ - -#ifdef RISCOS -# define unlink remove -# define fileno(file) file->__file -#endif /* RISCOS */ - #define ONE_KB 1024 #define ONE_MB (ONE_KB * ONE_KB) #define ONE_GB (ONE_MB * ONE_KB) -- cgit v0.12 From 8aef26f78594fc4f642e3bf5f170867c64839d2c Mon Sep 17 00:00:00 2001 From: Allen Byrne Date: Tue, 25 Aug 2015 09:14:12 -0500 Subject: [svn-r27575] lowercase commands --- config/cmake_ext_mod/grepTest.cmake | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/config/cmake_ext_mod/grepTest.cmake b/config/cmake_ext_mod/grepTest.cmake index 579d855..5f07134 100644 --- a/config/cmake_ext_mod/grepTest.cmake +++ b/config/cmake_ext_mod/grepTest.cmake @@ -27,7 +27,7 @@ endif (NOT TEST_REFERENCE) message (STATUS "COMMAND: ${TEST_PROGRAM} ${TEST_ARGS}") # run the test program, capture the stdout/stderr and the result var -EXECUTE_PROCESS ( +execute_process ( COMMAND ${TEST_PROGRAM} ${TEST_ARGS} WORKING_DIRECTORY ${TEST_FOLDER} RESULT_VARIABLE TEST_RESULT @@ -44,16 +44,16 @@ message (STATUS "COMMAND Error: ${TEST_ERROR}") file (READ ${TEST_FOLDER}/${TEST_OUTPUT} TEST_STREAM) # TEST_REFERENCE should always be matched -STRING(REGEX MATCH "${TEST_REFERENCE}" TEST_MATCH ${TEST_STREAM}) -STRING(COMPARE EQUAL "${TEST_REFERENCE}" "${TEST_MATCH}" TEST_RESULT) +string (REGEX MATCH "${TEST_REFERENCE}" TEST_MATCH ${TEST_STREAM}) +string (COMPARE EQUAL "${TEST_REFERENCE}" "${TEST_MATCH}" TEST_RESULT) if (${TEST_RESULT} STREQUAL "0") message (FATAL_ERROR "Failed: The output of ${TEST_PROGRAM} did not contain ${TEST_REFERENCE}") endif (${TEST_RESULT} STREQUAL "0") -STRING(REGEX MATCH "${TEST_FILTER}" TEST_MATCH ${TEST_STREAM}) +string (REGEX MATCH "${TEST_FILTER}" TEST_MATCH ${TEST_STREAM}) if (${TEST_EXPECT} STREQUAL "1") # TEST_EXPECT (1) interperts TEST_FILTER as NOT to match - STRING(LENGTH "${TEST_MATCH}" TEST_RESULT) + string (LENGTH "${TEST_MATCH}" TEST_RESULT) if (NOT ${TEST_RESULT} STREQUAL "0") message (FATAL_ERROR "Failed: The output of ${TEST_PROGRAM} did contain ${TEST_FILTER}") endif (NOT ${TEST_RESULT} STREQUAL "0") -- cgit v0.12 From 4939ee241909f476bc25ad6f3a7f7ee56c443fa8 Mon Sep 17 00:00:00 2001 From: Scot Breitenfeld Date: Tue, 25 Aug 2015 16:49:36 -0500 Subject: [svn-r27580] Fix for: HDFFV-9283 Add H5Dget_offset fortran wrapper tested: h5committest --- fortran/src/H5Dff.F90 | 3 +- fortran/src/H5_f.c | 15 +++-- fortran/src/H5_ff.F90 | 11 ++-- fortran/src/H5f90global.F90 | 12 ++++ fortran/src/H5f90proto.h | 9 +-- fortran/test/fortranlib_test.f90 | 2 + fortran/test/tH5D.f90 | 120 ++++++++++++++++++++++++++++++++++++++- 7 files changed, 155 insertions(+), 17 deletions(-) diff --git a/fortran/src/H5Dff.F90 b/fortran/src/H5Dff.F90 index afdb5ba..e44d90e 100644 --- a/fortran/src/H5Dff.F90 +++ b/fortran/src/H5Dff.F90 @@ -1094,8 +1094,7 @@ CONTAINS offset = h5dget_offset(dset_id) - hdferr = 0 - IF(offset .LT. 0) hdferr = -1 + hdferr = 0 ! never returns a function error because C API never returns a function error. END SUBROUTINE h5dget_offset_f diff --git a/fortran/src/H5_f.c b/fortran/src/H5_f.c index e527dce..f3bc42f 100644 --- a/fortran/src/H5_f.c +++ b/fortran/src/H5_f.c @@ -436,11 +436,12 @@ h5close_types_c( hid_t_f * types, int_f *lentypes, */ int_f h5init_flags_c( int_f *h5d_flags, size_t_f *h5d_size_flags, - int_f *h5e_flags, hid_t_f *h5e_hid_flags, int_f *h5f_flags, - int_f *h5fd_flags, hid_t_f *h5fd_hid_flags, - int_f *h5g_flags, int_f *h5i_flags, int_f *h5l_flags, int_f *h5o_flags, - hid_t_f *h5p_flags, int_f *h5p_flags_int, int_f *h5r_flags, int_f *h5s_flags, - hsize_t_f *h5s_hsize_flags, int_f *h5t_flags, int_f *h5z_flags, int_f *h5_generic_flags) + int_f *h5e_flags, hid_t_f *h5e_hid_flags, int_f *h5f_flags, + int_f *h5fd_flags, hid_t_f *h5fd_hid_flags, + int_f *h5g_flags, int_f *h5i_flags, int_f *h5l_flags, int_f *h5o_flags, + hid_t_f *h5p_flags, int_f *h5p_flags_int, int_f *h5r_flags, int_f *h5s_flags, + hsize_t_f *h5s_hsize_flags, int_f *h5t_flags, int_f *h5z_flags, int_f *h5_generic_flags, + haddr_t_f *h5_haddr_generic_flags) /******/ { int ret_value = -1; @@ -773,7 +774,9 @@ h5init_flags_c( int_f *h5d_flags, size_t_f *h5d_size_flags, h5_generic_flags[5] = (int_f)H5_ITER_INC; /* Increasing order */ h5_generic_flags[6] = (int_f)H5_ITER_DEC; /* Decreasing order */ h5_generic_flags[7] = (int_f)H5_ITER_NATIVE; /* No particular order, whatever is fastest */ - h5_generic_flags[8] = (int_f)H5_ITER_N; /* Number of iteration orders */ + h5_generic_flags[8] = (int_f)H5_ITER_N; /* Number of iteration orders */ + + h5_haddr_generic_flags[0] = (haddr_t_f)HADDR_UNDEF; /* undefined address */ ret_value = 0; return ret_value; diff --git a/fortran/src/H5_ff.F90 b/fortran/src/H5_ff.F90 index 4ceb1a8..169864f 100644 --- a/fortran/src/H5_ff.F90 +++ b/fortran/src/H5_ff.F90 @@ -105,16 +105,17 @@ CONTAINS i_H5S_hsize_flags, & i_H5T_flags, & i_H5Z_flags, & - i_H5generic_flags) & + i_H5generic_flags, & + i_H5generic_haddr_flags) & BIND(C,NAME='h5init_flags_c') - IMPORT :: HID_T, SIZE_T, HSIZE_T + IMPORT :: HID_T, SIZE_T, HSIZE_T, HADDR_T IMPORT :: H5D_FLAGS_LEN, H5D_SIZE_FLAGS_LEN, & H5E_FLAGS_LEN, H5E_HID_FLAGS_LEN, & H5F_FLAGS_LEN, H5G_FLAGS_LEN, H5FD_FLAGS_LEN, & H5FD_HID_FLAGS_LEN, H5I_FLAGS_LEN, H5L_FLAGS_LEN, & H5O_FLAGS_LEN, H5P_FLAGS_LEN, H5P_FLAGS_INT_LEN, & H5R_FLAGS_LEN, H5S_FLAGS_LEN, H5S_HSIZE_FLAGS_LEN, & - H5T_FLAGS_LEN, H5Z_FLAGS_LEN, H5generic_FLAGS_LEN + H5T_FLAGS_LEN, H5Z_FLAGS_LEN, H5generic_FLAGS_LEN, H5generic_haddr_FLAGS_LEN IMPLICIT NONE INTEGER i_H5D_flags(H5D_FLAGS_LEN) INTEGER(SIZE_T) i_H5D_size_flags(H5D_SIZE_FLAGS_LEN) @@ -135,6 +136,7 @@ CONTAINS INTEGER i_H5T_flags(H5T_FLAGS_LEN) INTEGER i_H5Z_flags(H5Z_FLAGS_LEN) INTEGER i_H5generic_flags(H5generic_FLAGS_LEN) + INTEGER(HADDR_T) i_H5generic_haddr_flags(H5generic_haddr_FLAGS_LEN) END FUNCTION h5init_flags_c END INTERFACE INTERFACE @@ -164,7 +166,8 @@ CONTAINS H5S_hsize_flags, & H5T_flags, & H5Z_flags, & - H5generic_flags) + H5generic_flags,& + H5generic_haddr_flags) error_3 = h5init1_flags_c(H5LIB_flags ) error = error_1 + error_2 + error_3 END SUBROUTINE h5open_f diff --git a/fortran/src/H5f90global.F90 b/fortran/src/H5f90global.F90 index c88327c..947eff4 100644 --- a/fortran/src/H5f90global.F90 +++ b/fortran/src/H5f90global.F90 @@ -316,6 +316,18 @@ MODULE H5GLOBAL EQUIVALENCE(H5generic_flags(7), H5_ITER_DEC_F) EQUIVALENCE(H5generic_flags(8), H5_ITER_NATIVE_F) EQUIVALENCE(H5generic_flags(9), H5_ITER_N_F) + + INTEGER, PARAMETER :: H5generic_haddr_FLAGS_LEN = 1 + INTEGER(HADDR_T) :: H5generic_haddr_flags(H5generic_haddr_FLAGS_LEN) + !DEC$if defined(BUILD_HDF5_DLL) + !DEC$ATTRIBUTES DLLEXPORT :: /H5generic_haddr_FLAGS/ + !DEC$endif + COMMON /H5generic_haddr_FLAGS/ H5generic_haddr_flags + + INTEGER(HADDR_T) :: HADDR_UNDEF_F + + EQUIVALENCE(H5generic_haddr_flags(1), HADDR_UNDEF_F) + ! ! H5G flags declaration ! diff --git a/fortran/src/H5f90proto.h b/fortran/src/H5f90proto.h index a07db22..1d08d7e 100644 --- a/fortran/src/H5f90proto.h +++ b/fortran/src/H5f90proto.h @@ -524,10 +524,11 @@ H5_FCDLL int_f h5close_c(void); H5_FCDLL int_f h5init_types_c(hid_t_f *types, hid_t_f *floatingtypes, hid_t_f *integertypes); H5_FCDLL int_f h5close_types_c(hid_t_f *types, int_f *lentypes, hid_t_f *floatingtypes, int_f *floatinglen, hid_t_f *integertypes, int_f *integerlen); H5_FCDLL int_f h5init_flags_c(int_f *h5d_flags, size_t_f *h5d_size_flags, int_f *h5e_flags, hid_t_f *h5e_hid_flags, int_f *h5f_flags, - int_f *h5fd_flags, hid_t_f *h5fd_hid_flags, - int_f *h5g_flags, int_f *h5i_flags, int_f *h5l_flags, int_f *h5o_flags, - hid_t_f *h5p_flags, int_f *h5p_flags_int, int_f *h5r_flags, int_f *h5s_flags, - hsize_t_f *h5s_hsize_flags, int_f *h5t_flags, int_f *h5z_flags, int_f *h5_generic_flags); + int_f *h5fd_flags, hid_t_f *h5fd_hid_flags, + int_f *h5g_flags, int_f *h5i_flags, int_f *h5l_flags, int_f *h5o_flags, + hid_t_f *h5p_flags, int_f *h5p_flags_int, int_f *h5r_flags, int_f *h5s_flags, + hsize_t_f *h5s_hsize_flags, int_f *h5t_flags, int_f *h5z_flags, int_f *h5_generic_flags, + haddr_t_f *h5_haddr_generic_flags); H5_FCDLL int_f h5init1_flags_c(int_f *h5lib_flags); H5_FCDLL int_f h5get_libversion_c(int_f *majnum, int_f *minnum, int_f *relnum); H5_FCDLL int_f h5check_version_c(int_f *majnum, int_f *minnum, int_f *relnum); diff --git a/fortran/test/fortranlib_test.f90 b/fortran/test/fortranlib_test.f90 index 79ff161..7e3159e 100644 --- a/fortran/test/fortranlib_test.f90 +++ b/fortran/test/fortranlib_test.f90 @@ -93,6 +93,8 @@ PROGRAM fortranlibtest ret_total_error = 0 CALL extenddsettest(cleanup, ret_total_error) CALL write_test_status(ret_total_error, ' Extendible dataset test', total_error) + CALL test_userblock_offset(cleanup, ret_total_error) + CALL write_test_status(ret_total_error, ' Dataset offset with user block', total_error) ! write(*,*) ! write(*,*) '=========================================' diff --git a/fortran/test/tH5D.f90 b/fortran/test/tH5D.f90 index b5febb3..c9ba952 100644 --- a/fortran/test/tH5D.f90 +++ b/fortran/test/tH5D.f90 @@ -343,7 +343,7 @@ CONTAINS !Modify dataset creation properties, i.e. enable chunking ! CALL h5pcreate_f(H5P_DATASET_CREATE_F, crp_list, error) - CALL check("h5pcreat_f",error,total_error) + CALL check("h5pcreate_f",error,total_error) CALL h5pset_chunk_f(crp_list, RANK, dims1, error) CALL check("h5pset_chunk_f",error,total_error) @@ -508,5 +508,123 @@ CONTAINS RETURN END SUBROUTINE extenddsettest + +! +! The following subroutine tests h5dget_offset_f functionality +! + + SUBROUTINE test_userblock_offset(cleanup, total_error) + + USE ISO_C_BINDING + + IMPLICIT NONE + LOGICAL, INTENT(IN) :: cleanup + INTEGER, INTENT(OUT) :: total_error + ! + !the dataset is stored in file "offset.h5" + ! + INTEGER, PARAMETER :: dset_dim1=2, dset_dim2=10 + CHARACTER(LEN=6), PARAMETER :: filename = "offset" + CHARACTER(LEN=80) :: fix_filename + + INTEGER(hid_t) :: file, fcpl, dataset, space + INTEGER :: i, j, n, ios + INTEGER(hsize_t), DIMENSION(1:2) :: dims + INTEGER :: f + INTEGER(haddr_t) :: offset + INTEGER, DIMENSION(1:dset_dim1,1:dset_dim2), TARGET :: rdata, data_in + INTEGER :: error + TYPE(C_PTR) :: f_ptr + ! + !Create a new file using default properties. + ! + CALL h5_fixname_f(filename, fix_filename, H5P_DEFAULT_F, error) + IF (error .NE. 0) THEN + WRITE(*,*) "Cannot modify filename" + STOP + ENDIF + + CALL h5pcreate_f(H5P_FILE_CREATE_F, fcpl, error) + CALL check("h5pcreate_f",error,total_error) + + ! Initialize the dataset + n = 0 + DO i = 1, dset_dim1 + DO j = 1, dset_dim2 + n = n + 1 + data_in(i,j) = n + END DO + END DO + CALL h5fcreate_f(fix_filename, H5F_ACC_TRUNC_F, file, error, fcpl) + CALL check("h5fcreate_f",error,total_error) + + ! Create the data space + dims(1:2) = (/dset_dim1,dset_dim2/) + + CALL h5screate_simple_f(2, dims, space, error) + CALL check("h5screate_simple_f",error,total_error) + + ! Create the dataset + CALL h5dcreate_f(file, "dset1", H5T_NATIVE_INTEGER, space, dataset, error) + CALL check("h5dcreate_f", error, total_error) + + ! Test dataset address. Should be undefined. + CALL h5dget_offset_f(dataset, offset, error) + CALL VERIFY("h5dget_offset_f",offset, HADDR_UNDEF_F, total_error) + + ! Write the data to the dataset + f_ptr = C_LOC(data_in(1,1)) + CALL h5dwrite_f(dataset, H5T_NATIVE_INTEGER, f_ptr, error) + CALL check("h5dwrite_f", error, total_error) + + ! Test dataset address in file. Open the same file as a C file, seek + ! the data position as H5Dget_offset points to, read the dataset, and + ! compare it with the data written in. + CALL h5dget_offset_f(dataset, offset, error) + CALL check("h5dget_offset_f", error, total_error) + IF(offset.EQ.HADDR_UNDEF_F)THEN + total_error = total_error + 1 + ENDIF + + CALL h5dclose_f(dataset, error) + CALL check("h5dclose_f", error, total_error) + CALL h5fclose_f(file, error) + CALL check("h5fclose_f", error, total_error) + + IF(total_error.NE.0) RETURN + + OPEN(10,FILE=fix_filename, ACCESS="STREAM", IOSTAT=ios) + IF(ios.NE.0)THEN + WRITE(*,'(A)') "Failed to open file "//TRIM(fix_filename) + total_error = total_error + 1 + RETURN + ENDIF + ! The pos= specifier illustrates that positions are in bytes, + ! starting from byte 1 (as opposed to C, where they start from byte 0) + READ(10, POS=offset+1, IOSTAT=ios) rdata + IF(ios.NE.0)THEN + WRITE(*,'(A)') "Failed to read data from stream I/O " + total_error = total_error + 1 + CLOSE(10) + RETURN + ENDIF + + ! Check that the values read are the same as the values written + DO i = 1, dset_dim1 + DO j = 1, dset_dim2 + CALL VERIFY("h5dget_offset_f",rdata(i,j), data_in(i,j), total_error) + IF(total_error.NE.0)THEN + WRITE(*,'(A)') " Read different values than written." + WRITE(*,'(2(A,I0))') " At index ",i,",",j + CLOSE(10) + RETURN + ENDIF + END DO + END DO + + CLOSE(10) + + END SUBROUTINE test_userblock_offset + END MODULE TH5D -- cgit v0.12 From 767585b70f3e8c70b9558f32dfc5670533a26a4b Mon Sep 17 00:00:00 2001 From: Dana Robinson Date: Tue, 25 Aug 2015 19:05:39 -0500 Subject: [svn-r27581] Fixed a bug in the FUNC_ENTER macros. API calls of the form H5xx_* were flagged as H5XX_, which is a non-public API form. Tested on: h5committest --- src/H5private.h | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/src/H5private.h b/src/H5private.h index 65726da..5e968a0 100644 --- a/src/H5private.h +++ b/src/H5private.h @@ -1721,9 +1721,24 @@ H5_DLL double H5_trace(const double *calltime, const char *func, const char *typ *------------------------------------------------------------------------- */ -/* `S' is the name of a function which is being tested to check if its */ -/* an API function */ -#define H5_IS_API(S) ('_'!=((const char *)S)[2] && '_'!=((const char *)S)[3] && (!((const char *)S)[4] || '_'!=((const char *)S)[4])) +/* `S' is the name of a function which is being tested to check if it's + * an API function. + * + * BADNESS: + * - Underscore at positions 2 or 3 (0-indexed string). Handles + * H5_ and H5X_. + * - Underscore at position 4 if position 3 is uppercase or a digit. + * Handles H5XY_. + */ +#define H5_IS_API(S) (\ + '_'!=((const char *)S)[2] /* underscore at position 2 */ \ + && '_'!=((const char *)S)[3] /* underscore at position 3 */ \ + && !( /* NOT */ \ + ((const char *)S)[4] /* pos 4 exists */ \ + && (HDisupper(S[3]) || HDisdigit(S[3])) /* pos 3 dig | uc */ \ + && '_'==((const char *)S)[4] /* pos 4 underscore */ \ + )\ +) /* `S' is the name of a function which is being tested to check if it's */ /* a public API function */ -- cgit v0.12 From 2faae30c8db5e5155924e47b7267d04dd73b2152 Mon Sep 17 00:00:00 2001 From: Scot Breitenfeld Date: Wed, 26 Aug 2015 10:13:43 -0500 Subject: [svn-r27585] disabled the test "test_userblock_offset"; it fails for unknown reasons on platypus with pgf90 compiler when reading the streamed file back. --- fortran/test/fortranlib_test.f90 | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/fortran/test/fortranlib_test.f90 b/fortran/test/fortranlib_test.f90 index 7e3159e..f41d811 100644 --- a/fortran/test/fortranlib_test.f90 +++ b/fortran/test/fortranlib_test.f90 @@ -93,8 +93,9 @@ PROGRAM fortranlibtest ret_total_error = 0 CALL extenddsettest(cleanup, ret_total_error) CALL write_test_status(ret_total_error, ' Extendible dataset test', total_error) - CALL test_userblock_offset(cleanup, ret_total_error) - CALL write_test_status(ret_total_error, ' Dataset offset with user block', total_error) +! MSB--DISABLED TEST-- Fails for unknown reasons on platypus with pgf90 compiler +! CALL test_userblock_offset(cleanup, ret_total_error) +! CALL write_test_status(ret_total_error, ' Dataset offset with user block', total_error) ! write(*,*) ! write(*,*) '=========================================' -- cgit v0.12 From 6635d4c003caf15aadc16b0453d71ca1b0e8ca1f Mon Sep 17 00:00:00 2001 From: Allen Byrne Date: Wed, 26 Aug 2015 11:48:42 -0500 Subject: [svn-r27586] HDFFV-9497: Add back ALLOW_UNSUPPORTED OPTION. Added new option SKIP_HDF5_FORTRAN_SHARED --- CMakeLists.txt | 41 ++++++++++++++++++++++-------- fortran/examples/CMakeLists.txt | 12 ++++----- fortran/examples/CMakeTests.cmake | 24 +++++++++--------- fortran/src/CMakeLists.txt | 18 +++++++------- fortran/test/CMakeLists.txt | 52 +++++++++++++++++++-------------------- fortran/test/CMakeTests.cmake | 4 +-- hl/fortran/src/CMakeLists.txt | 22 ++++++++--------- hl/fortran/test/CMakeLists.txt | 16 ++++++------ hl/fortran/test/CMakeTests.cmake | 8 +++--- src/CMakeLists.txt | 8 +++++- test/CMakeLists.txt | 40 +++++++++++++++++++++++++++--- 11 files changed, 152 insertions(+), 93 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 799c1da..5a1f68c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -103,6 +103,8 @@ if (HDF5_USE_FOLDERS) endif (HDF5_USE_FOLDERS) option (HDF5_NO_PACKAGES "CPACK - Disable packaging" OFF) mark_as_advanced (HDF5_NO_PACKAGES) +option (ALLOW_UNSUPPORTED "Allow unsupported combinations of configure options" OFF) +mark_as_advanced (ALLOW_UNSUPPORTED) #----------------------------------------------------------------------------- # Set the core names of all the libraries @@ -541,25 +543,34 @@ if (WIN32) option (HDF5_ENABLE_THREADSAFE "Enable thread-safety" OFF) if (HDF5_ENABLE_THREADSAFE) # check for unsupported options - if (H5_BUILT_AS_STATIC_LIB) - message (FATAL_ERROR " **** thread-safety option not supported with static library **** ") - endif (H5_BUILT_AS_STATIC_LIB) + message (STATUS " **** thread-safety option not supported with static library **** ") + message (STATUS " **** thread-safety option will not be used building static library **** ") if (HDF5_ENABLE_PARALLEL) - message (FATAL_ERROR " **** parallel and thread-safety options are not supported **** ") + if (NOT ALLOW_UNSUPPORTED) + message (FATAL_ERROR " **** parallel and thread-safety options are not supported **** ") + else (NOT ALLOW_UNSUPPORTED) + message (STATUS " **** Allowing unsupported parallel and thread-safety options **** ") + endif (NOT ALLOW_UNSUPPORTED) endif (HDF5_ENABLE_PARALLEL) if (HDF5_BUILD_FORTRAN) - message (FATAL_ERROR " **** Fortran and thread-safety options are not supported **** ") + if (NOT ALLOW_UNSUPPORTED) + message (FATAL_ERROR " **** Fortran and thread-safety options are not supported **** ") + else (NOT ALLOW_UNSUPPORTED) + message (STATUS " **** Allowing unsupported Fortran and thread-safety options **** ") + endif (NOT ALLOW_UNSUPPORTED) endif (HDF5_BUILD_FORTRAN) if (HDF5_BUILD_CPP_LIB) - message (FATAL_ERROR " **** C++ and thread-safety options are not supported **** ") + if (NOT ALLOW_UNSUPPORTED) + message (FATAL_ERROR " **** C++ and thread-safety options are not supported **** ") + else (NOT ALLOW_UNSUPPORTED) + message (STATUS " **** Allowing unsupported C++ and thread-safety options **** ") + endif (NOT ALLOW_UNSUPPORTED) endif (HDF5_BUILD_CPP_LIB) - set (H5_HAVE_THREADSAFE 1) if (H5_HAVE_IOEO) message (STATUS " **** Win32 threads requires WINVER>=0x600 (Windows Vista/7/8) **** ") set (H5_HAVE_WIN_THREADS 1) else (H5_HAVE_IOEO) if (NOT H5_HAVE_PTHREAD_H) - set (H5_HAVE_THREADSAFE 0) message (FATAL_ERROR " **** thread-safe option requires Win32 threads or Pthreads **** ") endif (NOT H5_HAVE_PTHREAD_H) endif (H5_HAVE_IOEO) @@ -667,9 +678,15 @@ set (H5_FC_FUNC "H5_FC_FUNC(name,NAME) name ## _") set (H5_FC_FUNC_ "H5_FC_FUNC_(name,NAME) name ## _") if (EXISTS "${HDF5_SOURCE_DIR}/fortran" AND IS_DIRECTORY "${HDF5_SOURCE_DIR}/fortran") option (HDF5_BUILD_FORTRAN "Build FORTRAN support" OFF) + option (SKIP_HDF5_FORTRAN_SHARED "Do not build the fortran shared libraries" OFF) if (HDF5_BUILD_FORTRAN) if (BUILD_SHARED_LIBS AND APPLE) - message (FATAL_ERROR " **** Shared FORTRAN libraries are unsupported **** ") + if (NOT ALLOW_UNSUPPORTED) + message (STATUS " **** Shared FORTRAN libraries are unsupported **** ") + set (SKIP_HDF5_FORTRAN_SHARED ON) + else (NOT ALLOW_UNSUPPORTED) + message (STATUS " **** Allowing unsupported Fortran shared libraries **** ") + endif (NOT ALLOW_UNSUPPORTED) endif (BUILD_SHARED_LIBS AND APPLE) option (HDF5_ENABLE_F2003 "Enable FORTRAN 2003 Standard" ON) include (${HDF_RESOURCES_EXT_DIR}/HDFUseFortran.cmake) @@ -703,7 +720,11 @@ if (EXISTS "${HDF5_SOURCE_DIR}/c++" AND IS_DIRECTORY "${HDF5_SOURCE_DIR}/c++") if (HDF5_BUILD_CPP_LIB) # check for unsupported options if (HDF5_ENABLE_PARALLEL) - message (FATAL_ERROR " **** Parallel and C++ options are mutually exclusive **** ") + if (NOT ALLOW_UNSUPPORTED) + message (FATAL_ERROR " **** Parallel and C++ options are mutually exclusive **** ") + else (NOT ALLOW_UNSUPPORTED) + message (STATUS " **** Allowing unsupported Parallel and C++ options **** ") + endif (NOT ALLOW_UNSUPPORTED) endif (HDF5_ENABLE_PARALLEL) if (CMAKE_NO_STD_NAMESPACE) set (H5_NO_STD 1) diff --git a/fortran/examples/CMakeLists.txt b/fortran/examples/CMakeLists.txt index f2dc896..aad5f33 100644 --- a/fortran/examples/CMakeLists.txt +++ b/fortran/examples/CMakeLists.txt @@ -52,7 +52,7 @@ foreach (example ${examples}) FOLDER examples/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/static ) - if (BUILD_SHARED_LIBS) + if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_executable (f90_ex_${example}-shared ${HDF5_F90_EXAMPLES_SOURCE_DIR}/${example}.f90) TARGET_NAMING (f90_ex_${example}-shared SHARED) TARGET_FORTRAN_PROPERTIES (f90_ex_${example}-shared SHARED " " " ") @@ -66,7 +66,7 @@ foreach (example ${examples}) FOLDER examples/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) - endif (BUILD_SHARED_LIBS) + endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) endforeach (example ${examples}) foreach (example ${F2003_examples}) @@ -83,7 +83,7 @@ foreach (example ${F2003_examples}) FOLDER examples/fortran03 Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY} ) - if (BUILD_SHARED_LIBS) + if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_executable (f03_ex_${example}-shared ${HDF5_F90_EXAMPLES_SOURCE_DIR}/${example}.f90) TARGET_NAMING (f03_ex_${example}-shared SHARED) TARGET_FORTRAN_PROPERTIES (f03_ex_${example}-shared SHARED " " " ") @@ -97,7 +97,7 @@ foreach (example ${F2003_examples}) FOLDER examples/fortran03 Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) - endif (BUILD_SHARED_LIBS) + endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) endforeach (example ${F2003_examples}) if (H5_HAVE_PARALLEL AND MPI_Fortran_FOUND) @@ -115,7 +115,7 @@ if (H5_HAVE_PARALLEL AND MPI_Fortran_FOUND) FOLDER examples/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/static ) - if (BUILD_SHARED_LIBS) + if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_executable (f90_ex_ph5example-shared ${HDF5_F90_EXAMPLES_SOURCE_DIR}/ph5example.f90) TARGET_NAMING (f90_ex_ph5example-shared SHARED) TARGET_FORTRAN_PROPERTIES (f90_ex_ph5example-shared SHARED " " " ") @@ -130,7 +130,7 @@ if (H5_HAVE_PARALLEL AND MPI_Fortran_FOUND) FOLDER examples/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) - endif (BUILD_SHARED_LIBS) + endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) endif (H5_HAVE_PARALLEL AND MPI_Fortran_FOUND) if (BUILD_TESTING) diff --git a/fortran/examples/CMakeTests.cmake b/fortran/examples/CMakeTests.cmake index 173984c..63e75c2 100644 --- a/fortran/examples/CMakeTests.cmake +++ b/fortran/examples/CMakeTests.cmake @@ -9,12 +9,12 @@ add_test ( NAME f90_ex-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove + -E remove compound.h5 copy1.h5 copy2.h5 dsetf.h5 - extend.h5 + extend.h5 FORTRAN.h5 groupf.h5 groupsf.h5 @@ -28,16 +28,16 @@ set_tests_properties (f90_ex-clear-objects PROPERTIES DEPENDS ${last_test}) endif (NOT "${last_test}" STREQUAL "") set (last_test "f90_ex-clear-objects") - if (BUILD_SHARED_LIBS) + if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_test ( NAME f90_ex-shared-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove + -E remove compound.h5 copy1.h5 copy2.h5 dsetf.h5 - extend.h5 + extend.h5 FORTRAN.h5 groupf.h5 groupsf.h5 @@ -51,7 +51,7 @@ set_tests_properties (f90_ex-shared-clear-objects PROPERTIES DEPENDS ${last_test}) endif (NOT "${last_test}" STREQUAL "") set (last_test "f90_ex-shared-clear-objects") - endif (BUILD_SHARED_LIBS) + endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) foreach (example ${examples}) add_test (NAME f90_ex_${example} COMMAND $) @@ -59,13 +59,13 @@ foreach (example ${examples}) set_tests_properties (f90_ex_${example} PROPERTIES DEPENDS ${last_test}) endif (NOT "${last_test}" STREQUAL "") set (last_test "f90_ex_${example}") - if (BUILD_SHARED_LIBS) + if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_test (NAME f90_ex-shared_${example} COMMAND $) if (NOT "${last_test}" STREQUAL "") set_tests_properties (f90_ex-shared_${example} PROPERTIES DEPENDS ${last_test}) endif (NOT "${last_test}" STREQUAL "") set (last_test "f90_ex-shared_${example}") - endif (BUILD_SHARED_LIBS) + endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) endforeach (example ${examples}) if (HDF5_ENABLE_F2003) @@ -75,19 +75,19 @@ if (HDF5_ENABLE_F2003) set_tests_properties (f03_ex_${example} PROPERTIES DEPENDS ${last_test}) endif (NOT "${last_test}" STREQUAL "") set (last_test "f03_ex_${example}") - if (BUILD_SHARED_LIBS) + if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_test (NAME f03_ex-shared_${example} COMMAND $) if (NOT "${last_test}" STREQUAL "") set_tests_properties (f03_ex-shared_${example} PROPERTIES DEPENDS ${last_test}) endif (NOT "${last_test}" STREQUAL "") set (last_test "f03_ex-shared_${example}") - endif (BUILD_SHARED_LIBS) + endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) endforeach (example ${F2003_examples}) endif (HDF5_ENABLE_F2003) if (H5_HAVE_PARALLEL AND MPI_Fortran_FOUND) add_test (NAME f90_ex_ph5example COMMAND ${MPIEXEC} ${MPIEXEC_PREFLAGS} ${MPIEXEC_NUMPROC_FLAG} ${MPIEXEC_MAX_NUMPROCS} ${MPIEXEC_POSTFLAGS} $) - if (BUILD_SHARED_LIBS) + if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_test (NAME f90_ex-shared_ph5example COMMAND ${MPIEXEC} ${MPIEXEC_PREFLAGS} ${MPIEXEC_NUMPROC_FLAG} ${MPIEXEC_MAX_NUMPROCS} ${MPIEXEC_POSTFLAGS} $) - endif (BUILD_SHARED_LIBS) + endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) endif (H5_HAVE_PARALLEL AND MPI_Fortran_FOUND) diff --git a/fortran/src/CMakeLists.txt b/fortran/src/CMakeLists.txt index 261e52a..857b26d 100644 --- a/fortran/src/CMakeLists.txt +++ b/fortran/src/CMakeLists.txt @@ -62,19 +62,19 @@ set_target_properties (H5_buildiface PROPERTIES Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY} ) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) if (WIN32) set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/shared/\${BUILD_TYPE}) else (WIN32) set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/shared) endif (WIN32) -else (BUILD_SHARED_LIBS) +else (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) if (WIN32) set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/static/\${BUILD_TYPE}) else (WIN32) set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/static) endif (WIN32) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) INCLUDE_DIRECTORIES (${HDF5_F90_BINARY_DIR} ${CMAKE_Fortran_MODULE_DIRECTORY} ${MOD_BUILD_DIR}) @@ -133,7 +133,7 @@ set_target_properties (${HDF5_F90_C_LIB_TARGET} PROPERTIES ) set (install_targets ${HDF5_F90_C_LIB_TARGET}) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_library (${HDF5_F90_C_LIBSH_TARGET} SHARED ${f90CStub_C_SRCS} ${f90CStub_C_HDRS}) TARGET_C_PROPERTIES (${HDF5_F90_C_LIBSH_TARGET} SHARED " " " ") target_link_libraries (${HDF5_F90_C_LIBSH_TARGET} ${HDF5_LIBSH_TARGET} ${LINK_SHARED_LIBS}) @@ -147,7 +147,7 @@ if (BUILD_SHARED_LIBS) INTERFACE_COMPILE_DEFINITIONS H5_BUILT_AS_DYNAMIC_LIB=1 ) set (install_targets ${install_targets} ${HDF5_F90_C_LIBSH_TARGET}) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) set_source_files_properties (${HDF5_F90_BINARY_DIR}/H5_gen.F90 PROPERTIES GENERATED TRUE) @@ -221,7 +221,7 @@ if (WIN32) endif (WIN32) set (install_targets ${install_targets} ${HDF5_F90_LIB_TARGET}) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_library (${HDF5_F90_LIBSH_TARGET} SHARED ${f90_F_SRCS}) set (SHARED_LINK_FLAGS " ") if (WIN32 AND MSVC) @@ -248,7 +248,7 @@ if (BUILD_SHARED_LIBS) ) endif (WIN32) set (install_targets ${install_targets} ${HDF5_F90_LIBSH_TARGET}) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) #----------------------------------------------------------------------------- # Add file(s) to CMake Install @@ -299,10 +299,10 @@ install ( # Add Target(s) to CMake Install for import into other projects #----------------------------------------------------------------------------- if (HDF5_EXPORTED_TARGETS) - if (BUILD_SHARED_LIBS) + if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) INSTALL_TARGET_PDB (${HDF5_F90_C_LIBSH_TARGET} ${HDF5_INSTALL_BIN_DIR} fortlibraries) #INSTALL_TARGET_PDB (${HDF5_F90_LIBSH_TARGET} ${HDF5_INSTALL_BIN_DIR} fortlibraries) - endif (BUILD_SHARED_LIBS) + endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) install ( TARGETS diff --git a/fortran/test/CMakeLists.txt b/fortran/test/CMakeLists.txt index 19d4975..49b8da8 100644 --- a/fortran/test/CMakeLists.txt +++ b/fortran/test/CMakeLists.txt @@ -22,7 +22,7 @@ set_target_properties (${HDF5_F90_C_TEST_LIB_TARGET} PROPERTIES LINKER_LANGUAGE C INTERFACE_INCLUDE_DIRECTORIES "$/include>" ) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_library (${HDF5_F90_C_TEST_LIBSH_TARGET} SHARED t.c) TARGET_C_PROPERTIES (${HDF5_F90_C_TEST_LIBSH_TARGET} SHARED " " " ") target_link_libraries (${HDF5_F90_C_TEST_LIBSH_TARGET} @@ -37,13 +37,13 @@ if (BUILD_SHARED_LIBS) INTERFACE_INCLUDE_DIRECTORIES "$/include>" INTERFACE_COMPILE_DEFINITIONS H5_BUILT_AS_DYNAMIC_LIB=1 ) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) set_source_files_properties (tf.F90 ${HDF5_F90_BINARY_DIR}/tf_gen.F90 PROPERTIES LANGUAGE Fortran) add_library (${HDF5_F90_TEST_LIB_TARGET} STATIC tf.F90 ${HDF5_F90_BINARY_DIR}/tf_gen.F90) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_library (${HDF5_F90_TEST_LIBSH_TARGET} SHARED tf.F90 ${HDF5_F90_BINARY_DIR}/tf_gen.F90) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) TARGET_FORTRAN_PROPERTIES (${HDF5_F90_TEST_LIB_TARGET} STATIC " " " ") target_link_libraries (${HDF5_F90_TEST_LIB_TARGET} @@ -64,7 +64,7 @@ if (WIN32) COMPILE_DEFINITIONS "HDF5F90_WINDOWS" ) endif (WIN32) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) set (SHARED_LINK_FLAGS " ") if (WIN32 AND MSVC) set (SHARED_LINK_FLAGS "/DLL") @@ -90,7 +90,7 @@ if (BUILD_SHARED_LIBS) COMPILE_DEFINITIONS "BUILD_HDF5_TEST_DLL;HDF5F90_WINDOWS" ) endif (WIN32) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) #----------------------------------------------------------------------------- # Setup the Fortran auto-detection utilities @@ -150,7 +150,7 @@ add_executable (testhdf5_fortran ) TARGET_NAMING (testhdf5_fortran STATIC) TARGET_FORTRAN_PROPERTIES (testhdf5_fortran STATIC " " " ") -target_link_libraries (testhdf5_fortran +target_link_libraries (testhdf5_fortran ${HDF5_F90_TEST_LIB_TARGET} ${HDF5_F90_LIB_TARGET} ${HDF5_LIB_TARGET} @@ -164,7 +164,7 @@ set_target_properties (testhdf5_fortran PROPERTIES FOLDER test/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/static ) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_executable (testhdf5_fortran-shared fortranlib_test.f90 tH5A.f90 @@ -184,7 +184,7 @@ if (BUILD_SHARED_LIBS) ) TARGET_NAMING (testhdf5_fortran-shared SHARED) TARGET_FORTRAN_PROPERTIES (testhdf5_fortran-shared SHARED " " " ") - target_link_libraries (testhdf5_fortran-shared + target_link_libraries (testhdf5_fortran-shared ${HDF5_F90_TEST_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET} ${HDF5_LIBSH_TARGET} @@ -198,7 +198,7 @@ if (BUILD_SHARED_LIBS) FOLDER test/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) #-- Adding test for testhdf5_fortran_1_8 add_executable (testhdf5_fortran_1_8 @@ -211,7 +211,7 @@ add_executable (testhdf5_fortran_1_8 ) TARGET_NAMING (testhdf5_fortran_1_8 STATIC) TARGET_FORTRAN_PROPERTIES (testhdf5_fortran_1_8 STATIC " " " ") -target_link_libraries (testhdf5_fortran_1_8 +target_link_libraries (testhdf5_fortran_1_8 ${HDF5_F90_TEST_LIB_TARGET} ${HDF5_F90_LIB_TARGET} ${HDF5_LIB_TARGET} @@ -225,7 +225,7 @@ set_target_properties (testhdf5_fortran_1_8 PROPERTIES FOLDER test/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/static ) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_executable (testhdf5_fortran_1_8-shared fortranlib_test_1_8.f90 tH5O.f90 @@ -236,7 +236,7 @@ if (BUILD_SHARED_LIBS) ) TARGET_NAMING (testhdf5_fortran_1_8-shared SHARED) TARGET_FORTRAN_PROPERTIES (testhdf5_fortran_1_8-shared SHARED " " " ") - target_link_libraries (testhdf5_fortran_1_8-shared + target_link_libraries (testhdf5_fortran_1_8-shared ${HDF5_F90_TEST_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET} ${HDF5_LIBSH_TARGET} @@ -250,7 +250,7 @@ if (BUILD_SHARED_LIBS) FOLDER test/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) #-- Adding test for fortranlib_test_F03 add_executable (fortranlib_test_F03 @@ -265,7 +265,7 @@ add_executable (fortranlib_test_F03 ) TARGET_NAMING (fortranlib_test_F03 STATIC) TARGET_FORTRAN_PROPERTIES (fortranlib_test_F03 STATIC " " " ") -target_link_libraries (fortranlib_test_F03 +target_link_libraries (fortranlib_test_F03 ${HDF5_F90_TEST_LIB_TARGET} ${HDF5_F90_LIB_TARGET} ${HDF5_LIB_TARGET} @@ -279,7 +279,7 @@ set_target_properties (fortranlib_test_F03 PROPERTIES FOLDER test/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/static ) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_executable (fortranlib_test_F03-shared fortranlib_test_F03.f90 tH5E_F03.f90 @@ -292,7 +292,7 @@ if (BUILD_SHARED_LIBS) ) TARGET_NAMING (fortranlib_test_F03-shared SHARED) TARGET_FORTRAN_PROPERTIES (fortranlib_test_F03-shared SHARED " " " ") - target_link_libraries (fortranlib_test_F03-shared + target_link_libraries (fortranlib_test_F03-shared ${HDF5_F90_TEST_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET} ${HDF5_LIBSH_TARGET} @@ -306,13 +306,13 @@ if (BUILD_SHARED_LIBS) FOLDER test/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) #-- Adding test for fflush1 add_executable (fflush1 fflush1.f90) TARGET_NAMING (fflush1 STATIC) TARGET_FORTRAN_PROPERTIES (fflush1 STATIC " " " ") -target_link_libraries (fflush1 +target_link_libraries (fflush1 ${HDF5_F90_LIB_TARGET} ${HDF5_F90_TEST_LIB_TARGET} ${HDF5_LIB_TARGET} @@ -326,11 +326,11 @@ set_target_properties (fflush1 PROPERTIES FOLDER test/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/static ) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_executable (fflush1-shared fflush1.f90) TARGET_NAMING (fflush1-shared SHARED) TARGET_FORTRAN_PROPERTIES (fflush1-shared SHARED " " " ") - target_link_libraries (fflush1-shared + target_link_libraries (fflush1-shared ${HDF5_F90_LIBSH_TARGET} ${HDF5_F90_TEST_LIBSH_TARGET} ${HDF5_LIBSH_TARGET} @@ -344,13 +344,13 @@ if (BUILD_SHARED_LIBS) FOLDER test/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) #-- Adding test for fflush2 add_executable (fflush2 fflush2.f90) TARGET_NAMING (fflush2 STATIC) TARGET_FORTRAN_PROPERTIES (fflush2 STATIC " " " ") -target_link_libraries (fflush2 +target_link_libraries (fflush2 ${HDF5_F90_TEST_LIB_TARGET} ${HDF5_F90_LIB_TARGET} ${HDF5_LIB_TARGET} @@ -364,11 +364,11 @@ set_target_properties (fflush2 PROPERTIES FOLDER test/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/static ) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_executable (fflush2-shared fflush2.f90) TARGET_NAMING (fflush2-shared SHARED) TARGET_FORTRAN_PROPERTIES (fflush2-shared SHARED " " " ") - target_link_libraries (fflush2-shared + target_link_libraries (fflush2-shared ${HDF5_F90_TEST_LIBSH_TARGET} ${HDF5_F90_LIBSH_TARGET} ${HDF5_LIBSH_TARGET} @@ -382,6 +382,6 @@ if (BUILD_SHARED_LIBS) FOLDER test/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) include (CMakeTests.cmake) diff --git a/fortran/test/CMakeTests.cmake b/fortran/test/CMakeTests.cmake index 94f6b64..154e70c 100644 --- a/fortran/test/CMakeTests.cmake +++ b/fortran/test/CMakeTests.cmake @@ -27,7 +27,7 @@ add_test (NAME FORTRAN_fflush1 COMMAND $) add_test (NAME FORTRAN_fflush2 COMMAND $) set_tests_properties (FORTRAN_fflush2 PROPERTIES DEPENDS FORTRAN_fflush1) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_test (NAME FORTRAN_testhdf5_fortran-shared COMMAND $) set_tests_properties (FORTRAN_testhdf5_fortran-shared PROPERTIES PASS_REGULAR_EXPRESSION "[ ]*0 error.s") set_tests_properties (FORTRAN_testhdf5_fortran-shared PROPERTIES DEPENDS FORTRAN_testhdf5_fortran) @@ -51,4 +51,4 @@ if (BUILD_SHARED_LIBS) #-- Adding test for fflush2 add_test (NAME FORTRAN_fflush2-shared COMMAND $) set_tests_properties (FORTRAN_fflush2-shared PROPERTIES DEPENDS FORTRAN_fflush1-shared) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) diff --git a/hl/fortran/src/CMakeLists.txt b/hl/fortran/src/CMakeLists.txt index ed2e542..5df4e1d 100644 --- a/hl/fortran/src/CMakeLists.txt +++ b/hl/fortran/src/CMakeLists.txt @@ -36,19 +36,19 @@ set_target_properties (H5HL_buildiface PROPERTIES Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY} ) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) if (WIN32) set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/shared/\${BUILD_TYPE}) else (WIN32) set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/shared) endif (WIN32) -else (BUILD_SHARED_LIBS) +else (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) if (WIN32) set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/static/\${BUILD_TYPE}) else (WIN32) set (MOD_BUILD_DIR ${CMAKE_Fortran_MODULE_DIRECTORY}/static) endif (WIN32) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) #----------------------------------------------------------------------------- # Setup include Directories @@ -87,7 +87,7 @@ set_target_properties (${HDF5_HL_F90_C_LIB_TARGET} PROPERTIES ) set (install_targets ${HDF5_HL_F90_C_LIB_TARGET}) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_library (${HDF5_HL_F90_C_LIBSH_TARGET} SHARED ${HDF5_HL_F90_C_SRCS} ${HDF5_HL_F90_HEADERS}) TARGET_C_PROPERTIES (${HDF5_HL_F90_C_LIBSH_TARGET} SHARED " " " ") target_link_libraries (${HDF5_HL_F90_C_LIBSH_TARGET} ${HDF5_F90_C_LIBSH_TARGET} ${HDF5_HL_LIBSH_TARGET}) @@ -101,7 +101,7 @@ if (BUILD_SHARED_LIBS) INTERFACE_COMPILE_DEFINITIONS H5_BUILT_AS_DYNAMIC_LIB=1 ) set (install_targets ${install_targets} ${HDF5_HL_F90_C_LIBSH_TARGET}) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) #----------------------------------------------------------------------------- # Fortran Modules @@ -149,13 +149,13 @@ set_target_properties (${HDF5_HL_F90_LIB_TARGET} PROPERTIES Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/static ) if (WIN32) - set_property (TARGET ${HDF5_HL_F90_LIB_TARGET} + set_property (TARGET ${HDF5_HL_F90_LIB_TARGET} APPEND PROPERTY COMPILE_DEFINITIONS "HDF5F90_WINDOWS" ) endif (WIN32) set (install_targets ${install_targets} ${HDF5_HL_F90_LIB_TARGET}) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_library (${HDF5_HL_F90_LIBSH_TARGET} SHARED ${HDF5_HL_F90_F_SRCS}) set (SHARED_LINK_FLAGS " ") if (WIN32 AND MSVC) @@ -173,12 +173,12 @@ if (BUILD_SHARED_LIBS) Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) if (WIN32) - set_property (TARGET ${HDF5_HL_F90_LIBSH_TARGET} + set_property (TARGET ${HDF5_HL_F90_LIBSH_TARGET} APPEND PROPERTY COMPILE_DEFINITIONS "BUILD_HDF5_HL_DLL;HDF5F90_WINDOWS" ) endif (WIN32) set (install_targets ${install_targets} ${HDF5_HL_F90_LIBSH_TARGET}) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) #----------------------------------------------------------------------------- # Add file(s) to CMake Install @@ -207,10 +207,10 @@ install ( # Add Target(s) to CMake Install for import into other projects #----------------------------------------------------------------------------- if (HDF5_EXPORTED_TARGETS) - if (BUILD_SHARED_LIBS) + if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) INSTALL_TARGET_PDB (${HDF5_HL_F90_C_LIBSH_TARGET} ${HDF5_INSTALL_BIN_DIR} hlfortlibraries) #INSTALL_TARGET_PDB (${HDF5_HL_F90_LIBSH_TARGET} ${HDF5_INSTALL_BIN_DIR} hlfortlibraries) - endif (BUILD_SHARED_LIBS) + endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) install ( TARGETS diff --git a/hl/fortran/test/CMakeLists.txt b/hl/fortran/test/CMakeLists.txt index a1d1386..fc703dc 100644 --- a/hl/fortran/test/CMakeLists.txt +++ b/hl/fortran/test/CMakeLists.txt @@ -14,7 +14,7 @@ target_link_libraries (hl_f90_tstds ${HDF5_HL_F90_LIB_TARGET} ${HDF5_F90_LIB_TAR target_include_directories (hl_f90_tstds PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/static) set_target_properties (hl_f90_tstds PROPERTIES LINKER_LANGUAGE Fortran) set_target_properties (hl_f90_tstds PROPERTIES FOLDER test/hl/fortran) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_executable (hl_f90_tstds-shared tstds.F90) TARGET_NAMING (hl_f90_tstds-shared SHARED) TARGET_FORTRAN_PROPERTIES (hl_f90_tstds-shared SHARED " " " ") @@ -25,7 +25,7 @@ if (BUILD_SHARED_LIBS) FOLDER test/hl/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) #-- Adding test for hl_f90_tstlite add_executable (hl_f90_tstlite tstlite.F90) @@ -35,7 +35,7 @@ target_link_libraries (hl_f90_tstlite ${HDF5_HL_F90_LIB_TARGET} ${HDF5_F90_LIB_T target_include_directories (hl_f90_tstlite PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/static) set_target_properties (hl_f90_tstlite PROPERTIES LINKER_LANGUAGE Fortran) set_target_properties (hl_f90_tstlite PROPERTIES FOLDER test/hl/fortran) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_executable (hl_f90_tstlite-shared tstlite.F90) TARGET_NAMING (hl_f90_tstlite-shared SHARED) TARGET_FORTRAN_PROPERTIES (hl_f90_tstlite-shared SHARED " " " ") @@ -46,7 +46,7 @@ if (BUILD_SHARED_LIBS) FOLDER test/hl/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) #-- Adding test for hl_f90_tstimage add_executable (hl_f90_tstimage tstimage.F90) @@ -56,7 +56,7 @@ target_link_libraries (hl_f90_tstimage ${HDF5_HL_F90_LIB_TARGET} ${HDF5_F90_LIB target_include_directories (hl_f90_tstimage PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/static) set_target_properties (hl_f90_tstimage PROPERTIES LINKER_LANGUAGE Fortran) set_target_properties (hl_f90_tstimage PROPERTIES FOLDER test/hl/fortran) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_executable (hl_f90_tstimage-shared tstimage.F90) TARGET_NAMING (hl_f90_tstimage-shared SHARED) TARGET_FORTRAN_PROPERTIES (hl_f90_tstimage-shared SHARED " " " ") @@ -67,7 +67,7 @@ if (BUILD_SHARED_LIBS) FOLDER test/hl/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) #-- Adding test for hl_f90_tsttable add_executable (hl_f90_tsttable tsttable.F90) @@ -77,7 +77,7 @@ target_link_libraries (hl_f90_tsttable ${HDF5_HL_F90_LIB_TARGET} ${HDF5_F90_LIB_ target_include_directories (hl_f90_tsttable PRIVATE ${CMAKE_Fortran_MODULE_DIRECTORY}/static) set_target_properties (hl_f90_tsttable PROPERTIES LINKER_LANGUAGE Fortran) set_target_properties (hl_f90_tsttable PROPERTIES FOLDER test/hl/fortran) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_executable (hl_f90_tsttable-shared tsttable.F90) TARGET_NAMING (hl_f90_tsttable-shared SHARED) TARGET_FORTRAN_PROPERTIES (hl_f90_tsttable-shared SHARED " " " ") @@ -88,6 +88,6 @@ if (BUILD_SHARED_LIBS) FOLDER test/hl/fortran Fortran_MODULE_DIRECTORY ${CMAKE_Fortran_MODULE_DIRECTORY}/shared ) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) include (CMakeTests.cmake) diff --git a/hl/fortran/test/CMakeTests.cmake b/hl/fortran/test/CMakeTests.cmake index 38181bf..499e255 100644 --- a/hl/fortran/test/CMakeTests.cmake +++ b/hl/fortran/test/CMakeTests.cmake @@ -9,7 +9,7 @@ add_test ( NAME HL_FORTRAN_test-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove + -E remove dsetf1.h5 dsetf2.h5 dsetf3.h5 @@ -32,11 +32,11 @@ set_tests_properties (HL_FORTRAN_f90_tstimage PROPERTIES DEPENDS HL_FORTRAN_test add_test (NAME HL_FORTRAN_f90_tsttable COMMAND $) set_tests_properties (HL_FORTRAN_f90_tsttable PROPERTIES DEPENDS HL_FORTRAN_test-clear-objects) -if (BUILD_SHARED_LIBS) +if (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) add_test ( NAME HL_FORTRAN_test-shared-clear-objects COMMAND ${CMAKE_COMMAND} - -E remove + -E remove dsetf1.h5 dsetf2.h5 dsetf3.h5 @@ -61,4 +61,4 @@ if (BUILD_SHARED_LIBS) add_test (NAME HL_FORTRAN_f90_tsttable-shared COMMAND $) set_tests_properties (HL_FORTRAN_f90_tsttable-shared PROPERTIES DEPENDS HL_FORTRAN_test-shared-clear-objects) -endif (BUILD_SHARED_LIBS) +endif (BUILD_SHARED_LIBS AND NOT SKIP_HDF5_FORTRAN_SHARED) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt index ee06669..dc6ba0a 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt @@ -896,9 +896,15 @@ if (BUILD_SHARED_LIBS) INTERFACE_INCLUDE_DIRECTORIES "$/include>" INTERFACE_COMPILE_DEFINITIONS H5_BUILT_AS_DYNAMIC_LIB=1 ) + if (HDF5_ENABLE_THREADSAFE) + set_property (TARGET ${HDF5_LIBSH_TARGET} + APPEND PROPERTY COMPILE_DEFINITIONS + "H5_HAVE_THREADSAFE" + ) + endif (HDF5_ENABLE_THREADSAFE) if (HDF5_ENABLE_DEBUG_APIS) - set_property (TARGET ${HDF5_LIBSH_TARGET} + set_property (TARGET ${HDF5_LIBSH_TARGET} APPEND PROPERTY COMPILE_DEFINITIONS "H5Z_DEBUG;H5VM_DEBUG;H5T_DEBUG;H5S_DEBUG;H5P_DEBUG;H5O_DEBUG;H5MM_DEBUG;H5MF_DEBUG;H5I_DEBUG;H5HL_DEBUG;H5HG_DEBUG;H5G_DEBUG;H5F_DEBUG;H5E_DEBUG;H5D_DEBUG;H5B_DEBUG;H5AC_DEBUG" ) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index c94b880..2dc8131 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -58,6 +58,12 @@ if (BUILD_SHARED_LIBS) INTERFACE_INCLUDE_DIRECTORIES "$/include>" INTERFACE_COMPILE_DEFINITIONS H5_BUILT_AS_DYNAMIC_LIB=1 ) + if (HDF5_ENABLE_THREADSAFE) + set_property (TARGET ${HDF5_TEST_LIBSH_TARGET} + APPEND PROPERTY COMPILE_DEFINITIONS + "H5_HAVE_THREADSAFE" + ) + endif (HDF5_ENABLE_THREADSAFE) endif (BUILD_SHARED_LIBS) #----------------------------------------------------------------------------- @@ -103,7 +109,7 @@ endif (BUILD_SHARED_LIBS) TARGET ${HDF5_TEST_PLUGIN_LIB_TARGET} POST_BUILD COMMAND ${CMAKE_COMMAND} - ARGS -E copy_if_different + ARGS -E copy_if_different "$" "${CMAKE_BINARY_DIR}/testdir1/$" ) @@ -134,7 +140,7 @@ endif (BUILD_SHARED_LIBS) TARGET ${HDF5_TEST_PLUGIN_LIB_TARGET} POST_BUILD COMMAND ${CMAKE_COMMAND} - ARGS -E copy_if_different + ARGS -E copy_if_different "$" "${CMAKE_BINARY_DIR}/testdir2/$" ) @@ -207,7 +213,7 @@ set (H5_TESTS #cache_api #cache_tagging pool - hyperslab + #hyperslab istore bittests dt_arith @@ -307,6 +313,26 @@ if (BUILD_SHARED_LIBS) set_target_properties (cache_tagging-shared PROPERTIES FOLDER test) endif (BUILD_SHARED_LIBS) +#-- Adding test for hyperslab +add_executable (hyperslab ${HDF5_TEST_SOURCE_DIR}/hyperslab.c) +TARGET_NAMING (hyperslab STATIC) +TARGET_C_PROPERTIES (hyperslab STATIC " " " ") +target_link_libraries (hyperslab ${HDF5_LIB_TARGET} ${HDF5_TEST_LIB_TARGET}) +set_target_properties (hyperslab PROPERTIES FOLDER test) +if (BUILD_SHARED_LIBS) + add_executable (hyperslab-shared ${HDF5_TEST_SOURCE_DIR}/hyperslab.c) + TARGET_NAMING (hyperslab-shared SHARED) + TARGET_C_PROPERTIES (hyperslab-shared SHARED " " " ") + target_link_libraries (hyperslab-shared ${HDF5_TEST_LIBSH_TARGET} ${HDF5_LIBSH_TARGET}) + set_target_properties (hyperslab-shared PROPERTIES FOLDER test) + if (HDF5_ENABLE_THREADSAFE) + set_property (TARGET hyperslab-shared} + APPEND PROPERTY COMPILE_DEFINITIONS + "H5_HAVE_THREADSAFE" + ) + endif (HDF5_ENABLE_THREADSAFE) +endif (BUILD_SHARED_LIBS) + #-- Adding test for ttsafe add_executable (ttsafe ${HDF5_TEST_SOURCE_DIR}/ttsafe.c @@ -331,6 +357,12 @@ if (BUILD_SHARED_LIBS) TARGET_C_PROPERTIES (ttsafe-shared SHARED " " " ") target_link_libraries (ttsafe-shared ${HDF5_TEST_LIBSH_TARGET} ${HDF5_LIBSH_TARGET}) set_target_properties (ttsafe-shared PROPERTIES FOLDER test) + if (HDF5_ENABLE_THREADSAFE) + set_property (TARGET ttsafe-shared + APPEND PROPERTY COMPILE_DEFINITIONS + "H5_HAVE_THREADSAFE" + ) + endif (HDF5_ENABLE_THREADSAFE) endif (BUILD_SHARED_LIBS) #-- Adding test for err_compat @@ -379,7 +411,7 @@ endif (BUILD_SHARED_LIBS) #-- Adding test for libinfo set (GREP_RUNNER ${PROJECT_BINARY_DIR}/GrepRunner.cmake) -file (WRITE ${GREP_RUNNER} +file (WRITE ${GREP_RUNNER} "file (STRINGS \${TEST_PROGRAM} TEST_RESULT REGEX \"SUMMARY OF THE HDF5 CONFIGURATION\") if (\${TEST_RESULT} STREQUAL \"0\") message (FATAL_ERROR \"Failed: The output: \${TEST_RESULT} of \${TEST_PROGRAM} did not contain SUMMARY OF THE HDF5 CONFIGURATION\") -- cgit v0.12 From 606c16e11126bd908e673abefd4f0b7e91562d7f Mon Sep 17 00:00:00 2001 From: Dana Robinson Date: Wed, 26 Aug 2015 12:05:57 -0500 Subject: [svn-r27587] Added a new API call (H5is_library_threadsafe) to the library. This call can be used to determine at runtime if the library was built with thread-safety. Fixes HDFFV-9496 Tested on: h5committest --- src/H5.c | 48 +++++++++++++++++++++++++++++++++++++++--------- src/H5public.h | 4 +++- test/ttsafe.c | 43 +++++++++++++++++++++++++++++++++++-------- test/ttsafe.h | 10 +++------- test/ttsafe_error.c | 1 + 5 files changed, 81 insertions(+), 25 deletions(-) diff --git a/src/H5.c b/src/H5.c index 3d4512f..8563545 100644 --- a/src/H5.c +++ b/src/H5.c @@ -21,17 +21,17 @@ /***********/ /* Headers */ /***********/ -#include "H5private.h" /* Generic Functions */ -#include "H5ACprivate.h" /* Metadata cache */ -#include "H5Dprivate.h" /* Datasets */ -#include "H5Eprivate.h" /* Error handling */ -#include "H5FLprivate.h" /* Free lists */ -#include "H5Lprivate.h" /* Links */ +#include "H5private.h" /* Generic Functions */ +#include "H5ACprivate.h" /* Metadata cache */ +#include "H5Dprivate.h" /* Datasets */ +#include "H5Eprivate.h" /* Error handling */ +#include "H5FLprivate.h" /* Free lists */ +#include "H5Lprivate.h" /* Links */ #include "H5MMprivate.h" /* Memory management */ -#include "H5Pprivate.h" /* Property lists */ -#include "H5Tprivate.h" /* Datatypes */ +#include "H5Pprivate.h" /* Property lists */ #include "H5SLprivate.h" /* Skip lists */ - +#include "H5Tprivate.h" /* Datatypes */ +#include "H5TSprivate.h" /* Thread safety */ /****************/ /* Local Macros */ @@ -973,6 +973,36 @@ H5free_memory(void *mem) } /* end H5free_memory() */ +/*------------------------------------------------------------------------- + * Function: H5is_library_threadsafe + * + * Purpose: Checks to see if the library was built with thread-safety + * enabled. + * + * Return: SUCCEED/FAIL + * + *------------------------------------------------------------------------- + */ +herr_t +H5is_library_threadsafe(hbool_t *is_ts) +{ + herr_t ret_value = SUCCEED; + + FUNC_ENTER_API_NOINIT + H5TRACE1("e", "*b", is_ts); + + HDassert(is_ts); + +#ifdef H5_HAVE_THREADSAFE + *is_ts = TRUE; +#else /* H5_HAVE_THREADSAFE */ + *is_ts = FALSE; +#endif /* H5_HAVE_THREADSAFE */ + + FUNC_LEAVE_API(ret_value) +} /* end H5is_library_threadsafe() */ + + #if defined(H5_HAVE_THREADSAFE) && defined(H5_BUILT_AS_DYNAMIC_LIB) \ && defined(H5_HAVE_WIN32_API) && defined(H5_HAVE_WIN_THREADS) /*------------------------------------------------------------------------- diff --git a/src/H5public.h b/src/H5public.h index b9b4dd7..8c7da05 100644 --- a/src/H5public.h +++ b/src/H5public.h @@ -331,6 +331,7 @@ H5_DLL herr_t H5get_libversion(unsigned *majnum, unsigned *minnum, unsigned *relnum); H5_DLL herr_t H5check_version(unsigned majnum, unsigned minnum, unsigned relnum); +H5_DLL herr_t H5is_library_threadsafe(hbool_t *is_ts); H5_DLL herr_t H5free_memory(void *mem); H5_DLL void *H5allocate_memory(size_t size, hbool_t clear); H5_DLL void *H5resize_memory(void *mem, size_t size); @@ -338,5 +339,6 @@ H5_DLL void *H5resize_memory(void *mem, size_t size); #ifdef __cplusplus } #endif -#endif +#endif /* _H5public_H */ + diff --git a/test/ttsafe.c b/test/ttsafe.c index d0ab81a..d3c5cfb 100644 --- a/test/ttsafe.c +++ b/test/ttsafe.c @@ -40,13 +40,6 @@ /* ANY new test needs to have a prototype in ttsafe.h */ #include "ttsafe.h" -#ifndef H5_HAVE_THREADSAFE -int main(void) -{ - printf("Test skipped because THREADSAFE not enabled\n"); - return 0; -} -#else #define MAX_NUM_NAME 1000 #define NAME_OFFSET 6 /* offset for "name" */ @@ -66,6 +59,30 @@ num_digits(int num) return u; } +/* Test the H5is_library_threadsafe() function */ +void +tts_is_threadsafe(void) +{ + hbool_t is_ts; + hbool_t should_be; + +#ifdef H5_HAVE_THREADSAFE + is_ts = FALSE; + should_be = TRUE; +#else /* H5_HAVE_THREADSAFE */ + is_ts = TRUE; + should_be = FALSE; +#endif /* H5_HAVE_THREADSAFE */ + + if(H5is_library_threadsafe(&is_ts) != SUCCEED) + TestErrPrintf("H5_is_library_threadsafe() call failed - test failed\n"); + + if(is_ts != should_be) + TestErrPrintf("Thread-safety value incorrect - test failed\n"); + + return; +} + /* Routine to generate attribute names for numeric values */ char *gen_name(int value) { @@ -88,10 +105,13 @@ char *gen_name(int value) int main(int argc, char *argv[]) { + /* Initialize testing framework */ TestInit(argv[0], NULL, NULL); /* Tests are generally arranged from least to most complexity... */ + AddTest("is_threadsafe", tts_is_threadsafe, NULL, "library threadsafe status", NULL); +#ifdef H5_HAVE_THREADSAFE AddTest("dcreate", tts_dcreate, cleanup_dcreate, "multi-dataset creation", NULL); AddTest("error", tts_error, cleanup_error, "per-thread error stacks", NULL); #ifdef H5_HAVE_PTHREAD_H @@ -100,6 +120,12 @@ int main(int argc, char *argv[]) #endif /* H5_HAVE_PTHREAD_H */ AddTest("acreate", tts_acreate, cleanup_acreate, "multi-attribute creation", NULL); +#else /* H5_HAVE_THREADSAFE */ + + printf("Most thread-safety tests skipped because THREADSAFE not enabled\n"); + +#endif /* H5_HAVE_THREADSAFE */ + /* Display testing information */ TestInfo(argv[0]); @@ -118,5 +144,6 @@ int main(int argc, char *argv[]) TestCleanup(); return GetTestNumErrs(); + } /* end main() */ -#endif /*H5_HAVE_THREADSAFE*/ + diff --git a/test/ttsafe.h b/test/ttsafe.h index b4826fc..f2e9e86 100644 --- a/test/ttsafe.h +++ b/test/ttsafe.h @@ -20,8 +20,6 @@ #ifndef TTSAFE_H #define TTSAFE_H -#include - /* * Include required headers. This file tests internal library functions, * so we include the private headers here. @@ -31,16 +29,13 @@ #include "H5Eprivate.h" #include "testhdf5.h" -#ifdef H5_HAVE_THREADSAFE -/* Include pthread library for threadsafe tests */ -#ifdef H5_HAVE_PTHREAD_H -#include -#endif /* H5_HAVE_PTHREAD_H */ /* Prototypes for the support routines */ extern char* gen_name(int); /* Prototypes for the test routines */ +void tts_is_threadsafe(void); +#ifdef H5_HAVE_THREADSAFE void tts_dcreate(void); void tts_error(void); void tts_cancel(void); @@ -54,3 +49,4 @@ void cleanup_acreate(void); #endif /* H5_HAVE_THREADSAFE */ #endif /* TTSAFE_H */ + diff --git a/test/ttsafe_error.c b/test/ttsafe_error.c index e143263..a2f25db 100644 --- a/test/ttsafe_error.c +++ b/test/ttsafe_error.c @@ -231,3 +231,4 @@ void cleanup_error(void) } #endif /*H5_HAVE_THREADSAFE*/ + -- cgit v0.12 From c491cf01bf8ca63cc3c3d8cad1f239975cc344dc Mon Sep 17 00:00:00 2001 From: Allen Byrne Date: Thu, 27 Aug 2015 08:41:32 -0500 Subject: [svn-r27590] Fix typo --- test/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 2dc8131..f33c2df 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -326,7 +326,7 @@ if (BUILD_SHARED_LIBS) target_link_libraries (hyperslab-shared ${HDF5_TEST_LIBSH_TARGET} ${HDF5_LIBSH_TARGET}) set_target_properties (hyperslab-shared PROPERTIES FOLDER test) if (HDF5_ENABLE_THREADSAFE) - set_property (TARGET hyperslab-shared} + set_property (TARGET hyperslab-shared APPEND PROPERTY COMPILE_DEFINITIONS "H5_HAVE_THREADSAFE" ) -- cgit v0.12 From 01a1e8f1caa498993f707b692f27bac82ba18470 Mon Sep 17 00:00:00 2001 From: Allen Byrne Date: Thu, 27 Aug 2015 10:36:25 -0500 Subject: [svn-r27591] Threadsafe option implementation has changed and ALLOWUNSUPPORTED option needs to be used with TS to actually use of TS with Fortran and C++. --- CMakeLists.txt | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 5a1f68c..c75114e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -554,14 +554,16 @@ if (WIN32) endif (HDF5_ENABLE_PARALLEL) if (HDF5_BUILD_FORTRAN) if (NOT ALLOW_UNSUPPORTED) - message (FATAL_ERROR " **** Fortran and thread-safety options are not supported **** ") + message (STATUS " **** Fortran and thread-safety options are not supported **** ") + message (STATUS " **** thread-safety option will not be used building Fortran library **** ") else (NOT ALLOW_UNSUPPORTED) message (STATUS " **** Allowing unsupported Fortran and thread-safety options **** ") endif (NOT ALLOW_UNSUPPORTED) endif (HDF5_BUILD_FORTRAN) if (HDF5_BUILD_CPP_LIB) if (NOT ALLOW_UNSUPPORTED) - message (FATAL_ERROR " **** C++ and thread-safety options are not supported **** ") + message (STATUS " **** C++ and thread-safety options are not supported **** ") + message (STATUS " **** thread-safety option will not be used building C++ library **** ") else (NOT ALLOW_UNSUPPORTED) message (STATUS " **** Allowing unsupported C++ and thread-safety options **** ") endif (NOT ALLOW_UNSUPPORTED) -- cgit v0.12 From a9c28bac4e6822321c8a7a81784526201a2d6b09 Mon Sep 17 00:00:00 2001 From: Scot Breitenfeld Date: Thu, 27 Aug 2015 11:07:50 -0500 Subject: [svn-r27592] Added dll for H5DGET_OFFSET_F --- fortran/src/hdf5_fortrandll.def.in | 1 + 1 file changed, 1 insertion(+) diff --git a/fortran/src/hdf5_fortrandll.def.in b/fortran/src/hdf5_fortrandll.def.in index e931a97..1333262 100644 --- a/fortran/src/hdf5_fortrandll.def.in +++ b/fortran/src/hdf5_fortrandll.def.in @@ -64,6 +64,7 @@ H5D_mp_H5DFILL_CHAR H5D_mp_H5DFILL_INTEGER H5D_mp_H5DGET_SPACE_STATUS_F H5D_mp_H5DCREATE_ANON_F +H5D_mp_H5DGET_OFFSET_F H5D_mp_H5DGET_SPACE_F H5D_mp_H5DGET_TYPE_F H5D_mp_H5DSET_EXTENT_F -- cgit v0.12 From ccf2bcc6368fc3888c908da99da69c534888053d Mon Sep 17 00:00:00 2001 From: Allen Byrne Date: Thu, 27 Aug 2015 16:46:50 -0500 Subject: [svn-r27597] Update text files to match 1.8 changes --- release_docs/INSTALL_CMake.txt | 335 +++++---- release_docs/RELEASE.txt | 1242 +++------------------------------ release_docs/USING_CMake_Examples.txt | 45 +- release_docs/USING_HDF5_CMake.txt | 179 ++--- 4 files changed, 362 insertions(+), 1439 deletions(-) diff --git a/release_docs/INSTALL_CMake.txt b/release_docs/INSTALL_CMake.txt index 7a98bef..df6291f 100644 --- a/release_docs/INSTALL_CMake.txt +++ b/release_docs/INSTALL_CMake.txt @@ -4,11 +4,11 @@ ************************************************************************ Table of Contents - + Section I: Preconditions -Section II: Quick Step Building HDF5 Libraries with CMake Script Mode +Section II: Quick Step Building HDF5 Libraries with CMake Script Mode Section III: Quick Step Building HDF5 Libraries with CMake Command Mode -Section IV: Further considerations +Section IV: Further considerations Section V: Options for building HDF5 Libraries with CMake command line Section VI: CMake option defaults for HDF5 Section VII: User Defined Options for HDF5 Libraries with CMake @@ -20,7 +20,7 @@ Section VIII: Options for platform configuration files ======================================================================== I. Preconditions ======================================================================== -Obtaining HDF5 source code +Obtaining HDF5 source code 1. Create a directory for your development; for example, "myhdfstuff". 2. Obtain compressed (*.tar or *.zip) HDF5 source from @@ -29,17 +29,17 @@ Obtaining HDF5 source code Uncompress the file. There should be a hdf5-1.8."X" folder. CMake version - 1. We suggest you obtain the latest CMake from the Kitware web site. + 1. We suggest you obtain the latest CMake from the Kitware web site. The HDF5 1.8."X" product requires a minimum CMake version 3.1.0, - where "X" is the current HDF5 release version. + where "X" is the current HDF5 release version. ======================================================================== II. Quick Step Building HDF5 Libraries with CMake Script Mode ======================================================================== -This short set of instructions is written for users who want to quickly -build the HDF5 C and C++ static libraries and tools with SZIP and ZLIB -compression included. This procedure will use the default settings in +This short set of instructions is written for users who want to quickly +build the HDF5 C and C++ static libraries and tools with SZIP and ZLIB +compression included. This procedure will use the default settings in the config/cmake/cacheinit.cmake file. HDF Group recommends using the ctest script mode to build HDF5. @@ -57,7 +57,7 @@ CMake build script: External compression szip and zlib libraries: SZip.tar.gz ZLib.tar.gz - + Platform configuration files: HDF518config.cmake ----------------------------------------------- @@ -65,18 +65,18 @@ Platform configuration files: To build HDF5 with the SZIP and ZLIB external libraries you will need to: 1. Change to the development directory "myhdfstuff". - + 2. Download the SZip.tar.gz and ZLib.tar.gz to "myhdfstuff". Do not uncompress the files. - + 3. Download the CTestScript.cmake file to "myhdfstuff". - CTestScript.cmake file should not be modified. - + CTestScript.cmake file should not be modified. + 4. Download the platform configuration file, HDF518config.cmake, to "myhdfstuff". Do not modify the file unless you want to change default build environment. (See http://www.hdfgroup.org/HDF5/release/chgcmkbuild.html) - 5. From the "myhdfstuff" directory execute the CTest Script with the + 5. From the "myhdfstuff" directory execute the CTest Script with the following options: On 32-bit Windows with Visual Studio 2012, execute: @@ -90,31 +90,31 @@ To build HDF5 with the SZIP and ZLIB external libraries you will need to: On Linux and Mac, execute: ctest -S HDF518config.cmake -C Release -VV -O hdf5.log - The command above will configure, build, test, and create an install + The command above will configure, build, test, and create an install package in the myhdfstuff folder. It will have the format: HDF5-1.8.NN-. On Unix, will be "Linux". A similar .sh file will also be created. - On Windows, will be "win64" or "win32". If you have an - installer on your system, you will also see a similar file that ends + On Windows, will be "win64" or "win32". If you have an + installer on your system, you will also see a similar file that ends in either .exe (NSIS) or .msi (WiX). - + The -S option uses the script version of ctest. - - The value for the -C option (as shown above, "-C Release") must - match the setting for CTEST_BUILD_CONFIGURATION in the platform + + The value for the -C option (as shown above, "-C Release") must + match the setting for CTEST_BUILD_CONFIGURATION in the platform configuration file. - + The -VV option is for most verbose; use -V for less verbose. - + The "-O hdf5.log" option saves the output to a log file hdf5.log. 6. To install, "X" is the current release version - + On Windows, execute: HDF5-1.8."X"-win32.msi or HDF5-1.8."X"-win64.msi By default this program will install the hdf5 library into the - "C:\Program Files" directory and will create the following + "C:\Program Files" directory and will create the following directory structure: HDF_Group --HDF5 @@ -124,14 +124,14 @@ To build HDF5 with the SZIP and ZLIB external libraries you will need to: ------lib ------cmake - On Linux, change to the install destination directory + On Linux, change to the install destination directory (create it if doesn't exist) and execute: /myhdfstuff/HDF5-1.8."X"-Linux.sh After accepting the license, the script will prompt: By default the HDF5 will be installed in: "/HDF5-1.8."X"-Linux" Do you want to include the subdirectory HDF5-1.8."X"-Linux? - Saying no will install in: "" [Yn]: + Saying no will install in: "" [Yn]: Note that the script will create the following directory structure relative to the install point: HDF_Group @@ -141,10 +141,10 @@ To build HDF5 with the SZIP and ZLIB external libraries you will need to: ------include ------lib ------share - + On Mac you will find HDF5-1.8."X"-Darwin.dmg in the myhdfstuff folder. Click on the dmg file to proceed with installation. After accepting the license, - there will be a folder with the following structure: + there will be a folder with the following structure: HDF_Group --HDF5 ----1.8."X" @@ -152,7 +152,7 @@ To build HDF5 with the SZIP and ZLIB external libraries you will need to: ------include ------lib ------share - + By default the installation will create the bin, include, lib and cmake folders in the /HDF_Group/HDF5/1.8."X" @@ -160,47 +160,47 @@ To build HDF5 with the SZIP and ZLIB external libraries you will need to: ======================================================================== III. Quick Step Building HDF5 C Static Libraries and Tools with CMake ======================================================================== -Notes: This short set of instructions is written for users who want to - quickly build the just the HDF5 C static library and tools from +Notes: This short set of instructions is written for users who want to + quickly build the just the HDF5 C static library and tools from the HDF5 source code package using the CMake command line tools. - + Go through these steps: 1. Change to the development directory "myhdfstuff". 2. Uncompress the HDF5 source file - + 3. Create a folder "build" in the "myhdfstuff" directory. - - 4. Change into the "build" folder. - + + 4. Change into the "build" folder. + 5. Configure the C library, tools and tests with one of the following commands: On Windows 32 bit - cmake -G "Visual Studio 11 2012" -DCMAKE_BUILD_TYPE:STRING=Release -DBUILD_TESTING:BOOL=ON -DHDF5_BUILD_TOOLS:BOOL=ON ..\hdf5-1.8."X" + cmake -G "Visual Studio 11 2012" -DCMAKE_BUILD_TYPE:STRING=Release -DBUILD_SHARED_LIBS:BOOL=OFF -DBUILD_TESTING:BOOL=ON -DHDF5_BUILD_TOOLS:BOOL=ON ..\hdf5-1.8."X" On Windows 64 bit - cmake -G "Visual Studio 11 2012 Win64" -DCMAKE_BUILD_TYPE:STRING=Release -DBUILD_TESTING:BOOL=ON -DHDF5_BUILD_TOOLS:BOOL=ON ..\hdf5-1.8."X" - + cmake -G "Visual Studio 11 2012 Win64" -DCMAKE_BUILD_TYPE:STRING=Release -DBUILD_SHARED_LIBS:BOOL=OFF -DBUILD_TESTING:BOOL=ON -DHDF5_BUILD_TOOLS:BOOL=ON ..\hdf5-1.8."X" + On Linux and Mac - cmake -G "Unix Makefiles" -DCMAKE_BUILD_TYPE:STRING=Release -DBUILD_TESTING:BOOL=ON -DHDF5_BUILD_TOOLS:BOOL=ON ../hdf5-1.8."X" + cmake -G "Unix Makefiles" -DCMAKE_BUILD_TYPE:STRING=Release -DBUILD_SHARED_LIBS:BOOL=OFF -DBUILD_TESTING:BOOL=ON -DHDF5_BUILD_TOOLS:BOOL=ON ../hdf5-1.8."X" where "X" is the current release version. - + 6. Build the C library, tools and tests with this command: cmake --build . --config Release - + 7. Test the C library and tools with this command: ctest . -C Release - + 8. Create an install image with this command: cpack -C Release CPackConfig.cmake - - 9. To install + + 9. To install On Windows, execute: HDF5-1.8."X"-win32.msi or HDF5-1.8."X"-win64.msi By default this program will install the hdf5 library into the - "C:\Program Files" directory and will create the following + "C:\Program Files" directory and will create the following directory structure: HDF_Group --HDF5 @@ -210,14 +210,14 @@ Notes: This short set of instructions is written for users who want to ------lib ------cmake - On Linux, change to the install destination directory + On Linux, change to the install destination directory (create if doesn't exist) and execute: /myhdfstuff/build/HDF5-1.8."X"-Linux.sh After accepting the license, the script will prompt: By default the HDF5 will be installed in: "/HDF5-1.8."X"-Linux" Do you want to include the subdirectory HDF5-1.8."X"-Linux? - Saying no will install in: "" [Yn]: + Saying no will install in: "" [Yn]: Note that the script will create the following directory structure relative to the install point: HDF_Group @@ -227,10 +227,10 @@ Notes: This short set of instructions is written for users who want to ------include ------lib ------share - + On Mac you will find HDF5-1.8."X"-Darwin.dmg in the build folder. Click on the dmg file to proceed with installation. After accepting the license, - there will be a folder with the following structure: + there will be a folder with the following structure: HDF_Group --HDF5 ----1.8."X" @@ -241,41 +241,41 @@ Notes: This short set of instructions is written for users who want to ======================================================================== -IV. Further considerations +IV. Further considerations ======================================================================== 1. We suggest you obtain the latest CMake for windows from the Kitware - web site. The HDF5 1.8."X" product requires a minimum CMake version 3.1.0. - + web site. The HDF5 1.8."X" product requires a minimum CMake version 3.1.0. + 2. If you plan to use Zlib or Szip: - A. Download the binary packages and install them in a central location. - For example on Windows, create a folder extlibs and install the + A. Download the binary packages and install them in a central location. + For example on Windows, create a folder extlibs and install the packages there. Add the following CMake options: -DZLIB_LIBRARY:FILEPATH=some_location/lib/zlib.lib -DZLIB_INCLUDE_DIR:PATH=some_location/include -DSZIP_LIBRARY:FILEPATH=some_location/lib/szlib.lib -DSZIP_INCLUDE_DIR:PATH=some_location/include - where "some_location" is the full path to the extlibs folder. + where "some_location" is the full path to the extlibs folder. - B. Use source packages from an SVN server by adding the following CMake + B. Use source packages from an SVN server by adding the following CMake options: HDF5_ALLOW_EXTERNAL_SUPPORT:STRING="SVN" ZLIB_SVN_URL:STRING="http://some_location/zlib/trunk" SZIP_SVN_URL:STRING="http://some_location/szip/trunk" where "some_location" is the URL to the SVN repository. Also set CMAKE_BUILD_TYPE to the configuration type. - - C. Use source packages from a compressed file by adding the following + + C. Use source packages from a compressed file by adding the following CMake options: HDF5_ALLOW_EXTERNAL_SUPPORT:STRING="TGZ" ZLIB_TGZ_NAME:STRING="zlib_src.ext" SZIP_TGZ_NAME:STRING="szip_src.ext" TGZPATH:STRING="some_location" - where "some_location" is the URL or full path to the compressed + where "some_location" is the URL or full path to the compressed file and ext is the type of compression file. Also set CMAKE_BUILD_TYPE to the configuration type during configuration - - 3. If you are building on Apple Darwin platforms, you should add the + + 3. If you are building on Apple Darwin platforms, you should add the following options: Compiler choice - use xcode by setting the ENV variables of CC and CXX Shared fortran is not supported, build static: @@ -283,12 +283,12 @@ IV. Further considerations Additional options: CMAKE_ANSI_CFLAGS:STRING=-fPIC CTEST_USE_LAUNCHERS:BOOL=ON - CMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=OFF - + CMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=OFF + 4. Windows developers should install NSIS or WiX to create an install image with CPack. Visual Studio Express users will not be able to package HDF5 into an install image executable. - + 5. Developers can copy the config/cmake/cacheinit.cmake file and alter the the settings for the developers' environment. Then the only options needed on the command line are those options that are different. Example using HDF @@ -299,31 +299,31 @@ IV. Further considerations Notes: CMake and HDF5 - 1. Using CMake for building and using HDF5 is under active development. - While we have attempted to provide error-free files, please - understand that development with CMake has not been extensively + 1. Using CMake for building and using HDF5 is under active development. + While we have attempted to provide error-free files, please + understand that development with CMake has not been extensively tested outside of HDF. The CMake specific files may change before the next release. - - 2. CMake support for HDF5 development should be usable on any - system where CMake is supported. Please send us any comments on - how CMake support can be improved on any system. Visit the + + 2. CMake support for HDF5 development should be usable on any + system where CMake is supported. Please send us any comments on + how CMake support can be improved on any system. Visit the KitWare site for more information about CMake. - + 3. Build and test results can be submitted to our CDash server, please read the HDF and CDash document at: - www.hdfgroup.org/CDash/HowToSubmit. - + www.hdfgroup.org/CDash/HowToSubmit. + 4. See the appendix at the bottom of this file for examples of using a ctest script for building and testing. Using a ctest script is preferred because of its flexibility. - + Notes: CMake in General - 1. More information about using CMake can be found at the KitWare site at + 1. More information about using CMake can be found at the KitWare site at www.cmake.org. - - 2. CMake uses the command line; however, the visual CMake tool is + + 2. CMake uses the command line; however, the visual CMake tool is available for the configuration step. The steps are similar for all the operating systems supported by CMake. @@ -348,27 +348,27 @@ These five steps are described in detail below. The visual CMake executable is named "cmake-gui.exe" on Windows and should be available in your Start menu. For Linux, UNIX, and Mac users the - executable is named "cmake-gui" and can be found where CMake was - installed. - - Specify the source and build directories. - + executable is named "cmake-gui" and can be found where CMake was + installed. + + Specify the source and build directories. + ***** Make the build and source directories different. ****** - - For example on Windows, if the source is at c:\MyHDFstuff\hdf5, - then use c:\MyHDFstuff\hdf5\build or c:\MyHDFstuff\build\hdf5 as the + + For example on Windows, if the source is at c:\MyHDFstuff\hdf5, + then use c:\MyHDFstuff\hdf5\build or c:\MyHDFstuff\build\hdf5 as the build directory. - + RECOMMENDED: - Users can perform the configuration step without using the visual - cmake-gui program. We use the file cacheinit.cmake in the - config/cmake source folder for our testing. This file enables all of the - basic options and we turn specific options on or off for testing + Users can perform the configuration step without using the visual + cmake-gui program. We use the file cacheinit.cmake in the + config/cmake source folder for our testing. This file enables all of the + basic options and we turn specific options on or off for testing using the following command line within the build directory: - + cmake -C /config/cmake/cacheinit.cmake -G "" [-D] - - Where is + + Where is * MinGW Makefiles * NMake Makefiles * Unix Makefiles @@ -424,128 +424,128 @@ These five steps are described in detail below. 2. Configure the cache settings - 2.1 Visual CMake users, click the Configure button. If this is the first time you are - running cmake-gui in this directory, you will be prompted for the - generator you wish to use (for example on Windows, Visual Studio 11). - CMake will read in the CMakeLists.txt files from the source directory and - display options for the HDF5 project. After the first configure you + 2.1 Visual CMake users, click the Configure button. If this is the first time you are + running cmake-gui in this directory, you will be prompted for the + generator you wish to use (for example on Windows, Visual Studio 11). + CMake will read in the CMakeLists.txt files from the source directory and + display options for the HDF5 project. After the first configure you can adjust the cache settings and/or specify the locations of other programs. - + Any conflicts or new values will be highlighted by the configure - process in red. Once you are happy with all the settings and there are no - more values in red, click the Generate button to produce the appropriate - build files. - - On Windows, if you are using a Visual Studio generator, the solution and + process in red. Once you are happy with all the settings and there are no + more values in red, click the Generate button to produce the appropriate + build files. + + On Windows, if you are using a Visual Studio generator, the solution and project files will be created in the build folder. - + On linux, if you are using the Unix Makefiles generator, the Makefiles will be created in the build folder. 2.2 Preferred command line example on Windows in c:\MyHDFstuff\hdf5\build directory: - + cmake -C ../config/cmake/cacheinit.cmake -G "Visual Studio 11 2012" \ -DHDF5_ENABLE_SZIP_SUPPORT:BOOL=OFF -DHDF5_ENABLE_Z_LIB_SUPPORT:BOOL=OFF \ -DCMAKE_BUILD_TYPE:STRING=Release .. - 2.3 On Windows, if you are using a Visual Studio Express version you must + 2.3 On Windows, if you are using a Visual Studio Express version you must be sure that the following two options are correctly set/unset: - + HDF5_NO_PACKAGES:BOOL=ON HDF5_USE_FOLDERS:BOOL=OFF - + 3. Build HDF5 - - On Windows, you can build HDF5 using either the Visual Studio Environment + + On Windows, you can build HDF5 using either the Visual Studio Environment or the command line. The command line can be used on all platforms; Windows, linux, Unix, and Mac. To build from the command line, navigate to your build directory and execute the following: - - cmake --build . --config {Debug | Release} - + + cmake --build . --config {Debug | Release} + NOTE: "--config {Debug | Release}" may be optional on your platform. We - recommend choosing either Debug or Release on Windows. - - 3.1 If you wish to use the Visual Studio environment, open the solution - file in your build directory. Be sure to select either Debug or + recommend choosing either Debug or Release on Windows. + + 3.1 If you wish to use the Visual Studio environment, open the solution + file in your build directory. Be sure to select either Debug or Release and build the solution. - + 3.2.1 The external libraries (zlib and szip) can be configured to allow building the libraries by downloading from an SVN repository. The option is 'HDF5_ALLOW_EXTERNAL_SUPPORT'; by adding the following configuration option: -DHDF5_ALLOW_EXTERNAL_SUPPORT:STRING="SVN" - + The options to control the SVN URL (config/cmake/cacheinit.cmake file) are: ZLIB_SVN_URL:STRING="http://${svn_url}/zlib/trunk" SZIP_SVN_URL:STRING="http://${svn_url}/szip/trunk" ${svn_url} should be changed to your location. Also define CMAKE_BUILD_TYPE to be the configuration type. - + 3.2.2 Or the external libraries (zlib and szip) can be configured to allow building the libraries by using a compressed file. - The option is 'HDF5_ALLOW_EXTERNAL_SUPPORT' and is enabled by + The option is 'HDF5_ALLOW_EXTERNAL_SUPPORT' and is enabled by adding the following configuration option: -DHDF5_ALLOW_EXTERNAL_SUPPORT:STRING="TGZ" - - The options to control the SVN URL (config/cmake/cacheinit.cmake + + The options to control the SVN URL (config/cmake/cacheinit.cmake file) are: ZLIB_TGZ_NAME:STRING="zlib_src.ext" SZIP_TGZ_NAME:STRING="szip_src.ext" TGZPATH:STRING="some_location" - where "some_location/xxxx_src.ext" is the URL or full path to - the compressed file and where ext is the type of the compression + where "some_location/xxxx_src.ext" is the URL or full path to + the compressed file and where ext is the type of the compression file such as .bz2, .tar, .tar.gz, .tgz, or .zip. Also define CMAKE_BUILD_TYPE to be the configuration type. 4. Test HDF5 To test the build, navigate to your build directory and execute: - + ctest . -C {Debug | Release} - + NOTE: "-C {Debug | Release}" may be optional on your platform. We recommend choosing either Debug or Release to match the build - step on Windows. + step on Windows. 5. Packaging HDF5 (create an install image) - + To package the build into a simple installer using WiX toolset or the NullSoft installer NSIS on Windows, or into compressed files (.tar.gz, .sh, .zip), use the CPack tool. To package the build, navigate to your build directory and execute; - + cpack -C {Debug | Release} CPackConfig.cmake - + NOTE: See note 8 of this document for NSIS information. See note 9 of this document for WiX information. - Also, if you are using a Visual Studio Express version or do not - want to enable the packaging components, set HDF5_NO_PACKAGES + Also, if you are using a Visual Studio Express version or do not + want to enable the packaging components, set HDF5_NO_PACKAGES to ON (on the command line add -DHDF5_NO_PACKAGES:BOOL=ON) - - 6. The files that support building HDF5 with CMake are all the files in the - config/cmake folder, the CMakeLists.txt files in each source folder, and - CTestConfig.cmake. CTestConfig.cmake is specific to the internal testing - performed by The HDF Group. It should be altered for the user's + + 6. The files that support building HDF5 with CMake are all the files in the + config/cmake folder, the CMakeLists.txt files in each source folder, and + CTestConfig.cmake. CTestConfig.cmake is specific to the internal testing + performed by The HDF Group. It should be altered for the user's installation and needs. The cacheinit.cmake file settings are used by - The HDF Group for daily testing. It should be altered/ignored for the user's + The HDF Group for daily testing. It should be altered/ignored for the user's installation and needs. - 7. More information about using CMake can be found at the KitWare site, + 7. More information about using CMake can be found at the KitWare site, www.cmake.org. - + 8. Nullsoft Scriptable Install System - The Nullsoft Scriptable Install System (NSIS) is an open source installation - system. It was created by the WinAmp authors to distribute that application, - but it is now a general-purpose system which anyone might use. NSIS installers - recognize /S for silent installation and /D=dir to specify the - "output directory", which is where the program will be installed. These - options are case-sensitive, so be sure to type them in upper case. + The Nullsoft Scriptable Install System (NSIS) is an open source installation + system. It was created by the WinAmp authors to distribute that application, + but it is now a general-purpose system which anyone might use. NSIS installers + recognize /S for silent installation and /D=dir to specify the + "output directory", which is where the program will be installed. These + options are case-sensitive, so be sure to type them in upper case. 9. WiX Toolset - WiX--the Windows Installer XML toolset--lets developers create installers for + WiX--the Windows Installer XML toolset--lets developers create installers for Windows Installer, the Windows installation engine. See http://wixtoolset.org. @@ -553,14 +553,14 @@ These five steps are described in detail below. VI. CMake Option Defaults for HDF5 ======================================================================== -In the options listed below, there are three columns of information: -Option Name, Option Description, and Option Default. -The config/cmake/cacheinit.cmake file overrides the following values. +In the options listed below, there are three columns of information: +Option Name, Option Description, and Option Default. +The config/cmake/cacheinit.cmake file can override the following values. ---------------- General Build Options --------------------- -BUILD_SHARED_LIBS "Build Shared Libraries" OFF +BUILD_SHARED_LIBS "Build Shared Libraries" ON BUILD_STATIC_EXECS "Build Static Executabless" OFF -BUILD_TESTING "Build HDF5 Unit Testing" OFF +BUILD_TESTING "Build HDF5 Unit Testing" ON ---------------- HDF5 Build Options --------------------- HDF5_BUILD_CPP_LIB "Build HDF5 C++ Library" ON @@ -568,7 +568,7 @@ HDF5_BUILD_EXAMPLES "Build HDF5 Library Examples" ON HDF5_BUILD_FORTRAN "Build FORTRAN support" OFF HDF5_BUILD_HL_LIB "Build HIGH Level HDF5 Library" ON HDF5_BUILD_TOOLS "Build HDF5 Tools" ON -if (HDF5_BUILD_FORTRAN) +if (HDF5_BUILD_FORTRAN) HDF5_ENABLE_F2003 "Enable FORTRAN 2003 Standard" ON ---------------- HDF5 Advanced Options --------------------- @@ -591,14 +591,13 @@ HDF5_STRICT_FORMAT_CHECKS "Whether to perform strict file format checks" HDF5_TEST_VFD "Execute tests with different VFDs" OFF HDF5_USE_16_API_DEFAULT "Use the HDF5 1.6.x API by default" OFF HDF5_USE_FOLDERS "Enable folder grouping of projects in IDEs." OFF -HDF5_WANT_DATA_ACCURACY "IF data accuracy is guaranteed during data conversions" ON HDF5_WANT_DCONV_EXCEPTION "exception handling functions is checked during data conversions" ON HDF5_ENABLE_THREADSAFE "Enable Threadsafety" OFF -if (APPLE) +if (APPLE) HDF5_BUILD_WITH_INSTALL_NAME "Build with library install_name set to the installation path" OFF -if (CMAKE_BUILD_TYPE MATCHES Debug) +if (CMAKE_BUILD_TYPE MATCHES Debug) HDF5_ENABLE_TRACE "Enable API tracing capability" ON -if (HDF5_TEST_VFD) +if (HDF5_TEST_VFD) HDF5_TEST_FHEAP_VFD "Execute fheap test with different VFDs" ON ---------------- External Library Options --------------------- @@ -607,7 +606,7 @@ HDF5_ENABLE_SZIP_SUPPORT "Use SZip Filter" OFF HDF5_ENABLE_Z_LIB_SUPPORT "Enable Zlib Filters" OFF ZLIB_USE_EXTERNAL "Use External Library Building for ZLIB" 0 SZIP_USE_EXTERNAL "Use External Library Building for SZIP" 0 -if (HDF5_ENABLE_SZIP_SUPPORT) +if (HDF5_ENABLE_SZIP_SUPPORT) HDF5_ENABLE_SZIP_ENCODING "Use SZip Encoding" OFF if (WINDOWS) H5_DEFAULT_PLUGINDIR "%ALLUSERSPROFILE%/hdf5/lib/plugin" @@ -624,9 +623,9 @@ VII. User Defined Options for HDF5 Libraries with CMake Support for User Defined macros and options has been added. The file UserMacros.cmake has an example of the technique. In the folder, config/cmake/UserMacros, is an implementation for Windows Visual Studio -users for linking libraries to the static CRT - Windows_MT.cmake. +users for linking libraries to the static CRT - Windows_MT.cmake. -Copy the contents of the file, both macro and option, into the +Copy the contents of the file, both macro and option, into the UserMacros.cmake file. Then enable the option to the CMake configuration, build and test process. @@ -648,7 +647,7 @@ adding an option (${CTEST_SCRIPT_ARG}) to the platform configuration script. ######################################################################### cmake_minimum_required(VERSION 3.1.0 FATAL_ERROR) -set(CTEST_SOURCE_VERSION 1.8.15-pre7) +set(CTEST_SOURCE_VERSION 1.8.16) set(CTEST_SOURCE_NAME hdf5-${CTEST_SOURCE_VERSION}) set(CTEST_BINARY_NAME "build") set(CTEST_DASHBOARD_ROOT "${CTEST_SCRIPT_DIRECTORY}") @@ -709,7 +708,7 @@ endif() ################################################################### set(MODEL "Experimental") ######### Following describes computer ############ -## following is optional to describe build ## +## following is optional to describe build ## set(SITE_BUILDNAME_SUFFIX "STATIC") ################################################################### diff --git a/release_docs/RELEASE.txt b/release_docs/RELEASE.txt index 849a340..fdc1dac 100644 --- a/release_docs/RELEASE.txt +++ b/release_docs/RELEASE.txt @@ -5,19 +5,19 @@ HDF5 version 1.9.229 currently under development INTRODUCTION This document describes the differences between HDF5-1.9.0 and -HDF5 1.9.x snapshot, and contains information on the platforms -tested and known problems in HDF5-1.9.x. +HDF5 1.9.x snapshot, and contains information on the platforms +tested and known problems in HDF5-1.9.x. For more details check the HISTORY*.txt files in the HDF5 source. -Links to HDF5 1.9.x source code can be found on The HDF Group's +Links to HDF5 1.9.x source code can be found on The HDF Group's development FTP server at the following location: ftp://ftp.hdfgroup.uiuc.edu/pub/outgoing/hdf5/snapshots -User documentation for the snapshot can be accessed directly at this location: +User documentation for the snapshot can be accessed directly at this location: http://www.hdfgroup.uiuc.edu/HDF5/doc_dev_snapshot/H5_dev/ For more information, see the HDF5 home page: - + http://www.hdfgroup.org/HDF5/ If you have any questions or comments, please send them to the HDF Help Desk: @@ -41,1137 +41,67 @@ New Features Configuration: ------------- - - cmakehdf5: configure options added to enable or disable the building of - different API's and testings. See "cmakehdf5 --help" for details. - (AKC - 2014/12/09 HDFFV-8932) - - Autotools: Automake updated to 1.14.1 (ADB - 2014/04/08) - - CMake: Moved minimum CMake version to 2.8.11 which enables better library - include processing. (ADB - 2014/03/26) - - New configuration option added to change the default plugin path. - configure option is --with-default-plugin=location - cmake option is -DH5_DEFAULT_PLUGINDIR:PATH=location - HDFFV-8513. (ADB 2013/09/04) - - Rename FFLAGS to FCFLAGS in configure (ADB 2013/08/13) - - CMake minimum is now 2.8.10. (ADB 2013/01/14) - - A new tool, cmakehdf5, which is a build command script similar to - buildhdf5 is added and is available in the bin directory. - (AKC - 2012/12/12) - - Fixed AIX Fortran compiler flags to use appropriate settings for - debugging, profiling, optimization situations. HDFFV-8069. (AKC - 2012/09/27) - - Updated to latest autotools and changed all hard *.sh scripts to - configure managed *.sh.in files. Removed overloading of autotools - TESTS variable by examples and tests. Renamed configure.in to - configure.ac. (ADB - 2012/08/23 - HDFFV-8129) - - Added code to display the version information of XL fortran and C++ - in the summary of configure. (AKC - 2012/02/28 - HDFFV-7793) - - Configure now generates Makefiles that build in "silent make mode" - by default in which compile and link lines are significantly - simplified for clarity. To override this and view actual compile and - link lines during building, the --disable-silent-rules flag can be used - at configure time, or the 'make' command can be followed by V=1, to - indicate a "verbose" make. (MAM - 2011/4/14). - - Added mpicc and mpif90 as the default C and Fortran compilers for Linux - systems when --enable-parallel is specified but no $CC or $FC is defined. - (AKC - 2011/2/7) - - Added a new configure option, "--enable-unsupported", which can - be used to stop configure from preventing the use of unsupported - configure option combinations, such as c++ in parallel or parallel - HDF5 with threadsafe. Use at your own risk, as it may result in a - library that won't compile or run as expected! - (MAM - 2010/11/17 - Bug 2061) - - PHDF5 changed to use "mpiexec", instead of mpirun, as the default MPI - applications startup command as defined in the MPI-2 definition, section - 4.1. (AKC - 2010/6/11 - Bug 1921) - - Configure now adds appropriate defines for supporting large (64-bit) - files on all systems, where supported, by default, instead of only linux. - This largefile support is controllable with the --enable-largefile - configure option. This is replacing the linux-specific --enable-linux-lfs - option, which has been removed from configure. - (MAM - 2010/05/05 - 1772/1434) - - Upgraded versions of autotools used to generate configuration suite. - We now use Automake 1.11.1, Autoconf 2.65, and Libtool 2.2.6b. - MAM 2010/04/15. - - Added the xlc-* and mpcc_r-* BASENAME patterns to be recognized as IBM - compilers so that the ibm compiler options can be added properly. This - allows non-system-default compiler command names (e.g. xlc-m.n.k.l) be - recognized. AKC 2009/11/26. - - Configuration suite now uses Automake 1.11 and Autoconf 2.64. - MAM 2009/08/11. - - Changed default Gnu fortran compiler from g95 to gfortran since - gfortran is more likely installed with gcc now. -AKC 2009/07/19- - - Added libtool version numbers to generated c++, fortran, and - hl libraries. MAM 2009/04/19. - - Regenerated Makefile.ins using Automake 1.10.2. MAM 2009/04/19. - - Added a Make target of check-all-install to test the correctness of - installing via the prefix= or $DESTDIR options. AKC - 2009/04/14 - - Configuration suite now uses Libtool 2.2.6a. MAM 2008/10/24 - - - Configuration suite now uses Autoconf 2.61, Automake 1.10.1. - MAM 2008/05/05. - - - The new configure option "--disable-sharedlib-rpath" disables - embedding the '-Wl,-rpath' information into executables when - shared libraries are produced, and instead solely relies on the - information in LD_LIBRARY_PATH. (MAM - 2008/05/15) Library: -------- - - H5F_ACC_DEBUG labeled "deprecated" - - The symbol was originally used to emit some extra debugging - informationi in the multi VFD. The underlying functionality - was removed due to disuse in HDF5 1.8.16 though the symbol - remained defined since it was visible in H5Fpublic.h. - - In this release, the symbol has been labeled deprecated and will - not be defined when H5_NO_DEPRECATED_SYMBOLS is defined. - - (DER - 2015-04-30, HDFFV-1074) - - - The library can load filter libraries dynamically during runtime. Users - can set the search path through environment variable HDF5_PLUGIN_PATH - and call H5Pset_filter to enable a dynamic filter. (SLU - 2013/04/08) - - Added new API functions H5Dscatter and H5Dgather to scatter data to and - and gather data from a selection within a memory buffer. - (NAF - 2013/02/05) - - The library now supports the data conversion from enumeration to numeric - (integer and floating-point number) datatypes. See Issue 8221. - (SLU - 2012/10/23) - - The data sieve buffer size was for all the datasets in the file. It - could waste memory if any dataset size is smaller than the sieve buffer - size. Now the library picks the smaller one between the dataset size - and the sieve buffer size from the file access property. See Issue 7934. - (SLU - 2012/4/2) - - I added a new parameter of object access property list to the function - H5Rdereference (Issue 2763). It's called H5Rdereference2 now. The former - H5Rdereference function has been deprecated to H5Rdereference1. (SLU - - 2011/7/18) - - H5Tcreate now supports string type (fixed-length and variable-length). - (SLU - 2011/05/20) - - Added ability to cache files opened through external links. Added new - public functions H5Pset_elink_file_cache_size(), - H5Pget_elink_file_cache_size(), and H5Fclear_elink_file_cache(). - (NAF - 2011/02/17) - - Removed all old code for Metraowerks compilers, bracketed by - __MWERKS__). Metraowerks compiler is long gone. (AKC - 2010/11/17) - - Added support for threadsafety on windows using the windows threads - library. Use the HDF5_ENABLE_THREADSAFE option in CMake while on a - windows platform to enable this functionality. This is supported on - Windows Vista and newer Windows operating systems. (MAM - 2010/09/10) - - When a mandatory filter failed to write data chunks, the dataset - couldn't close (bug 1260). The fix releases all resources and closes - the dataset but returns a failure. (SLU - 2010/9/8) - - H5Tset_order and H5Tget_order now support all data types. A new byte - order H5T_ORDER_MIXED has been added specifically for compound datatype - and its derived type. Please see bug #1934. (SLU - 2010/8/23) - - Improved performance of the chunk cache by avoiding unnecessary b-tree - lookups of chunks already in cache. (NAF - 2010/06/15) - - Greatly improved performance of extending a dataset with early - allocation. (NAF - 2010/03/24 - 1637) - - Added support for filtering densely stored groups. Many of the API - functions related to filters have been extended to support dense groups - as well as datasets. Pipeline messages can now be stored in a group's - object header. (NAF/QAK - 2009/10/8) - - The embedded library information is displayed by H5check_version() if a - version mismatch is detected. Also changed H5check_version() to - suppress the warning message totally if $HDF5_DISABLE_VERSION_CHECK is 2 - or higher. (Old behavior treated 3 or higher the same as 1, that is - print a warning and allows the program to continue. (AKC - 2009/9/28) - - If a user does not care for the extra library information insert - in the executables, he may turn it off by --disable-embedded-libinfo - during configure. (AKC - 2009/9/15) - - Corrected problem where library would re-write the superblock in a file - opened for R/W access, even when no changes were made to the file. - (QAK - 2009/08/20, Bz#1473) - - Separated "factory" free list class from block free lists. These free - lists are dynamically created and manage blocks of a fixed size. - H5set_free_list_limits() will use the same settings specified for block - free lists for factory free lists. (NAF - 2009/04/08) - - Added support for dense attributes to H5Ocopy. (XCao/NAF - 2009/01/29) - - Added H5Pset_elink_cb and H5Pget_elink_cb functions to support a - user-defined callback function for external link traversal. - (NAF - 2009/01/08) - - Added H5Pset_elink_acc_flags and H5Pget_elink_acc_flags functions to - allow the user to specify the file access flags used to open the target - file of an external link. (NAF - 2009/01/08) - - Added H5Pset_chunk_cache() and H5Pget_chunk_cache() functions to allow - individual rdcc configuration for each dataset. Added - H5Dget_access_plist() function to retrieve a dataset access property - list from a dataset. (NAF - 2008/11/12) - - Added H5Iis_valid() function to check if an id is valid without producing - an error message. (NAF - 2008/11/5) - - Added two new public routines: H5Pget_elink_fapl() and - H5Pset_elink_fapl(). (see bug #1247) (VC - 2008/10/13) - - Improved free space tracking in file to be faster. (QAK - 2008/10/06) - - Added 'mounted' field to H5G_info_t struct. (QAK - 2008/07/15) Parallel Library: ----------------- - - Add H5Pget_mpio_no_collective_cause() function that retrive reasons - why the collective I/O was broken during read/write IO access. - (JKM - 2012/08/30 HDFFV-8143) - - Special Collective IO (IO when some processes do not contribute to the - IO) and Complex Derived Datatype MPI functionalities are no longer - conditionally enabled in the library by configure. They are always - enabled in order to take advantage of performance boosts from these - behaviors. Older MPI implementations that do not allow for these - functionalities can no longer by used by HDF5. (MAM - 2011/07/08). - - Modified parallel tests to run with arbitrary number of processes. The - modified tests are testphdf5 (parallel dataset access), t_chunk_alloc - (chunk allocation), and t_posix_compliant (posix compliance). The rest of - the parallel tests already use in the code the number of processes - available in the communicator. (CMC - 2009/04/28) Fortran Library: ---------------- - - Added parallel routine H5Pget_mpio_actual_io_mode_f (MSB - 2012/09/27) - - - Added for the C API the Fortran wrapper: - h5ocopy_f (MSB - 2012/03/22) - - - HDF5 Fortran library was enhanced to support Fortran 2003 standard. - The following features are available when the HDF5 library is configured - using --enable-fortran --enable-fortran2003 configure flags AND - if fortran compiler is Fortran2003 compliant: - - - Subroutines overloaded with the C_PTR derived type: - h5pget_f - h5pget_fill_value_f - h5pinsert_f - h5pregister_f - h5pset_f - h5pset_fill_value_f - h5rcreate_f - h5rderefrence_f - h5rget_name_f - h5rget_obj_type_f - - Subroutines overloaded with the C_PTR derived type - and simplified signatures: - h5aread_f - h5awrite_f - h5dread_f - h5dwrite_f - - New subroutines - h5dvlen_reclaim_f - h5literate_by_name_f - h5literate_f - h5ovisit_f - h5tconvert_f - - - Subroutines with additional optional parameters: - h5pcreate_class_f - (EIP - 2011/10/14) - - - Added for the C APIs the Fortran wrappers: - h5dget_access_plist_f - h5iis_valid_f - h5pset_chunk_cache_f - h5pget_chunk_cache_f - (MSB - 2009/04/17) - - - C++ Library: ------------ - - New member functions - + Overloaded CommonFG::getObjnameByIdx to take char* for name - + Overloaded CommonFG::getObjTypeByIdx to return type name as a char*. - (BMR - 2010/05/02) - + DataSet::getInMemDataSize() to simplify getting the dataset's - data size in memory. (BMR - 2009/07/26) - - These member functions were added as wrapper for H5Rdereference to - replace the incorrect IdComponent::dereference(). - void H5Object::dereference(H5File& h5file, void* ref) - void H5Object::dereference(H5Object& obj, void* ref) - In addition, these constructors were added to create the associated - objects by way of dereference: - Attribute(H5Object& obj, void* ref); - Attribute(H5File& file, void* ref); - DataSet(H5Object& obj, void* ref); - DataSet(H5File& file, void* ref); - DataType(H5Object& obj, void* ref); - DataType(H5File& file, void* ref); - Group(H5Object& obj, void* ref); - Group(H5File& obj, void* ref); - (BMR - 2008/08/10) - - Tools: ------ - - h5repack: Added ability to use plugin filters. HDFFV-8345 (ADB - 2013/09/04). - - h5dump: Added option -N --any_path, which searches the file for paths that - match the search path. HDFFV-7989 (ADB - 2013/08/12). - - h5dump: Added optional arg 0 to -A, which excludes attributes from display. - HDFFV-8134 (ADB - 2013/08/01). - - h5dump: Fixed displaying compression ratio for unknown or user-defined - filters. HDFFV-8344 (XCAO 2013/03/19) - - h5dump: Changed UNKNOWN_FILTER to USER_DEFINED_FILTER for user defined filter. - HDFFV-8346 (XCAO 2013/03/19) - - h5dump: Added capability for "-a" option to show attributes containing "/" - by using an escape character. For example, for a dataset "/dset" - containing attribute "speed(m/h)", use "h5dump -a "/dset/speed(\/h)" - to show the content of the attribute. See details at HDFFV-7523 - (PC -- 2012/03/12) - - h5dump: Added ability to apply command options across multiple files using a - wildcard in the filename. Example; "h5dump -H -d Dataset1 tarr*.h5". - HDFFV-7876 (ADB - 2012/03/12). - - h5repack: Improved performance for big chunked datasets (size > 128MB) - when used with layout (-l) or compression (-f) option. - It would perform much better prior to the improvement, - especially for cases that chunk dimentions looks like - "1024x5x1" (compare to "1x5x1024"). When bigger numbers - are toward front and smaller number is toward back in chunk - dimentions. HDFFV-7862 (JKM - 2012/03/01) - - h5dump: Added new option --no-compact-subset. This option will not - interpret the '[' character as starting the compact form of - subsetting. This is useful when the "h5dump error: unable to - open dataset "datset_name"" message is output because a dataset - name contains a '[' character. HDFFV-7689 (ADB - 2012/01/31) - - h5dump: Corrected schema location: - - (ADB - 2011/08/10) - - h5diff: Added new level for -v (verbose) option. The new levels are - 1 and 2. So -v1 and -v2 can be specified to view more - information about attributes differences. - Bug#2121 (JKM 2011/3/23) - - h5dump: Added new option --enable-error-stack. This option will display - error stack information in the output stream. This is useful - when the "h5dump: Unable to print data" message is output. - (ADB - 2011/02/24) - - h5diff: Add a new flag --exclude-path. Specified path to an object will - be excluded from comparing the two files or two groups. If group - is specified all the member objects will be excluded. - (JKM - 2010/09/16). - - h5ls: Add new flag --no-dangling-links. (refer to --help for details) - (JKM - 2010/06/15) - - h5ls: Add new flag --follow-symlinks. (refer to --help for details) - (JKM - 2010/05/25) - - h5diff: Add new flag --no-dangling-links. (refer to --help for details) - (JKM - 2010/02/10) - - h5diff: Add new flag --follow-symlinks. (refer to --help for details) - (JKM - 2010/01/25) - - h5diff: fix for displaying garbage value on LE machine for BE data. - (JKM - 2009/11/20) - - h5dump: subsetting now allows default for count. Also trailing ; in short form - can be omitted after last specified value. - (ADB - 2009/09/04) - - h5dump/h5ls: now can display data in region references - using new -R, --region flag. - (ADB - 2009/09/04) - - h5diff: new flag, -c, --compare, list objects that are not comparable. - (PVN - 2009/4/10 - 1368) - - h5diff new flag, -N, --nan, avoids NaNs detection. (PVN - 2009/4/10) - - h5dump correctly specifies XML dtd / schema urls (ADB - 2009/4/3 - 1519) - - h5repack now handles group creation order. (PVN - 2009/4/2 - 1402) - - h5dump: added a printing of the compression ratio of uncompressed and compressed - sizes for cases where compression filters are present. (PVN - 2008/05/01) - - h5dump: added an option to allow a user defined formatting string for printf - regarding floating point numbers. (PVN - 2008/05/06) - - h5dump: support for external links, display the object that the external link - points to. (PVN - 2008/05/12) - - h5repack: add a userblock to an HDF5 file during the repack. (PVN - 2008/08/26) - - h5repack: add 2 options that call H5Pset_alignment in the repacked file. (PVN - 2008/08/29) - - h5ls: added capability to traverse through external links when the -r - (recursive) flag is given. (NAF - 2008/09/16) - - h5ls: added -E option to enable traversal of external links. h5ls will - not traverse external links without this flag being set. - (NAF - 2008/10/06) - - h5diff: added support for long double (PVN - 2008/10/28) - - h5dump: binary output defaults to NATIVE with -b optionally accepting - the form of binary output (NATIVE, FILE, BE, LE). (PVN - 2008/10/30) - - h5diff: return 1 for file differences when both file graphs differ by any object. - Error return code was changed to 2 from -1. (PVN - 2008/10/30) - - h5import: TEXTFPE (scientific format) was deprecated. Use TEXTFP - instead (PVN - 2008/10/30) - - h5repack: When user doesn't specify a chunk size, h5repack now defines a default - chunk size as the same size of the size of the hyperslab used to read the chunks. - The size of the hyperslabs are defined as the size of each dimension or a - predefined constant, whatever is smaller. This assures that the chunk - read fits in the chunk cache. (PVN - 2008/11/21) - - h5diff: h5diff treats two INFINITY values different. Fixed by checking (value==expect) - before call ABS(...) at h5diff_array.c This will make that (INF==INF) is true - (INF is treated as an number instead of NaN) (PC -- 2009/07/28) - - h5diff: add option "--use-system-epsilon" to print difference if (|a-b| > EPSILON) - Change default to use strict equality (PC -- 2009/09/12) - - + + High-Level APIs: ------ - - Table: In version 3.0 of Table, "NROWS" (used to store number of records) was - deprecated (PVN - 2008/11/24) - - - Added Fortran wrappers for Dimension Scale APIs. HDFFV-3797 - h5dsset_scale_f - h5dsattach_scale_f - h5dsdetach_scale_f - h5dsis_attached_f - h5dsis_scale_f - h5dsset_label_f - h5dsget_label_f - h5dsget_scale_name_f - h5dsget_num_scales_f - (EIP for SB - 2011/10/13) - - - New API: h5ltpath_valid (Fortran: h5ltpath_valid_f) which checks - if a path is correct and determines if a link resolves to a valid - object and checks that the link does not dangle. (MSB- 2012/3/15) - - - A new API function H5DOwrite_chunk. It writes a data chunk directly - into a file bypassing hyperslab selection, data conversion, and - filter pipeline. The user must be careful with the function and - clearly understand the I/O process of the library. - (SLU - 2013/2/11) - - Documentation - ------------- + + Documentation + ------------- Support for new platforms, languages and compilers. ======================================= - - Intel V11.1 uses now -O3 optimization in production mode (EIP - 2010/10/08) - - PathScale compilers are recognized and can build the HDF5 library - properly. AKC - 2009/7/28 - - - SunOS 5.11 (emu) 32-bit and 64-bit with Sun C/C++ 5.12 compiler and - Sun Fortran 95 8.6 compiler. (SLU - 2013/04/15) Bug Fixes since HDF5-1.8.0 release ================================== Library ------- - - Incorrect usage of list in CMake COMPILE_DEFINITIONS set_property - - The CMake command, set_property with COMPILE_DEFINITIONS property - needs a quoted semi-colon separated list of values. CMake will - transform the list to a series of -D{value} for the compile. - - (ADB - 2014/12/09, HDFV-9041) - - - H5Z.c: H5Zfilter_avail(H5Z_filter_t id) - Added else block if the call to the internal H5Z_filter_avail(id) does not - fail and returns FALSE. This block calls the H5PL_load(H5PL_TYPE_FILTER, (int)id) - function to attempt to dynamically load the filter plugin. - (ADB - 2014/03/03 HDFFV-8629) - - Added const qualifier to source buffer parameters in H5Dgather and - H5D_scatter_func_t (H5Dscatter callback). (NAF - 2013/7/02) - - Fixed an error involving failure to write fill values to the user's - buffer when reading unallocated chunks from datasets that have a - fill value set to H5D_FILL_VALUE_DEFAULT. A consequence of this - was the reporting of spurious data values in h5dump and h5diff - output. - (HDFFV-8247; JP - 2013/05/03) - - Fixed an error that could occur when calling H5Ocopy within an - H5Literate callback (and possibly other situations). - (NAF - 2012/7/25 - HDFFV-5853) - - Fixed an error that would occur when copying an object with attribute - creation order tracked and indexed. (NAF - 2012/3/28 - HDFFV-7762) - - Fixed a bug in H5Ocopy(): When copying an opened object, call the - object's flush class action to ensure that cached data is flushed - so that H5Ocopy will get the correct data. - (VC - 2012/3/27 - HDFFV-7853) - - When an application tries to write or read many small data chunks and - runs out of memory, the library had a seg fault. The fix is to - return the error stack with proper information. (SLU - 2012/3/23. - Issue 7785) - - H5Pset_data_transform had seg fault in some cases like x*-100. It - works correctly now and handles other cases like 100-x or 2/x. - (SLU - 2012/3/15. Issue 7922) - - Fixed rare corruption bugs that could occur when using the new object - header format. (NAF - 2012/3/15 - HDFFV-7879) - - Creating a dataset in a read-only file caused seg fault when the file - is closed. It's fixed. The attemp to create a dataset will fail - with the error stack indicating the file is read-only. (SLU - - 2012/1/25. Issue 7756) - - Fixed a seg fault that could occur when shrinking a dataset with chunks - larger than 1 MB. (NAF - 2011/11/30 - HDFFV-7833) - - Fixed a bug that could cause file corruption when copying named - datatypes to a file using shared messages. (NAF - 2011/11/14) - - Fixed a bug that could cause H5Oget_info to return the wrong address - after copying a named datatype. (NAF - 2011/11/14) - - The library allowed the conversion of strings between ASCII and UTF8 - (Issue 7582). We have corrected it to report an error under this - situation. (SLU - 2011/11/8) - - The library had seg fault when it tried to shrink the size of compound type - through H5Tset_size immediately after the type was created (Issue - 7618). It's fixed now. (SLU - 2011/10/26) - - Fixed a bug that occurred when using H5Ocopy on a committed datatype - containing an attribute using that committed datatype. - (NAF - 2011/10/13 - Issue 5854) - - #ifdef _WIN32 instances changed to #ifdef H5_HAVE_WIN32_API and added - H5_HAVE_VISUAL_STUDIO checks where necessary. CMake only as configure - never set _WIN32. - - CLANG compiler with the options -fcatch-undefined-behavior and -ftrapv - discovered 3 problems in tests and tools' library (Issue 7674): - 1. In dsets.c, left shifting an unsigned int for 32 bits or more - caused undefined behavior. - 2. In dt_arith.c, the INIT_INTEGER macro definition has an overflow - when the value is negative minimal and is being subtracted one. - 3. In tools/lib/h5tools_str.c, right shifting an int value for 32 bits - or more caused undefined behavior. - All the problems have been corrected. (SLU - 2011/9/2) - - In v1.6 library, there was EOA for the whole MULTI file saved in the - super block. We took it out in v1.8 library because it's meaningless - for the MULTI file. v1.8 library saves the EOA for the metadata file, - instead. But this caused some backward compatibility problem. - v1.8 library couldn't open the file created with v1.6 library. We - fixed the problem by checking the EOA value to detect the file - created with v1.6 library. (SLU - 2011/6/22) - - When a dataset had filters and reading data failed, the error message - didn't say which filter isn't registered. It's fixed now. - (SLU - 2011/6/3) - - The datatype handler created with H5Tencode/decode used to have the - reference count 0 (zero). I have fixed it. It is 1 (one) now. - (SLU - 2011/2/18) - - Fixed a bug that caused big endian machines to generate corrupt files - when using the scale-offset filter with floating point data or - fill values. Note that such datasets will no longer be readable - by any machine after this patch. (NAF - 2010/02/02 - Bug 2131) - - Retrieving a link's name by index in the case where the link is - external and the file that the link refers to doesn't exist will - now fail gracefully rather than cause a segmentation fault. - (MAM - 2010/11/17) - - Modified library to always cache symbol table information. Libraries - version 1.6.3 have a bug which causes them to require this - information for some operations. (NAF - 2010/09/21 - 1864) - - Fixed a bug that could occur when getting information for a new-style - group that was previously opened through a file handle that was - later closed. (NAF - 2010/09/15) - - Added define check in H5public.h if stdint.h is supported by the C++ - compiler. This define is only available on Windows with VS2010 and - using CMake to build the library. (ADB - 2010/09/13 - Bug 1938) - - H5Eset_current_stack now also closes the error stack to be set as the - default. This is to avoid a potential problem (Bug 1799). - (SLU - 2010/9/7) - - Fixed the bug in the filter's public CAN_APPLY function. The return - value should be htri_t not herr_t (Bug #1239). (SLU - 2010/8/5) - - Fixed a bug in the direct I/O driver that could render files with - certain kinds of unaligned data unreadable or corrupt them. - (NAF - 2010/07/28) - - valgrind reported an error of copying data to itself when a new attribute - is written (Bug #1956). I fixed it by taking out the memcpy step in - the attribute code. (SLU - 2010/07/28) - - Fixed a bug that could cause file corruption when using non-default - sizes of addresses and/or lengths. This bug could also cause - uncorrupted files with this property to be unreadable. This bug - was introduced in 1.8.5. (NAF - 2010/07/16 - 1951) - - Fixed a file corruption bug that could happen when shrinking a - compressed dataset. (NAF - 2010/05/20) - - Fixed some memory leaks in VL datatype conversion when strings are - used as fill values. (MAM - 2010/05/12 - BZ# 1826) - - Fixed a bug when copying objects with NULL references with the - H5O_COPY_EXPAND_REFERENCE_FLAG flag set. (NAF - 2010/04/08 - 1815) - - Files can now be concurrently opened more than once using the core file - driver, as long as the backing store is used. (NAF - 2010/03/09) - - Added support for H5O_COPY_EXPAND_EXT_LINK_FLAG to H5Ocopy. External - links will now be expanded if this flag is set. - (NAF - 2010/03/05 - 1733) - - Fixed a bug where the library, when traversing an external link, would - reopen the source file if nothing else worked. (NAF - 2010/03/05) - - Fixed an intermittent bug in the b-tree code which could be triggered - by expanding and shrinking chunked datasets in certain ways. - (NAF - 2010/02/16) - - H5Tdetect_class said a VL string is a string type. But when it's - in a compound type, it said it's a VL type (Bug #1584). I fixed it - to be consistent. It always return string type. (SLU - 2009/12/10) - - Fixed a bug where writing and deleting many global heap objects (i.e. - variable length data) would render the file unreadable. Previously - created files exhibiting this problem should now be readable. - (NAF - 2009/10/27 - 1483) - - Fixed incorrect return value for H5Pget_preserve. (AKC - 2009/10/08 - 1628) - - Fixed an assertion failure that occurred when H5Ocopy was called on a - dataset using a vlen inside a compound. (NAF - 2009/10/02 - 1597) - - Fixed incorrect return value for H5Pget_filter_by_id1/2 in H5Ppublic.h. - (NAF - 2009/09/25 - 1620) - - Fixed a bug where properties weren't being compared with the registered - compare callback. (NAF - 2009/09/25 - 1555) - - Fixed a bug where H5Pget_fitler_by_id would succeed when called for a - filter that wasn't present. (NAF - 2009/06/25 - 1250) - - Fixed an issue with committed compound datatypes containing a vlen. - Also fixed memory leaks involving committed datatypes. - (NAF - 2009/06/10 - 1593) - - Added versioning to H5Z_class_t struct to allow compatibility with 1.6 - API. (NAF - 2009/04/20 - 1533) - - Fixed a problem with using data transforms with non-native types in the - file. (NAF - 2009/04/20 - 1548) - - Added direct.h include file to windows section of H5private.h - to fix _getcwd() warning. (ADB - 2009/04/14 - 1536) - - Fixed a bug that prevented external links from working after calling - H5close(). (NAF - 2009/04/10 - 1539) - - Modified library to write cached symbol table information to the - superblock, to allow library versions 1.3.0 to 1.6.3 to read files - created by this version. (NAF - 2009/04/08 - 1423) - - Changed skip lists to use a deterministic algorithm. The library should - now never call rand() or srand(). (NAF - 2009/04/08 - 503) - - Fixed a bug where H5Lcopy and H5Lmove wouldn't create intermediate - groups when that property was set. (NAF - 2009/04/07 - 1526) - - Fixed a bug that caused files with a user block to grow by the size of - the user block every time they were opened. - (NAF - 2009/03/26 - 1499) - - Fixed a rare problem that could occur with files using the old (pre 1.4) - array datatype. (NAF - 2009/03/23) - - Modified library to be able to open files with corrupt root group symbol - table messages, and correct these errors if they are found. Such - files can only be successfully opened with write access. - (NAF - 2009/03/23 - 1189) - - Removed the long_long #define and replaced all instances with - "long long". This caused problems with third party products. All - currently supported compliers support the type. (ADB - 2009/03/05) - - Fixed various bugs that could prevent the fill value from being written - in certain rare cases. (NAF - 2009/02/26 - 1469) - - Fixed a bug that prevented more than one dataset chunk from being cached - at a time. (NAF - 2009/02/12 - 1015) - - Fixed an assertion failure caused by opening an attribute multiple times - through multiple file handles. (NAF - 2009/02/12 - 1420) - - Fixed a problem that could prevent the user from adding attributes (or - any object header message) in some circumstances. - (NAF - 2009/02/12 - 1427) - - Fixed a bug that could cause problems when an attribute was added to a - committed datatype using the committed datatype's datatype. - (NAF - 2009/02/12) - - Fixed a bug that could cause problems when copying an object with a - shared message in its own object header. (NAF - 2009/01/29) - - Changed H5Tset_order to properly reject H5T_ORDER_NONE for most - datatypes. (NAF - 2009/01/27 - 1443) - - Fixed a bug where H5Tpack wouldn't remove trailing space from an - otherwise packed compound type. (NAF - 2009/01/14) - - Fixed up some old v2 btree assertions that get run in debug mode that - were previously failing on compilation, and removed some of the - more heavily outdated and non-rewritable ones. (MAM - 2008/12/15) - - Fixed a bug that could cause problems when "automatically" unmounting - multiple files. (NAF - 2008/11/17) - - H5Ovisit and H5Ovisit_by_name will now properly terminate when the - callback function returns a positive value on the starting object. - (NAF - 2008/11/03) - - Fixed an error where a null message could be created that was larger - than could be written to the file. (NAF - 2008/10/23) - - Corrected error with family/split/multi VFD not updating driver info - when "latest" version of the file format used. (QAK - 2008/10/14) - - Corrected alignment+threshold errors to work correctly when metadata - aggregation is enabled. (QAK - 2008/10/06) - - Changed H5Fget_obj_count and H5Fget_obj_ids to ignore objects registered - by the library for internal library use. (NAF - 2008/10/06) - - Fixed potential memory leak during compound conversion. - (NAF - 2008/10/06) - - Changed the return value of H5Fget_obj_count from INT to SSIZE_T. Also - changed the return value of H5Fget_obj_ids from HERR_T to SSIZE_T and - the type of the parameter MAX_OBJS from INT to SIZE_T. (SLU - 2008/09/26) - - Fixed an issue that could cause data to be improperly overwritten - during compound type conversion. (NAF - 2008/09/19) - - Fixed pointer alignment violations that could occur during vlen - conversion. (NAF - 2008/09/16) - - Fixed problem where library could cause a segmentation fault when - an invalid location ID was given to H5Giterate(). (QAK - 2008/08/19) - - Fixed improper shutdown when objects have reference count > 1. The - library now tracks reference count due to the application separately - from that due to internal library routines. (NAF - 2008/08/19) - - Fixed assertion failure caused by incorrect array datatype version. - (NAF - 2008/08/08) - - Fixed an issue where mount point traversal would fail when using - multiple handles for the child. (NAF - 2008/08/07) - - Fixed an issue where mount points were inaccessible when using multiple - file handles for the parent. The mount table is now in the shared - file structure (the parent pointer is still in the top structure). - (NAF - 2008/08/07) - - when an attribute was opened twice and data was written with one of the handles, - the file didn't have the data. It happened because each handle had its own - object structure, and the empty one overwrote the data with fill value. This is - fixed by making some attribute information like the data be shared in the - attribute structure. SLU - 2008/07/22 - - Fixed issue where a group could have a file mounted on it twice. - (QAK - 2008/07/15) - - Fixed a Windows-specific issue in the ohdr test which was causing users - in some timezones to get false errors. This a deficiency in the Windows - mktime() function, and has been handled properly. SJW - 2008/06/19 - - Fixed the problem with the searching of target file for H5Lcreate_external(). - The searching pattern will depend on whether the target file's - pathname is an absolute or a relative path. Please see the description - in the RM for H5Lcreate_external(). (VC - 2008/04/08) - - Fixed possible file corruption bug when encoding datatype - descriptions for compound datatypes whose size was between - 256 & 511 bytes and the file was opened with the "use the - latest format" property enabled (with H5Pset_libver_bounds). - (QAK - 2008/03/13) - - Fixed bug in H5Aget_num_attrs() routine to handle invalid location - ID correctly. (QAK - 2008/03/11) - - H5Dset_extent: when shrinking dimensions, some chunks were not deleted. - (PVN - 2009/01/8) - - Added code to maintain a min_clean_fraction in the metadata cache when - in serial mode. (MAM - 2009/01/9) - - Configuration ------------- - - CMake: When CMake commands are executed individually on the command line - and the external filters are being built, the CMAKE_BUILD_TYPE define - must be set to the same value as the configuration - (-DCMAKE_BUILD_TYPE:STRING=Release if using -C Release). This is needed - by the the szip and zlib filter build commands. (ADB - HDFFV-8695) - - CMake: Remove use of XLATE_UTILITY program. (ADB - 2014/03/28 HDFFV-8640) - - CMake: Added missing quotes in setting the CMAKE_EXE_LINKER_FLAGS for the - MPI option. (ADB - 2014/02/27 HDFFV-8674) - - Modified H5detect.c to scan floating point types for padding bits before - analyzing the type further. This should fix problems with gcc 4.8 - (NAF - 2013/09/19 - HDFFV-8523/HDFFV-8500) - - Fixed Makefile issue in which "-Wl," was not properly specified - prior to -rpath when building parallel fortran libraries with - an Intel compiler. (MAM - 2012/03/26) - - Makefiles generated by other packages using h5cc as the compiler - no longer error when 'make' is invoked more than once in order - to 'rebuild' after changes to source. (MAM - 2012/03/26) - - Added --enable-fortran2003 flag to enable Fortran2003 support - in the HDF5 Fortran library. The flag should be used along with the - --enable-fortran flag and takes affect only when Fortran compiler - is Fortran2003 compliant. (EIP - 2011/11/14) - - - In Windows platform, the default VFD, was Windows VFD, is restored back - to the SEC2, aka POSIX, VFD. The Windows VFD is deprecated. HDFFV-7740 - (AKC 2011/09/26) - - Removed config/ibm-aix6.x. All IBM-AIX settings are in one file, - ibm-aix. (AKC - 2011/4/14) - - Shared C libraries are no longer disabled on Mac when Fortran - is enabled. Shared Fortran libraries are still not supported on Mac, - so configure will disable them by default, but this is overridable - with the new --enable-unsupported configure option. The configure - summary has been updated to reflect the fact that the shared-ness of - the C++/Fortran wrapper libraries may not align with the C library. - (MAM - 04/11/2011 - HDFFV-4353). - - Removed recognition of the parallel compilers of LAM(hcc) and - ChMPIon(cmpicc) since we have no access to these two MPI implementations - and cannot verify their correctness. (AKC - 2010/7/14 - Bug 1921) - - Removed the following config files, as we no longer support them: - config/dec-osf*, config/hpux11.00, config/irix5.x, - config/powerpc-ibm-aix4.x config/rs6000-ibm-aix5.x config/unicos* - MAM - 2009/10/08 - - Modified configure and make process to properly preserve user's CFLAGS - (and company) environment variables. Build will now properly use - automake's AM_CFLAGS for any compiler flags set by the configure - process. Configure will no longer modify CFLAGS directly, nor will - setting CFLAGS during make completely replace what configure has set up. - MAM - 2009/10/08 - - Support for TFLOPS, config/intel-osf1, is removed since the TFLOPS - machine has long retired. AKC - 2009/10/06. - - Added $(EXEEXT) extension to H5detect when it's executed in the - src/Makfile to generate H5Tinit.c so it works correctly on platforms - that require the full extension when running executables. - MAM - 2009/10/01 - BZ #1613 - - Configure will now set FC and CXX to "no" when fortran and c++ - are not being compiled, respectively, so configure will not run - some of the compiler tests for these languages when they are not - being used. MAM - 2009/10/01 - - The PathScale compiler (v3.2) was mistaken as gcc v4.2.0 but it fails to - recognize some gcc options. Fixed. (see bug 1301). AKC - 2009/7/28 - - - The --enable-static-exec flag will now properly place the -static flag - on the link line of all installed executables. This will force the - executable to link with static libraries over shared libraries, provided - the static libraries are available. MAM - 2009/08/31 - BZ #1583 - - The --includedir=DIR configuration option now works as intended, and can - be used to specify the location to install C header files. The default - location remains unchanged, residing at ${prefix}/include. - MAM - 2009/03/10 - BZ #1381 - - Configure no longer removes the '-g' flag from CFLAGS when in production - mode if it has been explicitly set in the CFLAGS environment variable - prior to configuration. MAM - 2009/03/09 - BZ #1401. - - Fixed error with 'make check install' failing due to h5dump - needing other tools built first. MAM - 2008/10/24. - - Wpen using shared szip, it is no longer necessary to specify - the path to the shared szip libraries in LD_LIBRARY_PATH. MAM - - 2008/10/24. - - The file libhdf5_fortran.settings is not installed since its content - is included in libhdf5.settings now. AKC - 2008/10/21 - - "make DESTDIR=xxx install" failed to install some tools and files - (e.g., h5cc and fortran modules). Fixed. AKC - 2008/10/8. - - Autotools: An export of LD_LIBRARY_PATH= was - removed from configure and make installcheck was revised to run - scripts installed in share/hdf5_examples to use the installed h5cc, etc. - to compile and run example source files also installed there. Make - installcheck will now fail when a shared szip or other external lib file - cannot be found in the same manner that executables compiled and linked - with h5cc will fail to run when those lib files cannot be found after - install. Make installcheck should pass after setting LD_LIBRARY_PATH to the - szip location. - (LRK - 2014/04/16) Performance ------------- - - Removed program perform/benchpar from the enable-build-all list. The - program will be retired or moved to another location. HDFFV-8156 - (AKC 2012/10/01) - - Retired program perform/mpi-perf. Its purpose has been incorporated - into h5perf before. (AKC 2012/09/20) - - ifdefs added to tests around include unistd.h and function to simulate - getlogin() on Windows. - (ADB - 2011/08/15) - - perf_serial test added to Windows projects and check batch file. - (ADB - 2009/06/11) + Fortran -------- - - Fixed a typo in return value of the nh5dread_f_c function ( was 1 - instead of 0 on success); fixed the return value to make it consistent - with other Fortran functions; cleaned the code from debug statements. - (EIP - 2012/06/23) - - - Fixed problem writing/reading control characters to a dataset; writing - a string containing: alerts, backspace, carriage_return, form_feed, - horizontal_tab, vertical_tab, new_line is now tested and working. - (MSB - 2012/09/01) - - - Corrected the integer type of H5S_UNLIMITED_F to HSIZE_T (MSB - 2012/09/01) - - - Corrected the number of continuation lines in the src files - to be less then 32 lines for F95 compliance. (MSB - 2012/10/01) Tools ----- - - h5repack: h5repack would not attempt to remove UD filters. Added a - check to h5repack for UD filters that checks if the filter can - be dynamically loaded. This will require a change in the library to - add the H5PL_load() to the H5Zfilter_avail(). (ADB - 2014/03/03 HDFFV-8629) - - h5repack: Fixed failure for converting a layout of small chunked dataset - (size < 1K) to contiguous layout. HDFFV-8214 (JKM 2013/03/18) - - h5diff: Fixed to return correct exit code 1 when detect unique extra - attribute. Prior to this fix, h5diff returned exit code 0 indicating - two files are identical. HDFFV-7643 (JKM 2013/02/15) - - h5diff: Improved speed when comparing HDF5 files with lots of - attributes. Much slower performance was identified with release - version from 1.8.7 to 1.8.10 compared to 1.8.6. (JKM 2012/10/19) - - h5repack: "h5repack -f NONE file1.h5 out.h5" command failed if - source file contains chunked dataset and a chunk dim is bigger than - the dataset dim. Another issue is that the command changed max dims - if chunk dim is smaller than the dataset dim. - These issue occurred when dataset size is smaller than 64k (compact - size limit) Fixed both. - HDFFV-8012 (JKM 2012/09/24) - - h5diff: Fixed not to accumulate attribute difference to dataset - difference in verbose mode (-v, -r), which caused incorrect - difference between dataset and group/datatype object if attribute - exist with any differences. This also lead to fix inconsistent - format indicating difference between dataset and group/datatype - object. HDFFV-5919 (JKM 2012/09/05) - - h5diff: Fixed the incorrect result when comparing attribute data - values and the data type has same class but different size. - HDFFV-7942 (JKM 2012/08/15) - - ph5diff: Fixed intermittent hang issue on a certain operation in - parallel mode. It was detected by daily test for comparing - non-comparable objects, but it could have occurred in other - operations depend on machine condition. HDFFV-8003 (JKM 2012/08/01) - - h5diff: Fixed test failure for "make check" due to failure of - copying test files when performed in HDF5 source tree. Also applied - to other tools. - HDFFV-8107 (JKM 2012/08/01) - - h5diff: Fixed the Function COPY_TESTFILES_TO_TESTDIR() of - testh5diff.sh to better report when there is an error in the file - copying. HDFFV-8105 (AKC -2012/07/22) - - h5diff: Fixed not to check and display dangling link status without - --follow-symlinks option. This also improved performance when - comparing lots of external links without the --follow-symlinks - option. HDFFV-7998 (JKM 2012/04/26) - - h5unjam: Fixed sefgault when used -V (show version) option. - HDFFV-8001 (JKM 2012/04/19) - - h5repack: Fixed a failure when change the chunk size of a specified - chunked dataset with unlimited max dims. HDFFV-7993 (JKM 2012/04/11) - - h5diff: Fixed failure for comparing same named object with different - object types in comparing groups. Prior to the fix, h5diff resulted - in error. After the fix, h5diff detects such case as non-comparable - and display messages accordingly. HDFFV-7664 (JKM 2012/03/28) - - h5diff: If unique objects exists only in one file and try to exclude - the unique objects with --exclude-path option, h5diff missed - excluding some objects. - Fixed to exclude objects correctly in such case. - HDFFV-7837 (JKM 2012/03/20) - - h5dump: Added tools library error stack to properly catch error - information generated within the library. - HDFFV-7958 (ADB 2012/03/12) - - h5dump: Dangling links no longer throw error message, change process - when open link fails. - HDFFV-7839 (ADB 2012/03/12) - - h5diff: When two symbolic dangling links are compared with - --follow-symlinks option, the result should be same. It worked for - comparing two files, but didn't work for comparing two objects. - HDFFV-7835 (JKM 2012/03/09) - - h5dump: Refactored code to remove duplicated functions. Split XML - functions from DDL functions. Corrected indentation and formatting - errors. Also fixed subsetting counting overflow (HDFFV-5874). Verified - all tools call tools_init() in main. - HDFFV-7560 (ADB 2012/02/17) - - h5diff: fixed to prevent from displaying error stack message when - comparing the two dangling symlinks with follow-symlinks option. - HDFFV-7836 (JKM 2012/01/13) - - h5repack: fixed memory leak for handling variable length string in - attribute. HDFFV-7840 (JKM 2012/01/06) - - h5ls: fixed segfault when access region reference data in an - attribute. HDFFV-7838 (JKM 2011/12/29) - - h5diff: fixed segfault over non-comparable attribute with different - dimention or rank, along with '-c' option to display details. - HDFFV-7770 (JKM 2011/10/24) - - Fixed h5diff to display all the comparable object and attribute - regardless of non-comparables. HDFFV-7693 (JKM 2011/09/16) - - Fixed h5repack to update values of references(object and region) of - attributes in h5repack for 1) references, 2) ARRAY of references, - 3) VLEN of references, and 4) COMPOUND of references. - (JIRA HDF5 5932) PC -2011/09/14 - - h5diff: fixed segfault over dataset with container types - (array,lven) with multiple nested compound types. - (ex: compound->array->compound, compound->vlen->compound) - HDFFV-7712 JKM (2011/09/01) - - h5repack: added macro to handle failure in H5Dread/write when memory - allocation failed inside the library. (PC -- 2011/08/19) - - Fixed h5jam not to allow specifying an HDF5 formatted file as input - file for -u (user block file) option, because the original HDF5 file - will not be accessible if allows. HDFFV-5941 (JKM 2011/08/15) - - Revised command help pages of h5jam and h5unjam. The descriptions - were not up to date and some were missing. - HDFFV-7515 (JKM 2011/08/15) - - h5repack: h5repack failed to copy dataset if the layout is changed - from chunked with unlimited dims to contiguous. HDFFV-7649 - (PC -- 2011/07/15) - - h5diff: "--delta" option considers two NaN of the same type are - different, which is wrong based on h5diff description in Reference - Manual. HDFFV-7656 (PC -- 2011/07/15) - - Fixed h5diff to display instructive error message and exit with 1 - when mutually exclusive options (-d, -p and --use-system-epsilon) - are used together. HDFFV-7600 (JKM 2011/07/07) - - Fixed h5dump to display the first line of each element into correct - position for multiple dimention array type. - Before this fix, the first line of each element in array were - displayed after the last line of previous element without - moving to the next line (+indentation). - Bug #HDFFV-5878 (JKM 2011/06/15) - - Fixed h5dump to display correct value for H5T_STD_I8LE dataset - on a system (ppc64, linux, Big-Endian, clustering). - Bug #HDFFV-7594 (ABERT & JKM 2011/05/12) - - Fixed h5diff to compare file itself correctly. Previously h5diff - reported either different or not compatible in certain cases even - comparing file itself. This fix also improve performance when - comparing same target objects through verifying the obj&file - addresses before comparing the details in the objects (ex: datasets - or attributes) Bug #HDFFV-5928 (XCAO & JKM 2011/05/06) - - Updated h5dump test case script to prevent entire test failure upon - source directory is read-only. Bug# HDFFV-4342 (JKM 2011/4/12) - - Fixed h5dump displaying incorrect values for H5T_STD_I8BE type data in - attribute on Big-Endian machine. H5T_STD_I8BE is unsigned 8bit type, - so h5dump is supposed to display -2 instead of 254. It worked - correctly on Little-Endian system , but not on Big-Endian system. - Bug #HDFFV-4358 (JKM 2011/04/08) - - Updated to unify option name to '--enable-error-stack' for printing - HDF5 error stack messages for HDF5 tools. h5ls and h5dump for now. - For h5ls, this replaces "-e/--errors" option, which is deprecated. - Bug#2182 (JKM 2011/3/30) - - Fix h5diff for --use-system-epsilon option: the calculation changed - from ( |a - b| / b ) to ( |a - b| ). This was decided for better - performance. Bug#2184 (JKM 2011/3/24) - - Fixed output for H5T_REFERENCE in h5dump. According to the BNF document - the output of a H5T_REFERENCE should be followed by the type; - ::= H5T_REFERENCE { } - ::= H5T_STD_REF_OBJECT | H5T_STD_REF_DSETREG - Previously this was only displayed if the -R option was used. - Bug#1725 (ADB 2011/3/28) - - Fix h5diff issues for #1: h5diff compared attributes correctly only - when two objects have the same number of attributes and attribute - names are identical, #2: didn't display useful information about - attribute difference. Bug#2121 (JKM 2011/3/17) - - Fixed memory leak for h5diff when accessing symbolic links with - --follow-symlink option. Bug#2214 (JKM 2011/3/18) - - Fixed memory leak for h5diff when access variable length string - data. Bug#2216 (JKM 2011/3/18) - - Fixed and improved help page for -a option of h5ls. - Bug#1904 (JKM 2011/3/11) - - Fixed h5dump not to include attribute values in the output file when - h5dump "-y -o output_file" options were used. The problem was introduced - in HDF5 1.8.6 by showing data pointed by region references. (XCAO 2011/3/9) - - Fixed h5copy to be able to copy any object into the same HDF5 file. - Previously h5copy displayed error message when target file is same - as source file. (XCAO 2011/3/8) - - Fixed h5dump for skipping some values for long array type dataset on - Windows. This issue only occurred on Windows due to the different - return behavior from _vsnprintf() funtion. Bug#2161 (JKM 2011/3/3) - - Fixed h5dump for skipping array indices every certain number - when the array type dataset is relatively big. The certain number - varies according to the size of array. Bug#2092 (JKM 2011/2/15). - - Fixed h5diff for the segfault when compares compound datasets - with combination of fixed length string types and vlen string types - in certain orders. bug#2089 (JKM 2010/12/28) - - Improve h5diff performance. 1) use HDmemcmp() before comparing each - elements. 2) replace expensive H5Tequals() calls 3) retrieve datatype - information at dataset level not each element level for compound - datasets - - Fixed h5ls to display nested compound type with curly bracket - when -S (--simple) option is used with -l (--label), so it shows - which member (in curly bracket) belong to which nested compound type - and make the output make sense. bug#1979 (JKM 2010/11/09) - - Fixed h5diff to handle variable-length strings in a compound dataset - correctly. (also variable-length string array in a compound dataset) - Garbage values were displayed when h5diff compared multiple - variable-length strings in a compound type dataset. - Bug#1989 (JKM 2010/10/28) - - Fixed h5copy to fail gracefully when copying object to non-exist - group without -p option. Bug#2040 (JKM 2010/10/18) - - Fixed to compare member objects and groups recursively when two - files or groups are specified to be compared. Bug#1975 - (JKM 2010/9/16) - - Make h5repack be able to convert a layout to COMPACT for small size - dataset as default. bug#1896 (JKM 2010/09/15) - - Change h5ls not to manipulate special characters in object name or - attribute name for smart display. bug#1784 (JKM 2010/06/28) - - Fixed h5ls to return exit code 1 (error) when non-existent file is - specified. bug#1793. (JKM 2010/04/27) - - h5copy failed to copy dangling link when the link is specified - directly. bug#1817. (JKM 2010/04/22) - - h5repack lost attributes from a dataset of reference type. bug#1726. - (JKM 2010/3/25) - - h5repack sets NULL for object reference value for group or - named datatype. bug#1814. (JKM 2010/03/19) - - h5diff: fixed incorrect behavior (hang) in parallel mode when - specify invalid options (ex: -v and -q) (JKM 2010/02/17) - - h5dump/h5ls display buffer resize fixed in tools library. - (ADB - 2009/07/21 - 1520) - - Fixed many problems that could occur when using h5repack with named - datatypes. (NAF - 2009/4/20 - 1516/1466) - - h5dump, h5diff, h5repack were not reading (by hyperslabs) datasets - that have a datatype datum size greater than H5TOOLS_BUFSIZE, a - constant defined as 1024Kb, such as array types with large - dimensions (PVN - 2009/4/1 - 1501) - - h5import: By selecting a compression type, a big endian byte order was being - selected (PVN - 2009/3/11 - 1462) - - zip_perf.c had missing argument on one of the open() calls. Fixed. - (AKC - 2008/12/9) - - h5dump now checks for uniqueness of committed datatypes. - (NAF - 2008/10/15) - - Fixed unnecessary indentation of committed datatypes in h5dump. - (NAF - 2008/10/15) - - Fixed bugs in h5stat:segmemtation fault when printing groups and - print warning message when traversal of objects is unsuccessful. - (see bug #1253) (VC- 2008/10/13) - - Fixed bug in h5ls that prevented relative group listings (like - "h5ls foo.h5/bar") from working correctly (QAK - 2008/06/03) - - Fixed bug in h5diff that prevented datasets & attributes with - variable-length string elements from comparing correctly. - (QAK - 2008/02/28) - - h5import bug on Windows w/binary datasets. fread in windows needs a - binary file to be open with 'rb' instead of 'r' otherwise it - terminates execution if an end of file character is found on the - input file. Besides that the binary file generated needs to be open - with 'wb' , otherwise an end of line character is read twice. - (PVN - 2008/02/19) - - Fixed bug in h5dump that caused binary output to be made only for the first - dataset, when several datasets were requested. (PVN - 2008/04/07) - - h5dump: when doing binary output (-b), the stdout printing of attributes - was done incorrectly. Removed printing of attributes when doing binary - output. PVN - 2008/06/05 - High-Level APIs: ------ - - Fixed problem with H5DSget_scale_name including the NULL terminator in - the size calculation returned by the function. The API does not - include the NULL terminator in the size returned (MSB- 2013/2/10) - - - Fixed problem with H5TBdelete_record destroying all data following the deletion - of a row. (MSB- 2012/7/26) - - - Fixed H5LTget_attribute_string not closing an object identifier when an - error occurs. (MSB- 2012/7/21) - - - Fixed the H5LTdtype_to_text function. It had some memory problems when - dealing with some complicated data types. HDFFVI-7701 (SLU - 2011/10/19) - - - Fixed a bug in H5DSattach_scale, H5DSis_attached and H5DSdetach_scale - caused by using H5Tget_native_type function to determine the native - type for reading REFERENCE_LIST attribute. The bug was exposed - on Mac PPC. - (EIP - 2010/05/22 -1851) - - Fixed a bug in the H5DSdetach_scale function when 0 bytes - were allocated after the last reference to a dim. scale - was removed from the list of references in a VL element of the - DIMENSION_LIST attribute; modified the function to comply - with the Spec: DIMENSION_LIST attribute is deleted now when no - dimension scales left attached. - (EIP - 2010/05/14 -1822) - - Fixed a bug where the H5TB API would forget the order of fields when - added out of offset order. (NAF - 2009/10/27 - 1582) - - H5DSis_attached failed to account for different platform types. Added a - get native type call. (ADB - 2009/9/29 - 1562) - - Dimension scales: The scale index return value in H5DSiterate_scales was not always - incremented. (PVN - 2009/4/8 - 1538) Fortran High-Level APIs: ------ - - Lite: The h5ltget_attribute_string_f used to return the C NULL character in the - returned character buffer. The returned Fortran charactor buffer now does - not return the C NULL character. (MSB - 2012/3/23) - - Lite: The h5ltget_dataset_info_f function (gets information about a dataset) - was not correctly returning the dimension array. (PVN - 2009/3/23) - - Lite: the h5ltread_dataset_string_f and h5ltget_attribute_string_f functions - had memory problems with the g95 fortran compiler. (PVN � 5/13/2009) 1522 - - - - - - Documentation - ------------- - + Documentation + ------------- F90 APIs -------- - - Modified the h5open_f and h5close_f subroutines to not to call H5open - and H5close correspodningly. While the H5open call just adds overhead, - the H5close call called by an Fortran application shuts down the HDF5 - library making it unaccessible to the application. - HDFFV-915 (EIP & SB - 2011/10/13) - C++ APIs -------- - - The constructor PropList::PropList(id) was fixed to act properly - according to the nature of 'id'. When 'id' is a property class id, - a new property list will be created. When 'id' id a property list id, - a copy of the property list will be made. (BMR - 2010/5/9) - - The parameters 'size' and 'bufsize' in CommonFG::getLinkval and - CommonFG::getComment, respectively, now have default values for - user's convenience. (BMR - 2009/10/23) - - NULL pointer accessing was fixed, bugzilla 1061. (BMR - 2009/10/05) - - read/write methods of DataSet and Attribute classes were fixed - to handle string correctly. (BMR - 2009/07/26) - - Fixed bug that caused segfaults in Attribute::read. (BMR - 2008/04/20) - - Fixed bug in PropList::getClassName to use portable HDfree instead - of free. (BMR - 2008/04/20) - - Fixed a design bug which allowed an Attribute object to create/modify - attributes (bugzilla #1068). The API class hierarchy was revised - to address the problem. Classes AbstractDS and Attribute are moved - out of H5Object. Class Attribute now multiply inherits from - IdComponent and AbstractDs and class DataSet from H5Object and - AbstractDs. In addition, the data member IdComponent::id was - moved into subclasses: Attribute, DataSet, DataSpace, DataType, - H5File, Group, and PropList. (BMR - 2008/08/10) - - IdComponent::dereference was incorrect and replaced as described - in "New Features" section. - (BMR - 2008/08/10) Testing ------- - - tools/h5diff/testh5diff.sh is run in every "make check", even after it - has passed in the previous run. It should not run again if there is no - code changes. Fixed. (AKC - 2013/07/19 HDFFV-8392) - - In some Mac system, testlibinfo.sh failed with this error: - Check file ../src/.libs/libhdf5.7.dylib - strings: object: ../src/.libs/libhdf5.7.dylib malformed object \ - (unknown load command 15) - The strings command of Mac inspects library files and older - versions of strings may not know newer library format, resulting - in errors. Fixed by sending the library file as stdin to the strings - coommand to avoid this problem. (AKC - 2013/03/08 HDFFV-8305) - - - Fixed a typo in the ERROR macro in test/testhdf5.h. It segmentation - faulted when used before. (AKC - 2013/02/12 HDFFV-8267) Supported Platforms @@ -1195,17 +125,17 @@ Supported Platforms #1 SMP x86_64 GNU/Linux compilers for 64-bit applications; (koala) Version 4.1.2 20080704 (Red Hat 4.1.2-54) Version 4.8.2 - Intel(R) C, C++, Fortran Compilers for - applications running on Intel(R) 64; + Intel(R) C, C++, Fortran Compilers for + applications running on Intel(R) 64; Version 14.0.2 (Build 20140120) Linux 2.6.32-431.11.2.el6 GNU C (gcc), Fortran (gfortran), C++ (g++) #1 SMP x86_64 GNU/Linux compilers: (platypus) Version 4.4.7 20120313 Version 4.8.2 - PGI C, Fortran, C++ for 64-bit target on + PGI C, Fortran, C++ for 64-bit target on x86-64; - Version 13.7-0 + Version 13.7-0 Intel(R) C (icc), C++ (icpc), Fortran (icc) compilers: Version 14.0.2 (Build 20140120) @@ -1215,7 +145,7 @@ Supported Platforms (ostrich) GNU Fortran (GCC) 4.4.7 20120313 (Red Hat 4.4.7-4) IBM XL C/C++ V13.1 IBM XL Fortran V15.1 - + Linux 2.6.32-220.23.1.1chaos Intel C, C++, Fortran Compilers ch5.x86_64 GNU/Linux Version 12.1.5.339 (LLNL Aztec) @@ -1232,14 +162,14 @@ Supported Platforms Visual Studio 2010 w/ Intel Fortran 14 (cmake) Visual Studio 2012 w/ Intel Fortran 15 (cmake) Visual Studio 2013 w/ Intel Fortran 15 (cmake) - Cygwin(CYGWIN_NT-6.1 1.7.34(0.285/5/3) gcc(4.9.2) compiler and gfortran) + Cygwin(CYGWIN_NT-6.1 2.2.0(0.289/5/3) gcc(4.9.3) compiler and gfortran) (cmake and autotools) Windows 7 x64 Visual Studio 2008 (cmake) Visual Studio 2010 w/ Intel Fortran 14 (cmake) Visual Studio 2012 w/ Intel Fortran 15 (cmake) Visual Studio 2013 w/ Intel Fortran 15 (cmake) - + Windows 8.1 Visual Studio 2012 w/ Intel Fortran 15 (cmake) Visual Studio 2013 w/ Intel Fortran 15 (cmake) @@ -1252,23 +182,23 @@ Supported Platforms Mac OS X Mountain Lion 10.8.1 cc Apple clang version 4.0 from Xcode 4.5.1 (owl) c++ Apple clang version 4.0 from Xcode 4.5.1 - gcc i686-apple-darwin11-llvm-gcc-4.2 (GCC) 4.2.1 from Xcode 4.5.1 - g++ i686-apple-darwin11-llvm-g++-4.2 (GCC) 4.2.1 from Xcode 4.5.1 - gfortran GNU Fortran (GCC) 4.6.2 + gcc i686-apple-darwin11-llvm-gcc-4.2 (GCC) 4.2.1 from Xcode 4.5.1 + g++ i686-apple-darwin11-llvm-g++-4.2 (GCC) 4.2.1 from Xcode 4.5.1 + gfortran GNU Fortran (GCC) 4.6.2 Tested Configuration Features Summary ===================================== In the tables below - y = tested + y = tested n = not tested in this release C = Cluster W = Workstation x = not working in this release dna = does not apply ( ) = footnote appears below second table - = testing incomplete on this feature or platform + = testing incomplete on this feature or platform Platform C F90/ F90 C++ zlib SZIP parallel F2003 parallel @@ -1296,30 +226,30 @@ CentOS 6.4 Linux 2.6.32 x86_64 PGI n y/y n y y y Linux 2.6.32-431.11.2.el6.ppc64 n y/n n y y y -Platform Shared Shared Shared Thread- - C libs F90 libs C++ libs safe -Solaris2.11 32-bit y y y y -Solaris2.11 64-bit y y y y +Platform Shared Shared Shared Thread- + C libs F90 libs C++ libs safe +Solaris2.11 32-bit y y y y +Solaris2.11 64-bit y y y y Windows 7 y y y y Windows 7 x64 y y y y Windows 7 Cygwin n n n y Windows 7 x64 Cygwin n n n y Windows 8 y y y y Windows 8 x64 y y y y -Mac OS X Lion 10.7.3 32-bit y n y y -Mac OS X Lion 10.7.3 64-bit y n y y -Mac OS X Mountain Lion 10.8.1 64-bit y n y y +Mac OS X Lion 10.7.3 32-bit y n y y +Mac OS X Lion 10.7.3 64-bit y n y y +Mac OS X Mountain Lion 10.8.1 64-bit y n y y Mac OS X Mavericks 10.9.1 64-bit y n y y -AIX 6.1 32- and 64-bit y n n y -CentOS 5.9 Linux 2.6.18-308 i686 GNU y y y y -CentOS 5.9 Linux 2.6.18-308 i686 Intel y y y n -CentOS 5.9 Linux 2.6.18-308 i686 PGI y y y n -CentOS 5.9 Linux 2.6.18 x86_64 GNU y y y y -CentOS 5.9 Linux 2.6.18 x86_64 Intel y y y n +AIX 6.1 32- and 64-bit y n n y +CentOS 5.9 Linux 2.6.18-308 i686 GNU y y y y +CentOS 5.9 Linux 2.6.18-308 i686 Intel y y y n +CentOS 5.9 Linux 2.6.18-308 i686 PGI y y y n +CentOS 5.9 Linux 2.6.18 x86_64 GNU y y y y +CentOS 5.9 Linux 2.6.18 x86_64 Intel y y y n CentOS 6.4 Linux 2.6.32 x86_64 GNU y y y n CentOS 6.4 Linux 2.6.32 x86_64 Intel y y y n -CentOS 6.4 Linux 2.6.32 x86_64 PGI y y y n -Linux 2.6.32-431.11.2.el6.ppc64 y y y n +CentOS 6.4 Linux 2.6.32 x86_64 PGI y y y n +Linux 2.6.32-431.11.2.el6.ppc64 y y y n Compiler versions for each platform are listed in the preceding "Supported Platforms" table. @@ -1335,7 +265,7 @@ The following platforms are not supported but have been tested for this release. Linux 2.6.18-431.11.2.el6 MPICH mpich 3.1.2 compiled with #1 SMP x86_64 GNU/Linux gcc 4.9.1 and gfortran 4.9.1 - (platypus) g95 (GCC 4.0.3 (g95 0.94!) + (platypus) g95 (GCC 4.0.3 (g95 0.94!) FreeBSD 8.2-STABLE i386 gcc 4.2.1 [FreeBSD] 20070719 (loyalty) gcc 4.6.1 20110422 @@ -1386,7 +316,7 @@ The following platforms are not supported but have been tested for this release. gcc (Ubuntu/Linaro 4.9.1-0ubuntu1) 4.9.1 GNU Fortran (Ubuntu/Linaro 4.9.1-0ubuntu1) 4.9.1 (cmake and autotools) - + Cray Linux Environment (CLE) PrgEnv-pgi/4.0.46 hopper.nersc.gov pgcc 12.5-0 64-bit target on x86-64 Linux -tp shanghai pgf90 12.5-0 64-bit target on x86-64 Linux -tp shanghai @@ -1402,20 +332,20 @@ Known Problems * CLANG compiler with the options -fcatch-undefined-behavior and -ftrapv catches some undefined behavior in the alignment algorithm of the macro DETECT_I - in H5detect.c (Issue 8147). Since the algorithm is trying to detect the alignment - of integers, ideally the flag -fcatch-undefined-behavior shouldn't to be used for - H5detect.c. In the future, we can separate flags for H5detect.c from the rest of + in H5detect.c (Issue 8147). Since the algorithm is trying to detect the alignment + of integers, ideally the flag -fcatch-undefined-behavior shouldn't to be used for + H5detect.c. In the future, we can separate flags for H5detect.c from the rest of the library. (SLU - 2013/10/16) * The 5.9 C++ compiler on Sun failed to compile a C++ test ttypes.cpp. It complains with this message: "/home/hdf5/src/H5Vprivate.h", line 130: Error: __func__ is not defined. - + The reason is that __func__ is a predefined identifier in C99 standard. The HDF5 C library uses it in H5private.h. The test ttypes.cpp includes - H5private.h (H5Tpkg.h<-H5Fprivate.h<-H5Vprivate.h<-H5private.h). Sun's 5.9 + H5private.h (H5Tpkg.h<-H5Fprivate.h<-H5Vprivate.h<-H5private.h). Sun's 5.9 C++ compiler doesn't support __func__, thus fails to compile the C++ test. - But 5.11 C++ compiler does. To check whether your Sun C++ compiler knows this + But 5.11 C++ compiler does. To check whether your Sun C++ compiler knows this identifier, try to compile the following simple C++ program: #include @@ -1433,23 +363,23 @@ Known Problems * The data conversion test dt_arith.c has failures (segmentation fault) from "long double" to other datatypes during hard conversion when the library - is built with the default GCC 4.2.1 on Mac Lion system. It only happens - with optimization (-O3, -O2, and -O1). Some newer versions of GCC do not + is built with the default GCC 4.2.1 on Mac Lion system. It only happens + with optimization (-O3, -O2, and -O1). Some newer versions of GCC do not have this problem. Users should disable optimization or try newer version of GCC. (Issue 8017. SLU - 2012/6/12) * The data conversion test dt_arith.c fails in "long double" to integer conversion on Ubuntu 11.10 (3.0.0.13 kernal) with GCC 4.6.1 if the library is built with optimization -O3 or -O2. The older GCC (4.5) or newer kernal - (3.2.2 on Fedora) doesn't have the problem. Users should lower down the - optimization level (-O1 or -O0) by defining CFLAGS in the command line of + (3.2.2 on Fedora) doesn't have the problem. Users should lower down the + optimization level (-O1 or -O0) by defining CFLAGS in the command line of "configure" like: CFLAGS=-O1 ./configure - It will overwrite the library's default optimization level. (Issue 7829. + It will overwrite the library's default optimization level. (Issue 7829. SLU - 2012/2/7) - + * --with-mpe configure option does not work with Mpich2. AKC - 2011/03/10) * While working on the 1.8.6 release of HDF5, a bug was discovered that can @@ -1472,7 +402,7 @@ Known Problems cause H5Fcreate() with H5F_ACC_EXCL to fail even when the file is not existing. This is due to the MPI_File_open() call failing if the amode has the MPI_MODE_EXCL bit set. (See bug 1468 for details.) AKC - 2009/8/11 - + * Parallel tests failed with 16 processes with data inconsistency at testphdf5 / dataset_readAll. Parallel tests also failed with 32 and 64 processes with collective abort of all ranks at t_posix_compliant / allwrite_allread_blocks @@ -1481,19 +411,19 @@ Known Problems * For SNL, spirit/liberty/thunderbird: The serial tests pass but parallel tests failed with MPI-IO file locking message. AKC - 2007/6/25. * On Intel 64 Linux cluster (RH 4, Linux 2.6.9) with Intel 10.0 compilers use - -mp -O1 compilation flags to build the libraries. Higher level of optimization - causes failures in several HDF5 library tests. + -mp -O1 compilation flags to build the libraries. Higher level of optimization + causes failures in several HDF5 library tests. * For HPUX 11.23 many tools tests failed for 64-bit version when linked to the shared libraries (tested for 1.8.0-beta2) * For SNL, Red Storm: only paralle HDF5 is supported. The serial tests pass and the parallel tests also pass with lots of non-fatal error messages. -* on SUN 5.10 C++ test fails in the "Testing Shared Datatypes with Attributes" test +* on SUN 5.10 C++ test fails in the "Testing Shared Datatypes with Attributes" test * configuring with --enable-debug=all produces compiler errors on most platforms. Users who want to run HDF5 in debug mode should use --enable-debug rather than --enable-debug=all to enable debugging information on most modules. * On Mac OS 10.4, test/dt_arith.c has some errors in conversion from long - double to (unsigned) long long and from (unsigned)long long to long double. + double to (unsigned) long long and from (unsigned)long long to long double. * On Altix SGI with Intel 9.0 testmeta.c would not compile with -O3 optimization flag. * On VAX, Scaleoffset filter isn't supported. The filter cannot be applied to @@ -1506,19 +436,19 @@ Known Problems contribute no IO and the application asks to do IO with collective, we found that when using 4 processors, a simple collective write will be hung sometimes. This can be verified with t_mpi test under testpar. -* The dataset created or rewritten with the v1.6.3 library or after can't - be read with the v1.6.2 library or before when Fletcher32 EDC(filter) is - enabled. There was a bug in the calculating code of the Fletcher32 - checksum in the library before v1.6.3. The checksum value wasn't consistent - between big-endian and little-endian systems. This bug was fixed in - Release 1.6.3. However, after fixing the bug, the checksum value is no - longer the same as before on little-endian system. The library release +* The dataset created or rewritten with the v1.6.3 library or after can't + be read with the v1.6.2 library or before when Fletcher32 EDC(filter) is + enabled. There was a bug in the calculating code of the Fletcher32 + checksum in the library before v1.6.3. The checksum value wasn't consistent + between big-endian and little-endian systems. This bug was fixed in + Release 1.6.3. However, after fixing the bug, the checksum value is no + longer the same as before on little-endian system. The library release after 1.6.4 can still read the dataset created or rewritten with the library of v1.6.2 or before. SLU - 2005/6/30 * For the version 6(6.02 and 6.04) of Portland Group compiler on AMD Opteron processor, there's a bug in the compiler for optimization(-O2). The library - failed in several tests but all related to multi driver. The problem has - been reported to the vendor. + failed in several tests but all related to multi driver. The problem has + been reported to the vendor. * On IBM AIX systems, parallel HDF5 mode will fail some tests with error messages like "INFO: 0031-XXX ...". This is from the command poe. Set the environment variable MP_INFOLEVEL to 0 to minimize the messages @@ -1532,7 +462,7 @@ Known Problems to provide a mean to run poe without the debug socket. * The C++ library's tests fails when compiling with PGI C++ compiler. The - workaround until the problem is correctly handled is to use the + workaround until the problem is correctly handled is to use the flag "--instantiate=local" prior to the configure and build steps, as: setenv CXX "pgCC --instantiate=local" for pgCC 5.02 and higher @@ -1546,9 +476,9 @@ Known Problems * The --enable-static-exec configure flag will only statically link libraries if the static version of that library is present. If only the shared version of a library exists (i.e., most system libraries on Solaris, AIX, and Mac, - for example, only have shared versions), the flag should still result in a - successful compilation, but note that the installed executables will not be - fully static. Thus, the only guarantee on these systems is that the + for example, only have shared versions), the flag should still result in a + successful compilation, but note that the installed executables will not be + fully static. Thus, the only guarantee on these systems is that the executable is statically linked with just the HDF5 library. * With the gcc 2.95.2 compiler, HDF 5 uses the `-ansi' flag during @@ -1556,7 +486,7 @@ Known Problems able to handle the `long long' datatype with the warning: warning: ANSI C does not support `long long' - + This warning is innocuous and can be safely ignored. * Certain platforms give false negatives when testing h5ls: @@ -1574,35 +504,35 @@ Known Problems * On some platforms that use Intel and Absoft compilers to build HDF5 fortran library, compilation may fail for fortranlib_test.f90, fflush1.f90 and fflush2.f90 - complaining about exit subroutine. Comment out the line + complaining about exit subroutine. Comment out the line IF (total_error .ne. 0) CALL exit (total_error) * Information about building with PGI and Intel compilers is available in INSTALL file sections 5.7 and 5.8 * On at least one system, (SDSC DataStar), the scheduler (in this case - LoadLeveler) sends job status updates to standard error when you run + LoadLeveler) sends job status updates to standard error when you run any executable that was compiled with the parallel compilers. - This causes problems when running "make check" on parallel builds, as + This causes problems when running "make check" on parallel builds, as many of the tool tests function by saving the output from test runs, - and comparing it to an exemplar. + and comparing it to an exemplar. The best solution is to reconfigure the target system so it no longer inserts the extra text. However, this may not be practical. - In such cases, one solution is to "setenv HDF5_Make_Ignore yes" prior to - the configure and build. This will cause "make check" to continue after + In such cases, one solution is to "setenv HDF5_Make_Ignore yes" prior to + the configure and build. This will cause "make check" to continue after detecting errors in the tool tests. However, in the case of SDSC DataStar, it also leaves you with some 150 "failed" tests to examine by hand. A second solution is to write a script to run serial tests and filter out the text added by the scheduler. A sample script used on SDSC - DataStar is given below, but you will probably have to customize it - for your installation. + DataStar is given below, but you will probably have to customize it + for your installation. - Observe that the basic idea is to insert the script as the first item - on the command line which executes the the test. The script then + Observe that the basic idea is to insert the script as the first item + on the command line which executes the the test. The script then executes the test and filters out the offending text before passing it on. @@ -1624,11 +554,11 @@ Known Problems exit $RETURN_VALUE You get the HDF make files and test scipts to execute your filter script - by setting the environment variable "RUNSERIAL" to the full path of the - script prior to running configure for parallel builds. Remember to + by setting the environment variable "RUNSERIAL" to the full path of the + script prior to running configure for parallel builds. Remember to "unsetenv RUNSERIAL" before running configure for a serial build. - Note that the RUNSERIAL environment variable exists so that we can + Note that the RUNSERIAL environment variable exists so that we can can prefix serial runs as necessary on the target system. On DataStar, no prefix is necessary. However on an MPICH system, the prefix might have to be set to something like "/usr/local/mpi/bin/mpirun -np 1" to diff --git a/release_docs/USING_CMake_Examples.txt b/release_docs/USING_CMake_Examples.txt index 0956ff1..d52a719 100644 --- a/release_docs/USING_CMake_Examples.txt +++ b/release_docs/USING_CMake_Examples.txt @@ -2,39 +2,34 @@ * Build and Test HDF5 Examples with CMake * ************************************************************************ -Notes: This short instruction is written for users who want to quickly +Notes: This short instruction is written for users who want to quickly test the installation of HDF5 by using the CMake tools to build and test the HDF5 Examples. The following instructions will show the default usage and then present common changes for non-default installations. For more information, see the USING_HDF5_CMake.txt file. - - More information about using CMake can be found at the KitWare + + More information about using CMake can be found at the KitWare site, www.cmake.org. - + CMake uses the command line and these instructions use the script method of the ctest command. ======================================================================== -I. Preconditions +I. Preconditions ======================================================================== 1. We suggest you obtain the latest CMake for windows from the Kitware - web site. The HDF5 1.8.x product requires a minimum CMake version - of 3.1.0. - - 2. You have installed the HDF5 library built with CMake, by executing - the HDF Install Utility (the *.exe file in the binary package for - Windows or the *.sh on Linux). If you are using a Windows platform, - you can obtain a pre-built Windows binary from The HDF Group's website - at www.hdfgroup.org. See Section "III. Common changes to the + web site. The HDF5 1.8.x product requires a minimum CMake version + of 3.1.0. + + 2. You have installed the HDF5 library built with CMake, by executing + the HDF Install Utility (the *.msi file in the binary package for + Windows or the *.sh on Linux). If you are using a Windows platform, + you can obtain a pre-built Windows binary from The HDF Group's website + at www.hdfgroup.org. See Section "III. Common changes to the HDF518_Examples.cmake file", for the line to change the location. - - 3. On Windows, you have installed the 7Zip package. See Section "III. - Common changes to the HDF518_Examples.cmake file", for the line to - change the command. - ======================================================================== @@ -42,16 +37,16 @@ II. Building HDF5 Examples with CMake ======================================================================== Files in the HDF5 install directory: - HDF5Examples-0.1.1-Source.zip (or HDF5Examples-0.1.1-Source.tar.gz) + HDF5Examples-0.1.1-Source folder HDF518_Examples.cmake - + Default installation process: Create a directory to run the examples, i.e. \test_hdf5. - Copy HDF5Examples-0.1.1-Source.zip(.tar.gz) to this directory, uncompress. + Copy HDF5Examples-0.1.1-Source folder to this directory. Copy HDF518_Examples.cmake to this directory. - Edit line 8 of the HDF518_Examples.cmake file and change the INSTALLDIR + Edit line 8 of the HDF518_Examples.cmake file and change the INSTALLDIR to the HDF5 install location. - + Execute from this directory: ctest -S HDF518_Examples.cmake,HDF5Examples-0.1.1-Source -C Release -O test.log @@ -60,7 +55,7 @@ The script will use the examples folder HDF5Examples-0.1.1-Source, It will then configure, build, and execute the examples. All the log files will be found under the build\Testing\Temporary directory, check these for errors. - + The amount of script information can be increased by adding -V to the ctest command. Even more information can be shown by adding -VV instead of -V. @@ -79,5 +74,3 @@ Line 16: comment to NOT build and test Fortran examples with F2003 option. Line 17: uncomment to use a compressed source file. -Line 71: change the CTEST_7Z_COMMAND to a different unzip program. - diff --git a/release_docs/USING_HDF5_CMake.txt b/release_docs/USING_HDF5_CMake.txt index 514cced..5fdb76c 100644 --- a/release_docs/USING_HDF5_CMake.txt +++ b/release_docs/USING_HDF5_CMake.txt @@ -2,60 +2,60 @@ * Build and Install HDF5 Applications with CMake * ************************************************************************ -Notes: This short instruction is written for users who want to quickly - build HDF5 applications using the CMake tools. Users can adapt - these instructions for their own applications. For more information, +Notes: This short instruction is written for users who want to quickly + build HDF5 applications using the CMake tools. Users can adapt + these instructions for their own applications. For more information, see the "Minimum C Project Files for CMake" section. - - More information about using CMake can be found at the KitWare + + More information about using CMake can be found at the KitWare site, www.cmake.org. - - CMake uses the command line; however, the visual CMake tool is + + CMake uses the command line; however, the visual CMake tool is available for the configuration step. The steps are similar for all of the operating systems supported by CMake. - + NOTES: - 1. Using CMake for building and using HDF5 is under active - development. While we have attempted to provide error-free - files, please understand that development with CMake has not - been extensively tested outside of HDF. The CMake specific + 1. Using CMake for building and using HDF5 is under active + development. While we have attempted to provide error-free + files, please understand that development with CMake has not + been extensively tested outside of HDF. The CMake specific files may change before the next release. - - 2. CMake for HDF5 development should be usable on any system - where CMake is supported. Please send us any comments on how - CMake support can be improved on any system. - - 3. See the appendix at the bottom of this file for an example - of using a ctest script for building and testing. See + + 2. CMake for HDF5 development should be usable on any system + where CMake is supported. Please send us any comments on how + CMake support can be improved on any system. + + 3. See the appendix at the bottom of this file for an example + of using a ctest script for building and testing. See INSTALL_CMake.txt for more information. ======================================================================== -I. Preconditions +I. Preconditions ======================================================================== 1. We suggest you obtain the latest CMake for windows from the Kitware - web site. The HDF5 1.8.x product requires a minimum CMake version - of 3.1.0. - - 2. You have installed the HDF5 library built with CMake, by executing - the HDF Install Utility (the *.exe file in the binary package for - Windows). If you are using a Windows platform, you can obtain a - pre-built Windows binary from The HDF Group's website at + web site. The HDF5 1.8.x product requires a minimum CMake version + of 3.1.0. + + 2. You have installed the HDF5 library built with CMake, by executing + the HDF Install Utility (the *.msi file in the binary package for + Windows). If you are using a Windows platform, you can obtain a + pre-built Windows binary from The HDF Group's website at www.hdfgroup.org. - 3. Set the environment variable HDF5_DIR to the installed location of - the config files for HDF5. On Windows: - HDF5_DIR=C:/Program Files/HDF_Group/HDF5/1.8.x/cmake/hdf5 - + 3. Set the environment variable HDF5_DIR to the installed location of + the config files for HDF5. On Windows: + HDF5_DIR=C:/Program Files/HDF_Group/HDF5/1.8.x/cmake + (Note there are no quote characters used on Windows and all platforms use forward slashes) 4. Created separate source and build directories. (CMake commands are executed in the build directory) - 5. Created a CMakeLists.txt file(s) for your source. See Section III + 5. Created a CMakeLists.txt file(s) for your source. See Section III below. @@ -65,6 +65,7 @@ II. Building HDF5 Applications with CMake ======================================================================== Go through these steps to build HDF5 applications with CMake. + (The application must support building with CMake.) 1. Run CMake 2. Configure the cache settings @@ -79,22 +80,22 @@ These steps are described in more detail below. The visual CMake executable is named "cmake-gui.exe" on Windows and should be available in your Start menu. For Linux, UNIX, and Mac users the - executable is named "cmake-gui" and can be found where CMake was - installed. - - Specify the source and build directories. Make the build and source - directories different. For example on Windows, if the source is at - c:\MyHDFstuff\hdf5, then use c:\MyHDFstuff\hdf5\build or - c:\MyHDFstuff\build\hdf5 for the build directory. - + executable is named "cmake-gui" and can be found where CMake was + installed. + + Specify the source and build directories. Make the build and source + directories different. For example on Windows, if the source is at + c:\MyHDFstuff\hdf5, then use c:\MyHDFstuff\hdf5\build or + c:\MyHDFstuff\build\hdf5 for the build directory. + PREFERRED: - Users can perform the configuration step without using the visual - cmake-gui program. The following is an example command line + Users can perform the configuration step without using the visual + cmake-gui program. The following is an example command line configuration step executed within the build directory: - + cmake -G "" [-D] - - Where is + + Where is * MinGW Makefiles * NMake Makefiles * Unix Makefiles @@ -111,63 +112,63 @@ These steps are described in more detail below. 2. Configure the cache settings - 2.1 Visual CMake users, click the Configure button. If this is the first time you are - running cmake-gui in this directory, you will be prompted for the - generator you wish to use (for example on Windows, Visual Studio 10). - CMake will read in the CMakeLists.txt files from the source directory and - display options for the HDF5 project. After the first configure you + 2.1 Visual CMake users, click the Configure button. If this is the first time you are + running cmake-gui in this directory, you will be prompted for the + generator you wish to use (for example on Windows, Visual Studio 10). + CMake will read in the CMakeLists.txt files from the source directory and + display options for the HDF5 project. After the first configure you can adjust the cache settings and/or specify locations of other programs. - + Any conflicts or new values will be highlighted by the configure - process in red. Once you are happy with all the settings and there are no - more values in red, click the Generate button to produce the appropriate - build files. - - On Windows, if you are using a Visual Studio generator, the solution and + process in red. Once you are happy with all the settings and there are no + more values in red, click the Generate button to produce the appropriate + build files. + + On Windows, if you are using a Visual Studio generator, the solution and project files will be created in the build folder. - + On linux, if you are using the Unix Makefiles generator, the Makefiles will be created in the build folder. 2.2 Alternative command line example on Windows in c:\MyHDFstuff\hdf5\build directory: - + cmake -G "Visual Studio 11" -DBUILD_TESTING:BOOL=ON .. 3. Build HDF5 Applications - - On Windows, you can build HDF5 applications using either the Visual Studio Environment + + On Windows, you can build HDF5 applications using either the Visual Studio Environment or the command line. The command line is normally used on linux, Unix, and Mac. To build from the command line, navigate to your build directory and execute the following: - - cmake --build . --config {Debug | Release} - + + cmake --build . --config {Debug | Release} + NOTE: "--config {Debug | Release}" may be optional on your platform. We recommend choosing either Debug or Release on Windows. If you are - using the pre-built binaries from HDF, use Release. - - 3.1 If you wish to use the Visual Studio environment, open the solution - file in your build directory. Be sure to select either Debug or + using the pre-built binaries from HDF, use Release. + + 3.1 If you wish to use the Visual Studio environment, open the solution + file in your build directory. Be sure to select either Debug or Release and build the solution. - + 4. Test HDF5 Applications To test the build, navigate to your build directory and execute: - + ctest . -C {Debug | Release} - + NOTE: "-C {Debug | Release}" may be optional on your platform. We recommend choosing either Debug or Release to match the build - step on Windows. + step on Windows. - 5. The files that support building with CMake are all of the files in the - config/cmake folder, the CMakeLists.txt files in each source folder, and - CTestConfig.cmake. CTestConfig.cmake is specific to the internal testing - performed by The HDF Group. It should be altered for the user's + 5. The files that support building with CMake are all of the files in the + config/cmake folder, the CMakeLists.txt files in each source folder, and + CTestConfig.cmake. CTestConfig.cmake is specific to the internal testing + performed by The HDF Group. It should be altered for the user's installation and needs. The cacheinit.cmake file settings are used by - The HDF Group for daily testing. It should be altered/ignored for the user's - installation and needs. + The HDF Group for daily testing. It should be altered/ignored for the user's + installation and needs. @@ -175,17 +176,17 @@ These steps are described in more detail below. III. Minimum C Project Files for CMake ======================================================================== -Create a CMakeLists.txt file at the source root. Include the +Create a CMakeLists.txt file at the source root. Include the following text in the file: ########################################################## cmake_minimum_required (VERSION 3.1.0) -PROJECT (HDF5MyApp C CXX) +project (HDF5MyApp C CXX) -FIND_PACKAGE (HDF5 NAMES hdf5) -# FIND_PACKAGE (HDF5) # Find non-cmake built HDF5 +find_package (HDF5 NAMES hdf5 COMPONENTS C static) +# find_package (HDF5) # Find non-cmake built HDF5 INCLUDE_DIRECTORIES (${HDF5_INCLUDE_DIR}) -set (LINK_LIBS ${LINK_LIBS} ${HDF5_LIBRARIES}) +set (LINK_LIBS ${LINK_LIBS} ${HDF5_C_STATIC_LIBRARY}) set (example hdf_example) @@ -193,7 +194,7 @@ add_executable (${example} ${PROJECT_SOURCE_DIR}/${example}.c) TARGET_C_PROPERTIES (${example} " " " ") target_link_libraries (${example} ${LINK_LIBS}) -ENABLE_TESTING () +enable_testing () include (CTest) add_test (NAME test_example COMMAND ${example}) @@ -216,8 +217,8 @@ NOTE: these files are available at the HDF web site: http://www.hdfgroup.org/HDF5/release/cmakebuild.html CTestScript.cmake - - HDF518ExamplesWindowsbinaryCMake.cmake + + HDF518_Examples.cmake @@ -226,10 +227,10 @@ ctest ======================================================================== ############################################################################ -# Product specific script, HDF518Example.cmake, that uses the +# Product specific script, HDF518_Examples.cmake, that uses the # CTestScript.cmake file (see Appendix in the CMake.txt). Usage: -# "ctest -S HDF518Example.cmake,hdf518Examples -C Release -O hdf518EX.log" -# where hdf518Examples is the source folder relative to the location of these scripts +# "ctest -S HDF518_Examples.cmake,HDF5Examples-0.1.1-Source -C Release -O test.log" +# where HDF5Examples-0.1.1-Source is the source folder relative to the location of these scripts ############################################################################ cmake_minimum_required(VERSION 3.1.0 FATAL_ERROR) @@ -259,7 +260,7 @@ set(REPOSITORY_URL "http://svn.${hdfgroup_url}/hdf5-examples/trunk/1_8") set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DCMAKE_INSTALL_PREFIX:PATH=/usr/local/hdf5Examples-1.8") # location of the installed hdf5 (cmake configuration folder) -set(ENV{HDF5_DIR} "/usr/share/cmake/hdf5") +set(ENV{HDF5_DIR} "/usr/share/cmake") include(${CTEST_SCRIPT_DIRECTORY}/CTestScript.cmake) -- cgit v0.12 From 1252bc4e669306b0e029e26b7283d1685fa2ccbc Mon Sep 17 00:00:00 2001 From: Dana Robinson Date: Thu, 27 Aug 2015 17:24:45 -0500 Subject: [svn-r27601] Removed the H5TSprivate.h include from H5.c. It's not needed and causes problems on Windows. Tested on: jam, with and without --enable-threadsafe --- src/H5.c | 1 - 1 file changed, 1 deletion(-) diff --git a/src/H5.c b/src/H5.c index 8563545..2e05819 100644 --- a/src/H5.c +++ b/src/H5.c @@ -31,7 +31,6 @@ #include "H5Pprivate.h" /* Property lists */ #include "H5SLprivate.h" /* Skip lists */ #include "H5Tprivate.h" /* Datatypes */ -#include "H5TSprivate.h" /* Thread safety */ /****************/ /* Local Macros */ -- cgit v0.12 From 1847391fc51728811407f3e1586213758c1d0e89 Mon Sep 17 00:00:00 2001 From: Neil Fortner Date: Fri, 28 Aug 2015 14:43:03 -0500 Subject: [svn-r27605] Fix potential memory error when using a dataspace that was created with H5Screate and had its extent set by H5Sextent_copy. Tested: jam, ostrich (h5committest) --- src/H5S.c | 2 +- test/th5s.c | 43 +++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 44 insertions(+), 1 deletion(-) diff --git a/src/H5S.c b/src/H5S.c index 9b37797..efb9d34 100644 --- a/src/H5S.c +++ b/src/H5S.c @@ -190,7 +190,7 @@ H5S_create(H5S_class_t type) FUNC_ENTER_NOAPI(NULL) /* Create a new dataspace */ - if(NULL == (new_ds = H5FL_MALLOC(H5S_t))) + if(NULL == (new_ds = H5FL_CALLOC(H5S_t))) HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, NULL, "memory allocation failed") /* Initialize default dataspace state */ diff --git a/test/th5s.c b/test/th5s.c index 1560ef4..9d08abe 100644 --- a/test/th5s.c +++ b/test/th5s.c @@ -2326,6 +2326,48 @@ test_h5s_extent_copy(void) /**************************************************************** ** +** test_h5s_bug1(): Test Creating dataspace with H5Screate then +* setting extent with H5Sextent_copy. +** +****************************************************************/ +static void +test_h5s_bug1(void) +{ + hid_t space1; /* Dataspace to copy extent to */ + hid_t space2; /* Scalar dataspace */ + hsize_t dims[2] = {10, 10}; /* Dimensions */ + hsize_t start[2] = {0, 0}; /* Hyperslab start */ + htri_t select_valid; /* Whether the dataspace selection is valid */ + herr_t ret; /* Generic error return */ + + /* Create dataspaces */ + space1 = H5Screate(H5S_SIMPLE); + CHECK(space1, FAIL, "H5Screate"); + space2 = H5Screate_simple(2, dims, NULL); + CHECK(space2, FAIL, "H5Screate"); + + /* Copy extent to space1 */ + ret = H5Sextent_copy(space1, space2); + CHECK(ret, FAIL, "H5Sextent_copy"); + + /* Select hyperslab in space1 containing entire extent */ + ret = H5Sselect_hyperslab(space1, H5S_SELECT_SET, start, NULL, dims, NULL); + CHECK(ret, FAIL, "H5Sselect_hyperslab"); + + /* Check that space1's selection is valid */ + select_valid = H5Sselect_valid(space1); + CHECK(select_valid, FAIL, "H5Sselect_valid"); + VERIFY(select_valid, TRUE, "H5Sselect_valid result"); + + /* Close dataspaces */ + ret = H5Sclose(space1); + CHECK(ret, FAIL, "H5Sclose"); + ret = H5Sclose(space2); + CHECK(ret, FAIL, "H5Sclose"); +} /* test_h5s_bug1() */ + +/**************************************************************** +** ** test_h5s(): Main H5S (dataspace) testing routine. ** ****************************************************************/ @@ -2350,6 +2392,7 @@ test_h5s(void) test_h5s_extent_equal(); /* Test extent comparison code */ test_h5s_extent_copy(); /* Test extent copy code */ + test_h5s_bug1(); /* Test bug in offset initialization */ } /* test_h5s() */ -- cgit v0.12