[hdf4] 03/06: Imported Upstream version 4.2.11

Johan Van de Wauw johanvdw-guest at moszumanska.debian.org
Sat Feb 14 13:10:48 UTC 2015


This is an automated email from the git hooks/post-receive script.

johanvdw-guest pushed a commit to branch experimental
in repository hdf4.

commit 604f0099716e1c60146071d395e1c69879b87a85
Author: Johan Van de Wauw <johan.vandewauw at gmail.com>
Date:   Sat Feb 14 13:42:53 2015 +0100

    Imported Upstream version 4.2.11
---
 CMakeFilters.cmake                                 |  266 ++---
 CMakeInstallation.cmake                            |  462 +++++----
 CMakeLists.txt                                     |  702 ++++++-------
 COPYING                                            |    2 +-
 CTestConfig.cmake                                  |   34 +-
 MANIFEST                                           |   52 +-
 Makefile.in                                        |  235 +++--
 README.txt                                         |    2 +-
 UserMacros.cmake                                   |    8 +-
 aclocal.m4                                         |  411 ++++++--
 bin/cmakehdf4                                      |   25 +-
 bin/reconfigure                                    |   12 +-
 bin/release                                        |  149 ++-
 bin/test-driver                                    |  139 +++
 config/cmake/CTestCustom.cmake                     |    6 +-
 config/cmake/CheckTypeSize.cmake                   |   48 -
 config/cmake/ConfigureChecks.cmake                 |  369 +------
 config/cmake/FindHDF4.cmake.in                     |   18 +-
 config/cmake/FindMPI.cmake                         |  628 ------------
 config/cmake/FindSZIP.cmake                        |  179 ----
 config/cmake/HDF4Macros.cmake                      |   37 +-
 config/cmake/HDF4UseFortran.cmake                  |   72 +-
 config/cmake/HDF4_Examples.cmake.in                |   48 +-
 config/cmake/HDFLibMacros.cmake                    |  350 -------
 config/cmake/HDFMacros.cmake                       |  187 ----
 config/cmake/NSIS.InstallOptions.ini.in            |    4 +-
 config/cmake/PkgInfo.in                            |    1 +
 config/cmake/README.txt.cmake.in                   |   60 ++
 config/cmake/UserMacros/Windows_MT.cmake           |   34 +-
 config/cmake/cacheinit.cmake                       |   64 +-
 config/cmake/h4config.h.in                         |    4 +-
 config/cmake/hdf.gif                               |  Bin 1016 -> 0 bytes
 config/cmake/hdf4-config-version.cmake.in          |   22 +-
 config/cmake/hdf4-config.cmake.build.in            |   70 +-
 config/cmake/hdf4-config.cmake.install.in          |   86 +-
 config/cmake/libhdf4.settings.cmake.in             |    2 +-
 config/cmake/mccacheinit.cmake                     |   67 +-
 config/cmake/runTest.cmake                         |  182 ----
 .../{cmake => cmake_ext_mod}/CPack.Info.plist.in   |    0
 config/cmake_ext_mod/CTestCustom.cmake             |   16 +
 config/cmake_ext_mod/CheckTypeSize.cmake           |   50 +
 config/cmake_ext_mod/ConfigureChecks.cmake         |  751 ++++++++++++++
 config/cmake_ext_mod/FindSZIP.cmake                |  179 ++++
 config/cmake_ext_mod/GetTimeOfDayTest.cpp          |   15 +
 config/cmake_ext_mod/HDFCXXTests.cpp               |   56 ++
 config/cmake_ext_mod/HDFLibMacros.cmake            |  249 +++++
 config/cmake_ext_mod/HDFMacros.cmake               |  288 ++++++
 config/{cmake => cmake_ext_mod}/HDFTests.c         |   34 +-
 config/cmake_ext_mod/HDFUseFortran.cmake           |  167 ++++
 .../NSIS.InstallOptions.ini.in                     |    2 +-
 config/{cmake => cmake_ext_mod}/NSIS.template.in   |    0
 config/cmake_ext_mod/grepTest.cmake                |   64 ++
 config/cmake_ext_mod/hdf.bmp                       |  Bin 0 -> 1254 bytes
 config/cmake_ext_mod/hdf.icns                      |  Bin 0 -> 326012 bytes
 config/cmake_ext_mod/hdf.ico                       |  Bin 0 -> 23558 bytes
 config/cmake_ext_mod/prunTest.cmake                |  145 +++
 config/cmake_ext_mod/runTest.cmake                 |  207 ++++
 config/cmake_ext_mod/version.plist.in              |   17 +
 configure                                          |  213 +++-
 configure.ac                                       |   29 +-
 hdf/CMakeLists.txt                                 |   12 +-
 hdf/Makefile.in                                    |  208 ++--
 hdf/examples/CMakeLists.txt                        |   16 +-
 hdf/examples/CMakeTests.cmake                      |   46 +-
 hdf/examples/Makefile.in                           |  662 ++++++++++++-
 hdf/examples/README                                |   11 +-
 hdf/fortran/CMakeLists.txt                         |   60 +-
 hdf/fortran/CMakeTests.cmake                       |   48 +-
 hdf/fortran/Makefile.in                            |  208 ++--
 hdf/fortran/examples/CMakeLists.txt                |   44 +-
 hdf/fortran/examples/CMakeTests.cmake              |   52 +-
 hdf/fortran/examples/GR_get_attribute.f            |    1 +
 hdf/fortran/examples/GR_image_info.f               |    1 +
 hdf/fortran/examples/Makefile.in                   |  627 +++++++++++-
 hdf/fortran/examples/VD_get_vdata_info.f           |   25 +-
 hdf/fortran/examples/VG_set_get_vgroup_attr.f      |    1 +
 hdf/src/CMakeLists.txt                             |   24 +-
 hdf/src/H4api_adpt.h                               |   59 +-
 hdf/src/Makefile.in                                |  241 +++--
 hdf/src/atom.c                                     |   14 +-
 hdf/src/bitvect.c                                  |   11 +-
 hdf/src/hfile.h                                    |    6 +-
 hdf/src/mfgr.c                                     |   18 +-
 hdf/src/vgint.h                                    |    5 +-
 hdf/test/CMakeLists.txt                            |   18 +-
 hdf/test/CMakeTests.cmake                          |   90 +-
 hdf/test/Makefile.in                               |  626 ++++++++++--
 hdf/test/tvsetf.f                                  |   14 +-
 hdf/util/CMakeLists.txt                            |   70 +-
 hdf/util/CMakeTests.cmake                          |  318 +++---
 hdf/util/Makefile.in                               |  711 +++++++++++---
 hdf/util/fp2hdf.c                                  |   66 +-
 hdf/util/h4cc.in                                   |   17 +-
 hdf/util/h4fc.in                                   |    0
 hdf/util/h4redeploy.in                             |    0
 hdf/util/hdf2gif.c                                 |    4 +-
 hdf/util/hdfrseq.c                                 |  706 --------------
 hdf/util/testutil.sh.in                            |    0
 hdf/util/vcompat.c                                 |   43 -
 hdf/util/writehdf.c                                |   24 +-
 man/Makefile.in                                    |  120 ++-
 man/hdf.1                                          |    6 +-
 mfhdf/CMakeLists.txt                               |   36 +-
 mfhdf/Makefile.in                                  |  209 ++--
 mfhdf/dumper/CMakeLists.txt                        |   36 +-
 mfhdf/dumper/CMakeTests.cmake                      |   84 +-
 mfhdf/dumper/Makefile.am                           |    4 +-
 mfhdf/dumper/Makefile.in                           |  592 +++++++++--
 mfhdf/dumper/hdp.c                                 |   37 +-
 mfhdf/dumper/hdp_util.c                            |   12 +-
 mfhdf/dumper/hdp_vg.c                              |   32 +-
 mfhdf/dumper/testhdp.sh.in                         |    2 +-
 mfhdf/examples/CMakeLists.txt                      |   22 +-
 mfhdf/examples/CMakeTests.cmake                    |   24 +-
 mfhdf/examples/Makefile.in                         |  571 ++++++++++-
 mfhdf/examples/testexamples.sh.in                  |    0
 mfhdf/fortran/CMakeLists.txt                       |  112 ++-
 mfhdf/fortran/CMakeTests.cmake                     |   90 +-
 mfhdf/fortran/Makefile.am                          |    4 +-
 mfhdf/fortran/Makefile.in                          |  600 +++++++++---
 mfhdf/fortran/examples/CMakeLists.txt              |   42 +-
 mfhdf/fortran/examples/CMakeTests.cmake            |   30 +-
 mfhdf/fortran/examples/Makefile.in                 |  571 ++++++++++-
 mfhdf/fortran/testfortran.sh.in                    |    0
 mfhdf/hdfimport/CMakeLists.txt                     |   42 +-
 mfhdf/hdfimport/CMakeTests.cmake                   |  176 ++--
 mfhdf/hdfimport/Makefile.am                        |    4 +-
 mfhdf/hdfimport/Makefile.in                        |  604 ++++++++++--
 mfhdf/hdfimport/hdfimport.c                        |  142 ++-
 mfhdf/hdfimport/testutil.sh.in                     |    0
 mfhdf/hdiff/CMakeLists.txt                         |   30 +-
 mfhdf/hdiff/CMakeTests.cmake                       |   98 +-
 mfhdf/hdiff/Makefile.am                            |    4 +-
 mfhdf/hdiff/Makefile.in                            |  584 +++++++++--
 mfhdf/hdiff/hdiff.h                                |    4 +-
 mfhdf/hdiff/testhdiff.sh.in                        |    0
 mfhdf/hrepack/CMakeLists.txt                       |   47 +-
 mfhdf/hrepack/CMakeTests.cmake                     |  338 +++++--
 mfhdf/hrepack/Makefile.am                          |   26 +-
 mfhdf/hrepack/Makefile.in                          |  821 ++++++++++------
 mfhdf/hrepack/hrepack.c                            |    1 +
 mfhdf/hrepack/hrepack.h                            |   17 +-
 mfhdf/hrepack/hrepack.sh.in                        |  357 +++++++
 mfhdf/hrepack/hrepack_all.sh.in                    |    0
 mfhdf/hrepack/hrepack_check_help.txt               |    3 +
 mfhdf/hrepack/hrepack_help.txt                     |   55 ++
 mfhdf/hrepack/hrepack_list.c                       |   57 +-
 mfhdf/hrepack/hrepacktst.c                         |  392 +-------
 mfhdf/libsrc/CMakeLists.txt                        |   72 +-
 mfhdf/libsrc/Makefile.am                           |    4 +-
 mfhdf/libsrc/Makefile.in                           |  265 +++--
 mfhdf/libsrc/local_nc.h                            |    4 +-
 mfhdf/libsrc/xdrposix.c                            |    8 +-
 mfhdf/ncdump/CMakeLists.txt                        |   36 +-
 mfhdf/ncdump/CMakeTests.cmake                      |   49 +-
 mfhdf/ncdump/Makefile.am                           |    4 +-
 mfhdf/ncdump/Makefile.in                           |  580 +++++++++--
 mfhdf/ncdump/ncdump.c                              |   18 +-
 mfhdf/ncdump/ncdump.h                              |    4 +-
 mfhdf/ncdump/testncdump.sh.in                      |    0
 mfhdf/ncdump/vardata.c                             |   38 +-
 mfhdf/ncgen/CMakeLists.txt                         |   40 +-
 mfhdf/ncgen/CMakeTests.cmake                       |   65 +-
 mfhdf/ncgen/Makefile.am                            |    4 +-
 mfhdf/ncgen/Makefile.in                            |  587 ++++++++---
 mfhdf/ncgen/main.c                                 |   15 +-
 mfhdf/ncgen/testncgen.sh.in                        |    0
 mfhdf/nctest/CMakeLists.txt                        |   43 +-
 mfhdf/nctest/CMakeTests.cmake                      |    6 +-
 mfhdf/nctest/Makefile.am                           |    4 +-
 mfhdf/nctest/Makefile.in                           |  578 +++++++++--
 mfhdf/nctest/driver.c                              |    3 +-
 mfhdf/nctest/val.c                                 |    8 +-
 mfhdf/test/CMakeLists.txt                          |   84 +-
 mfhdf/test/CMakeTests.cmake                        |   56 +-
 mfhdf/test/Makefile.am                             |    4 +-
 mfhdf/test/Makefile.in                             |  598 ++++++++++--
 mfhdf/test/tdatainfo.c                             |    2 +-
 mfhdf/test/testmfhdf.sh.in                         |    0
 mfhdf/xdr/CMakeLists.txt                           |   30 +-
 mfhdf/xdr/Makefile.am                              |    2 +-
 mfhdf/xdr/Makefile.in                              |  550 +++++++++--
 mfhdf/xdr/xdrstdio.c                               |    4 +-
 release_notes/HISTORY.txt                          |  302 ++++++
 release_notes/INSTALL                              |    2 +-
 release_notes/INSTALL_CMake.txt                    | 1027 ++++++++------------
 release_notes/INSTALL_CYGWIN.txt                   |   17 +-
 release_notes/RELEASE.txt                          |  314 +++---
 release_notes/USING_CMake_Examples.txt             |   91 +-
 release_notes/USING_HDF4_CMake.txt                 |  164 ++--
 release_notes/USING_HDF4_VS.txt                    |   30 +-
 191 files changed, 16626 insertions(+), 8750 deletions(-)

diff --git a/CMakeFilters.cmake b/CMakeFilters.cmake
index b2845f7..0fd994f 100644
--- a/CMakeFilters.cmake
+++ b/CMakeFilters.cmake
@@ -3,158 +3,160 @@
 # Options for HDF4 Filters
 #-----------------------------------------------------------------------------
 
-INCLUDE (ExternalProject)
-OPTION (HDF4_ALLOW_EXTERNAL_SUPPORT "Allow External Library Building (NO SVN TGZ)" "NO")
-IF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
-  OPTION (JPEG_USE_EXTERNAL "Use External Library Building for JPEG" 1)
-  OPTION (ZLIB_USE_EXTERNAL "Use External Library Building for ZLIB" 1)
-  OPTION (SZIP_USE_EXTERNAL "Use External Library Building for SZIP" 1)
-  IF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN")
-    SET (JPEG_URL ${JPEG_SVN_URL})
-    SET (ZLIB_URL ${ZLIB_SVN_URL})
-    SET (SZIP_URL ${SZIP_SVN_URL})
-  ELSEIF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
-    IF (NOT TGZPATH)
-      SET (TGZPATH ${HDF4_SOURCE_DIR})
-    ENDIF (NOT TGZPATH)
-    SET (JPEG_URL ${TGZPATH}/${JPEG_TGZ_NAME})
-    SET (ZLIB_URL ${TGZPATH}/${ZLIB_TGZ_NAME})
-    SET (SZIP_URL ${TGZPATH}/${SZIP_TGZ_NAME})
-  ELSE (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN")
-    SET (JPEG_USE_EXTERNAL 0)
-    SET (ZLIB_USE_EXTERNAL 0)
-    SET (SZIP_USE_EXTERNAL 0)
-  ENDIF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN")
-ENDIF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+include (ExternalProject)
+#option (HDF4_ALLOW_EXTERNAL_SUPPORT "Allow External Library Building (NO SVN TGZ)" "NO")
+set (HDF4_ALLOW_EXTERNAL_SUPPORT "NO" CACHE STRING "Allow External Library Building (NO SVN TGZ)")
+set_property (CACHE HDF4_ALLOW_EXTERNAL_SUPPORT PROPERTY STRINGS NO SVN TGZ)
+if (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+  option (JPEG_USE_EXTERNAL "Use External Library Building for JPEG" 1)
+  option (ZLIB_USE_EXTERNAL "Use External Library Building for ZLIB" 1)
+  option (SZIP_USE_EXTERNAL "Use External Library Building for SZIP" 1)
+  if (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN")
+    set (JPEG_URL ${JPEG_SVN_URL})
+    set (ZLIB_URL ${ZLIB_SVN_URL})
+    set (SZIP_URL ${SZIP_SVN_URL})
+  elseif (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+    if (NOT TGZPATH)
+      set (TGZPATH ${HDF4_SOURCE_DIR})
+    endif (NOT TGZPATH)
+    set (JPEG_URL ${TGZPATH}/${JPEG_TGZ_NAME})
+    set (ZLIB_URL ${TGZPATH}/${ZLIB_TGZ_NAME})
+    set (SZIP_URL ${TGZPATH}/${SZIP_TGZ_NAME})
+  else (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN")
+    set (JPEG_USE_EXTERNAL 0)
+    set (ZLIB_USE_EXTERNAL 0)
+    set (SZIP_USE_EXTERNAL 0)
+  endif (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN")
+endif (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
 
 #-----------------------------------------------------------------------------
 # Option for LibJpeg support
 #-----------------------------------------------------------------------------
-OPTION (HDF4_ENABLE_JPEG_LIB_SUPPORT "Enable libjpeg" ON)
-IF (HDF4_ENABLE_JPEG_LIB_SUPPORT)
-  IF (NOT H4_JPEGLIB_HEADER)
-    IF (NOT JPEG_USE_EXTERNAL)
-      FIND_PACKAGE (JPEG NAMES ${JPEG_PACKAGE_NAME}${HDF_PACKAGE_EXT})
-      IF (NOT JPEG_FOUND)
-        FIND_PACKAGE (JPEG) # Legacy find
-      ENDIF (NOT JPEG_FOUND)
-    ENDIF (NOT JPEG_USE_EXTERNAL)
-    IF (JPEG_FOUND)
-      SET (H4_HAVE_JPEGLIB_H 1)
-      SET (H4_HAVE_LIBJPEG 1)
-      SET (H4_JPEGLIB_HEADER "jpeglib.h")
-      SET (JPEG_INCLUDE_DIR_GEN ${JPEG_INCLUDE_DIR})
-      SET (JPEG_INCLUDE_DIRS ${JPEG_INCLUDE_DIR})
-    ELSE (JPEG_FOUND)
-      IF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+option (HDF4_ENABLE_JPEG_LIB_SUPPORT "Enable libjpeg" ON)
+if (HDF4_ENABLE_JPEG_LIB_SUPPORT)
+  if (NOT H4_JPEGLIB_HEADER)
+    if (NOT JPEG_USE_EXTERNAL)
+      find_package (JPEG NAMES ${JPEG_PACKAGE_NAME}${HDF_PACKAGE_EXT})
+      if (NOT JPEG_FOUND)
+        find_package (JPEG) # Legacy find
+      endif (NOT JPEG_FOUND)
+    endif (NOT JPEG_USE_EXTERNAL)
+    if (JPEG_FOUND)
+      set (H4_HAVE_JPEGLIB_H 1)
+      set (H4_HAVE_LIBJPEG 1)
+      set (H4_JPEGLIB_HEADER "jpeglib.h")
+      set (JPEG_INCLUDE_DIR_GEN ${JPEG_INCLUDE_DIR})
+      set (JPEG_INCLUDE_DIRS ${JPEG_INCLUDE_DIR})
+    else (JPEG_FOUND)
+      if (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
         # May need to build JPEG with PIC on x64 machines with gcc
         # Need to use CMAKE_ANSI_CFLAGS define so that compiler test works
-        IF (BUILD_JPEG_WITH_PIC)
-          SET (JPEG_CMAKE_C_FLAGS "-fPIC")
-        ELSE (BUILD_JPEG_WITH_PIC)
-          IF (DEFINED CMAKE_ANSI_CFLAGS)
-            SET (JPEG_CMAKE_C_FLAGS ${CMAKE_ANSI_CFLAGS})
-          ELSE (DEFINED CMAKE_ANSI_CFLAGS)
-            SET (JPEG_CMAKE_C_FLAGS " ")
-          ENDIF (DEFINED CMAKE_ANSI_CFLAGS)
-        ENDIF (BUILD_JPEG_WITH_PIC)
+        if (BUILD_JPEG_WITH_PIC)
+          set (JPEG_CMAKE_C_FLAGS "-fPIC")
+        else (BUILD_JPEG_WITH_PIC)
+          if (DEFINED CMAKE_ANSI_CFLAGS)
+            set (JPEG_CMAKE_C_FLAGS ${CMAKE_ANSI_CFLAGS})
+          else (DEFINED CMAKE_ANSI_CFLAGS)
+            set (JPEG_CMAKE_C_FLAGS " ")
+          endif (DEFINED CMAKE_ANSI_CFLAGS)
+        endif (BUILD_JPEG_WITH_PIC)
 
         EXTERNAL_JPEG_LIBRARY (${HDF4_ALLOW_EXTERNAL_SUPPORT} ${LIB_TYPE} ${JPEG_CMAKE_C_FLAGS})
-        SET (H4_HAVE_JPEGLIB_H 1)
-        SET (H4_HAVE_LIBJPEG 1)
-        SET (H4_JPEGLIB_HEADER "jpeglib.h")
-        MESSAGE (STATUS "JPEGLIB is built")
-      ELSE (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
-        MESSAGE (FATAL_ERROR " JPEGLib is Required for JPEGLib support in HDF4")
-      ENDIF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
-    ENDIF (JPEG_FOUND)
-  ELSE (NOT H4_JPEGLIB_HEADER)
+        set (H4_HAVE_JPEGLIB_H 1)
+        set (H4_HAVE_LIBJPEG 1)
+        set (H4_JPEGLIB_HEADER "jpeglib.h")
+        message (STATUS "JPEGLIB is built")
+      else (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+        message (FATAL_ERROR " JPEGLib is Required for JPEGLib support in HDF4")
+      endif (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+    endif (JPEG_FOUND)
+  else (NOT H4_JPEGLIB_HEADER)
     # This project is being called from within another and JPEGLib is already configured
-    SET (H4_HAVE_JPEGLIB_H 1)
-  ENDIF (NOT H4_JPEGLIB_HEADER)
-  SET (LINK_LIBS ${LINK_LIBS} ${JPEG_LIBRARY})
+    set (H4_HAVE_JPEGLIB_H 1)
+  endif (NOT H4_JPEGLIB_HEADER)
+  set (LINK_LIBS ${LINK_LIBS} ${JPEG_LIBRARY})
   INCLUDE_DIRECTORIES (${JPEG_INCLUDE_DIRS})
-  MESSAGE (STATUS "JPEGLIB is ON")
-ENDIF (HDF4_ENABLE_JPEG_LIB_SUPPORT)
+  message (STATUS "JPEGLIB is ON")
+endif (HDF4_ENABLE_JPEG_LIB_SUPPORT)
 
 #-----------------------------------------------------------------------------
 # Option for ZLib support
 #-----------------------------------------------------------------------------
-OPTION (HDF4_ENABLE_Z_LIB_SUPPORT "Enable Zlib Filters" ON)
-IF (HDF4_ENABLE_Z_LIB_SUPPORT)
-  IF (NOT H4_ZLIB_HEADER)
-    IF (NOT ZLIB_USE_EXTERNAL)
-      FIND_PACKAGE (ZLIB NAMES ${ZLIB_PACKAGE_NAME}${HDF_PACKAGE_EXT})
-      IF (NOT ZLIB_FOUND)
-        FIND_PACKAGE (ZLIB) # Legacy find
-      ENDIF (NOT ZLIB_FOUND)
-    ENDIF (NOT ZLIB_USE_EXTERNAL)
-    IF (ZLIB_FOUND)
-      SET (H4_HAVE_FILTER_DEFLATE 1)
-      SET (H4_HAVE_ZLIB_H 1)
-      SET (H4_HAVE_LIBZ 1)
-      SET (H4_ZLIB_HEADER "zlib.h")
-      SET (ZLIB_INCLUDE_DIR_GEN ${ZLIB_INCLUDE_DIR})
-      SET (ZLIB_INCLUDE_DIRS ${ZLIB_INCLUDE_DIR})
-    ELSE (ZLIB_FOUND)
-      IF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+option (HDF4_ENABLE_Z_LIB_SUPPORT "Enable Zlib Filters" ON)
+if (HDF4_ENABLE_Z_LIB_SUPPORT)
+  if (NOT H4_ZLIB_HEADER)
+    if (NOT ZLIB_USE_EXTERNAL)
+      find_package (ZLIB NAMES ${ZLIB_PACKAGE_NAME}${HDF_PACKAGE_EXT})
+      if (NOT ZLIB_FOUND)
+        find_package (ZLIB) # Legacy find
+      endif (NOT ZLIB_FOUND)
+    endif (NOT ZLIB_USE_EXTERNAL)
+    if (ZLIB_FOUND)
+      set (H4_HAVE_FILTER_DEFLATE 1)
+      set (H4_HAVE_ZLIB_H 1)
+      set (H4_HAVE_LIBZ 1)
+      set (H4_ZLIB_HEADER "zlib.h")
+      set (ZLIB_INCLUDE_DIR_GEN ${ZLIB_INCLUDE_DIR})
+      set (ZLIB_INCLUDE_DIRS ${ZLIB_INCLUDE_DIR})
+    else (ZLIB_FOUND)
+      if (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
         EXTERNAL_ZLIB_LIBRARY (${HDF4_ALLOW_EXTERNAL_SUPPORT} ${LIB_TYPE})
-        SET (H4_HAVE_FILTER_DEFLATE 1)
-        SET (H4_HAVE_ZLIB_H 1)
-        SET (H4_HAVE_LIBZ 1)
-        MESSAGE (STATUS "Filter ZLIB is built")
-      ELSE (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
-        MESSAGE (FATAL_ERROR " ZLib is Required for ZLib support in HDF4")
-      ENDIF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
-    ENDIF (ZLIB_FOUND)
-  ELSE (NOT H4_ZLIB_HEADER)
+        set (H4_HAVE_FILTER_DEFLATE 1)
+        set (H4_HAVE_ZLIB_H 1)
+        set (H4_HAVE_LIBZ 1)
+        message (STATUS "Filter ZLIB is built")
+      else (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+        message (FATAL_ERROR " ZLib is Required for ZLib support in HDF4")
+      endif (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+    endif (ZLIB_FOUND)
+  else (NOT H4_ZLIB_HEADER)
     # This project is being called from within another and ZLib is already configured
-    SET (H4_HAVE_FILTER_DEFLATE 1)
-    SET (H4_HAVE_ZLIB_H 1)
-    SET (H4_HAVE_LIBZ 1)
-  ENDIF (NOT H4_ZLIB_HEADER)
-  SET (LINK_LIBS ${LINK_LIBS} ${ZLIB_LIBRARIES})
+    set (H4_HAVE_FILTER_DEFLATE 1)
+    set (H4_HAVE_ZLIB_H 1)
+    set (H4_HAVE_LIBZ 1)
+  endif (NOT H4_ZLIB_HEADER)
+  set (LINK_LIBS ${LINK_LIBS} ${ZLIB_LIBRARIES})
   INCLUDE_DIRECTORIES (${ZLIB_INCLUDE_DIRS})
-  MESSAGE (STATUS "Filter ZLIB is ON")
-ENDIF (HDF4_ENABLE_Z_LIB_SUPPORT)
+  message (STATUS "Filter ZLIB is ON")
+endif (HDF4_ENABLE_Z_LIB_SUPPORT)
 
 #-----------------------------------------------------------------------------
 # Option for SzLib support
 #-----------------------------------------------------------------------------
-OPTION (HDF4_ENABLE_SZIP_SUPPORT "Use SZip Filter" OFF)
-SET (SZIP_INFO "disabled")
-IF (HDF4_ENABLE_SZIP_SUPPORT)
-  OPTION (HDF4_ENABLE_SZIP_ENCODING "Use SZip Encoding" OFF)
-  IF (NOT SZIP_USE_EXTERNAL)
-    FIND_PACKAGE (SZIP NAMES ${SZIP_PACKAGE_NAME}${HDF_PACKAGE_EXT})
-    IF (NOT SZIP_FOUND)
-      FIND_PACKAGE (SZIP) # Legacy find
-    ENDIF (NOT SZIP_FOUND)
-  ENDIF (NOT SZIP_USE_EXTERNAL)
-  IF (SZIP_FOUND)
-    SET (H4_HAVE_FILTER_SZIP 1)
-    SET (H4_HAVE_SZLIB_H 1)
-    SET (H4_HAVE_LIBSZ 1)
-    SET (SZIP_INCLUDE_DIR_GEN ${SZIP_INCLUDE_DIR})
-    SET (SZIP_INCLUDE_DIRS ${SZIP_INCLUDE_DIR})
-  ELSE (SZIP_FOUND)
-    IF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+option (HDF4_ENABLE_SZIP_SUPPORT "Use SZip Filter" OFF)
+set (SZIP_INFO "disabled")
+if (HDF4_ENABLE_SZIP_SUPPORT)
+  option (HDF4_ENABLE_SZIP_ENCODING "Use SZip Encoding" OFF)
+  if (NOT SZIP_USE_EXTERNAL)
+    find_package (SZIP NAMES ${SZIP_PACKAGE_NAME}${HDF_PACKAGE_EXT})
+    if (NOT SZIP_FOUND)
+      find_package (SZIP) # Legacy find
+    endif (NOT SZIP_FOUND)
+  endif (NOT SZIP_USE_EXTERNAL)
+  if (SZIP_FOUND)
+    set (H4_HAVE_FILTER_SZIP 1)
+    set (H4_HAVE_SZLIB_H 1)
+    set (H4_HAVE_LIBSZ 1)
+    set (SZIP_INCLUDE_DIR_GEN ${SZIP_INCLUDE_DIR})
+    set (SZIP_INCLUDE_DIRS ${SZIP_INCLUDE_DIR})
+  else (SZIP_FOUND)
+    if (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
       EXTERNAL_SZIP_LIBRARY (${HDF4_ALLOW_EXTERNAL_SUPPORT} ${LIB_TYPE} ${HDF4_ENABLE_SZIP_ENCODING})
-      SET (H4_HAVE_FILTER_SZIP 1)
-      SET (H4_HAVE_SZLIB_H 1)
-      SET (H4_HAVE_LIBSZ 1)
-      MESSAGE (STATUS "Filter SZIP is built")
-    ELSE (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
-      MESSAGE (FATAL_ERROR "SZIP is Required for SZIP support in HDF4")
-    ENDIF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
-  ENDIF (SZIP_FOUND)
-  SET (LINK_LIBS ${LINK_LIBS} ${SZIP_LIBRARIES})
+      set (H4_HAVE_FILTER_SZIP 1)
+      set (H4_HAVE_SZLIB_H 1)
+      set (H4_HAVE_LIBSZ 1)
+      message (STATUS "Filter SZIP is built")
+    else (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+      message (FATAL_ERROR "SZIP is Required for SZIP support in HDF4")
+    endif (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+  endif (SZIP_FOUND)
+  set (LINK_LIBS ${LINK_LIBS} ${SZIP_LIBRARIES})
   INCLUDE_DIRECTORIES (${SZIP_INCLUDE_DIRS})
-  MESSAGE (STATUS "Filter SZIP is ON")
-  IF (HDF4_ENABLE_SZIP_ENCODING)
-    SET (H4_HAVE_SZIP_ENCODER 1)
-    SET (SZIP_INFO "enabled with encoder")
-  ELSE (HDF4_ENABLE_SZIP_ENCODING)
-    SET (SZIP_INFO "enabled with decoder only")
-  ENDIF (HDF4_ENABLE_SZIP_ENCODING)
-ENDIF (HDF4_ENABLE_SZIP_SUPPORT)
+  message (STATUS "Filter SZIP is ON")
+  if (HDF4_ENABLE_SZIP_ENCODING)
+    set (H4_HAVE_SZIP_ENCODER 1)
+    set (SZIP_INFO "enabled with encoder")
+  else (HDF4_ENABLE_SZIP_ENCODING)
+    set (SZIP_INFO "enabled with decoder only")
+  endif (HDF4_ENABLE_SZIP_ENCODING)
+endif (HDF4_ENABLE_SZIP_SUPPORT)
diff --git a/CMakeInstallation.cmake b/CMakeInstallation.cmake
index 9cc99e3..8d3e4f8 100644
--- a/CMakeInstallation.cmake
+++ b/CMakeInstallation.cmake
@@ -1,114 +1,126 @@
 
 #-----------------------------------------------------------------------------
+# Check for Installation Utilities
+#-----------------------------------------------------------------------------
+if (WIN32)
+  set (PF_ENV_EXT "(x86)")
+  find_program (NSIS_EXECUTABLE NSIS.exe PATHS "$ENV{ProgramFiles}\\NSIS" "$ENV{ProgramFiles${PF_ENV_EXT}}\\NSIS")
+  if(NOT CPACK_WIX_ROOT)
+    file(TO_CMAKE_PATH "$ENV{WIX}" CPACK_WIX_ROOT)
+  endif()
+  find_program (WIX_EXECUTABLE candle  PATHS "${CPACK_WIX_ROOT}/bin")
+endif (WIN32)
+
+#-----------------------------------------------------------------------------
 # Add file(s) to CMake Install
 #-----------------------------------------------------------------------------
-IF (NOT HDF4_INSTALL_NO_DEVELOPMENT)
-  INSTALL (
+if (NOT HDF4_INSTALL_NO_DEVELOPMENT)
+  install (
       FILES ${PROJECT_BINARY_DIR}/h4config.h
       DESTINATION ${HDF4_INSTALL_INCLUDE_DIR}
       COMPONENT headers
   )
-ENDIF (NOT HDF4_INSTALL_NO_DEVELOPMENT)
+endif (NOT HDF4_INSTALL_NO_DEVELOPMENT)
 
 #-----------------------------------------------------------------------------
 # Add Target(s) to CMake Install for import into other projects
 #-----------------------------------------------------------------------------
-IF (NOT HDF4_EXTERNALLY_CONFIGURED)
-  INSTALL (
+if (NOT HDF4_EXTERNALLY_CONFIGURED)
+  install (
       EXPORT ${HDF4_EXPORTED_TARGETS}
       DESTINATION ${HDF4_INSTALL_CMAKE_DIR}/${HDF4_PACKAGE}
       FILE ${HDF4_PACKAGE}${HDF_PACKAGE_EXT}-targets.cmake
       COMPONENT configinstall
   )
-ENDIF (NOT HDF4_EXTERNALLY_CONFIGURED)
+endif (NOT HDF4_EXTERNALLY_CONFIGURED)
 
 #-----------------------------------------------------------------------------
 # Export all exported targets to the build tree for use by parent project
 #-----------------------------------------------------------------------------
-IF (NOT HDF4_EXTERNALLY_CONFIGURED)
-  EXPORT (
+if (NOT HDF4_EXTERNALLY_CONFIGURED)
+  export (
       TARGETS ${HDF4_LIBRARIES_TO_EXPORT} ${HDF4_LIB_DEPENDENCIES}
       FILE ${HDF4_PACKAGE}${HDF_PACKAGE_EXT}-targets.cmake
   )
-ENDIF (NOT HDF4_EXTERNALLY_CONFIGURED)
+endif (NOT HDF4_EXTERNALLY_CONFIGURED)
 
 #-----------------------------------------------------------------------------
 # Configure the hdf4-config.cmake file for the build directory
 #-----------------------------------------------------------------------------
-SET (HDF4_INCLUDES_BUILD_TIME
+set (HDF4_INCLUDES_BUILD_TIME
     ${HDF4_HDF_SOURCE_DIR}
     ${HDF4_MFHDF_SOURCE_DIR}
     ${HDF4_MFHDF_XDR_DIR}
     ${HDF4_BINARY_DIR}
 )
-SET (HDF4_VERSION_STRING @HDF4_PACKAGE_VERSION@)
-SET (HDF4_VERSION_MAJOR  @HDF4_PACKAGE_VERSION_MAJOR@)
-SET (HDF4_VERSION_MINOR  @HDF4_PACKAGE_VERSION_MINOR@)
+set (HDF4_VERSION_STRING ${HDF4_PACKAGE_VERSION})
+set (HDF4_VERSION_MAJOR  ${HDF4_PACKAGE_VERSION_MAJOR})
+set (HDF4_VERSION_MINOR  ${HDF4_PACKAGE_VERSION_MINOR})
 
-CONFIGURE_FILE (
-    ${HDF4_RESOURCES_DIR}/hdf4-config.cmake.build.in 
+configure_file (
+    ${HDF_RESOURCES_DIR}/hdf4-config.cmake.build.in 
     ${HDF4_BINARY_DIR}/${HDF4_PACKAGE}${HDF_PACKAGE_EXT}-config.cmake @ONLY
 )
 
 #-----------------------------------------------------------------------------
 # Configure the FindHDF4.cmake file for the install directory
 #-----------------------------------------------------------------------------
-IF (NOT HDF4_EXTERNALLY_CONFIGURED)
-  CONFIGURE_FILE (
-      ${HDF4_RESOURCES_DIR}/FindHDF4.cmake.in 
+if (NOT HDF4_EXTERNALLY_CONFIGURED)
+  configure_file (
+      ${HDF_RESOURCES_DIR}/FindHDF4.cmake.in 
       ${HDF4_BINARY_DIR}/CMakeFiles/FindHDF4${HDF_PACKAGE_EXT}.cmake @ONLY
   )
-  INSTALL (
+  install (
       FILES ${HDF4_BINARY_DIR}/CMakeFiles/FindHDF4${HDF_PACKAGE_EXT}.cmake
       DESTINATION ${HDF4_INSTALL_CMAKE_DIR}/${HDF4_PACKAGE}
       COMPONENT configinstall
   )
-ENDIF (NOT HDF4_EXTERNALLY_CONFIGURED)
+endif (NOT HDF4_EXTERNALLY_CONFIGURED)
 
 
 #-----------------------------------------------------------------------------
-# Configure the HDF4-config.cmake file for the install directory
+# Configure the hdf4-config.cmake file for the install directory
 #-----------------------------------------------------------------------------
-IF (NOT HDF4_EXTERNALLY_CONFIGURED)
-  CONFIGURE_FILE (
-      ${HDF4_RESOURCES_DIR}/hdf4-config.cmake.install.in
+if (NOT HDF4_EXTERNALLY_CONFIGURED)
+  configure_file (
+      ${HDF_RESOURCES_DIR}/hdf4-config.cmake.install.in
       ${HDF4_BINARY_DIR}/CMakeFiles/${HDF4_PACKAGE}${HDF_PACKAGE_EXT}-config.cmake @ONLY
   )
-  INSTALL (
+  install (
       FILES ${HDF4_BINARY_DIR}/CMakeFiles/${HDF4_PACKAGE}${HDF_PACKAGE_EXT}-config.cmake
       DESTINATION ${HDF4_INSTALL_CMAKE_DIR}/${HDF4_PACKAGE}
       COMPONENT configinstall
   )
-ENDIF (NOT HDF4_EXTERNALLY_CONFIGURED)
+endif (NOT HDF4_EXTERNALLY_CONFIGURED)
 
 #-----------------------------------------------------------------------------
 # Configure the hdf4-config-version .cmake file for the install directory
 #-----------------------------------------------------------------------------
-IF (NOT HDF4_EXTERNALLY_CONFIGURED)
-  CONFIGURE_FILE (
-      ${HDF4_RESOURCES_DIR}/hdf4-config-version.cmake.in
+if (NOT HDF4_EXTERNALLY_CONFIGURED)
+  configure_file (
+      ${HDF_RESOURCES_DIR}/hdf4-config-version.cmake.in
       ${HDF4_BINARY_DIR}/CMakeFiles/${HDF4_PACKAGE}${HDF_PACKAGE_EXT}-config-version.cmake @ONLY
   )
-  INSTALL (
+  install (
       FILES ${HDF4_BINARY_DIR}/CMakeFiles/${HDF4_PACKAGE}${HDF_PACKAGE_EXT}-config-version.cmake
       DESTINATION ${HDF4_INSTALL_CMAKE_DIR}/${HDF4_PACKAGE}
       COMPONENT configinstall
   )
-ENDIF (NOT HDF4_EXTERNALLY_CONFIGURED)
+endif (NOT HDF4_EXTERNALLY_CONFIGURED)
 
 #-----------------------------------------------------------------------------
 # Configure the libhdf4.settings file for the lib info
 #-----------------------------------------------------------------------------
-IF (H4_WORDS_BIGENDIAN)
-  SET (BYTESEX big-endian)
-ELSE (H4_WORDS_BIGENDIAN)
-  SET (BYTESEX little-endian)
-ENDIF (H4_WORDS_BIGENDIAN)
-CONFIGURE_FILE (
-    ${HDF4_RESOURCES_DIR}/libhdf4.settings.cmake.in 
+if (H4_WORDS_BIGENDIAN)
+  set (BYTESEX big-endian)
+else (H4_WORDS_BIGENDIAN)
+  set (BYTESEX little-endian)
+endif (H4_WORDS_BIGENDIAN)
+configure_file (
+    ${HDF_RESOURCES_DIR}/libhdf4.settings.cmake.in 
     ${HDF4_BINARY_DIR}/libhdf4.settings @ONLY
 )
-INSTALL (
+install (
     FILES ${HDF4_BINARY_DIR}/libhdf4.settings
     DESTINATION ${HDF4_INSTALL_CMAKE_DIR}/${HDF4_PACKAGE}
     COMPONENT libraries
@@ -117,242 +129,340 @@ INSTALL (
 #-----------------------------------------------------------------------------
 # Configure the HDF4_Examples.cmake file and the examples
 #-----------------------------------------------------------------------------
-OPTION (HDF4_PACK_EXAMPLES  "Package the HDF4 Library Examples Compressed File" OFF)
-IF (HDF4_PACK_EXAMPLES)
-  CONFIGURE_FILE (
-      ${HDF4_RESOURCES_DIR}/HDF4_Examples.cmake.in 
+option (HDF4_PACK_EXAMPLES  "Package the HDF4 Library Examples Compressed File" OFF)
+if (HDF4_PACK_EXAMPLES)
+  configure_file (
+      ${HDF_RESOURCES_DIR}/HDF4_Examples.cmake.in 
       ${HDF4_BINARY_DIR}/HDF4_Examples.cmake @ONLY
   )
-  INSTALL (
+  install (
       FILES ${HDF4_BINARY_DIR}/HDF4_Examples.cmake
       DESTINATION ${HDF4_INSTALL_DATA_DIR}
       COMPONENT hdfdocuments
   )
-  IF (EXISTS "${HDF4_EXAMPLES_COMPRESSED_DIR}/${HDF4_EXAMPLES_COMPRESSED}")
-    INSTALL (
+  if (EXISTS "${HDF4_EXAMPLES_COMPRESSED_DIR}/${HDF4_EXAMPLES_COMPRESSED}")
+    install (
         FILES
             ${HDF4_EXAMPLES_COMPRESSED_DIR}/${HDF4_EXAMPLES_COMPRESSED}
             ${HDF4_SOURCE_DIR}/release_notes/USING_CMake_Examples.txt
         DESTINATION ${HDF4_INSTALL_DATA_DIR}
         COMPONENT hdfdocuments
     )
-  ENDIF (EXISTS "${HDF4_EXAMPLES_COMPRESSED_DIR}/${HDF4_EXAMPLES_COMPRESSED}")
-ENDIF (HDF4_PACK_EXAMPLES)
+  endif (EXISTS "${HDF4_EXAMPLES_COMPRESSED_DIR}/${HDF4_EXAMPLES_COMPRESSED}")
+endif (HDF4_PACK_EXAMPLES)
+
+#-----------------------------------------------------------------------------
+# Configure the README.txt file for the binary package
+#-----------------------------------------------------------------------------
+HDF_README_PROPERTIES(HDF4_BUILD_FORTRAN)
+
+#-----------------------------------------------------------------------------
+# Configure the COPYING.txt file for the windows binary package
+#-----------------------------------------------------------------------------
+if (WIN32)
+  configure_file (${HDF4_SOURCE_DIR}/COPYING ${HDF4_BINARY_DIR}/COPYING.txt @ONLY)
+endif (WIN32)
 
 #-----------------------------------------------------------------------------
 # Add Document File(s) to CMake Install
 #-----------------------------------------------------------------------------
-IF (NOT HDF4_EXTERNALLY_CONFIGURED)
-  INSTALL (
+if (NOT HDF4_EXTERNALLY_CONFIGURED)
+  install (
       FILES
           ${HDF4_SOURCE_DIR}/COPYING
       DESTINATION ${HDF4_INSTALL_DATA_DIR}
       COMPONENT hdfdocuments
   )
-  IF (EXISTS "${HDF4_SOURCE_DIR}/release_notes" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/release_notes")
-    SET (release_files
+  if (EXISTS "${HDF4_SOURCE_DIR}/release_notes" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/release_notes")
+    set (release_files
         ${HDF4_SOURCE_DIR}/release_notes/USING_HDF4_CMake.txt
         ${HDF4_SOURCE_DIR}/release_notes/RELEASE.txt
     )
-    IF (WIN32 AND NOT CYGWIN)
-      SET (release_files
+    if (WIN32)
+      set (release_files
           ${release_files}
           ${HDF4_SOURCE_DIR}/release_notes/USING_HDF4_VS.txt
       )
-    ENDIF (WIN32 AND NOT CYGWIN)
-    IF (HDF5_PACK_INSTALL_DOCS)
-      SET (release_files
+    endif (WIN32)
+    if (HDF4_PACK_INSTALL_DOCS)
+      set (release_files
           ${release_files}
           ${HDF4_SOURCE_DIR}/release_notes/INSTALL_CMake.txt
           ${HDF4_SOURCE_DIR}/release_notes/HISTORY.txt
           ${HDF4_SOURCE_DIR}/release_notes/INSTALL
       )
-      IF (WIN32)
-        IF (NOT CYGWIN)
-          SET (release_files
-              ${release_files}
-              ${HDF5_SOURCE_DIR}/release_notes/INSTALL_Windows.txt
-          )
-        ELSE (NOT CYGWIN)
-          SET (release_files
-              ${release_files}
-              ${HDF5_SOURCE_DIR}/release_notes/INSTALL_Cygwin.txt
-          )
-        ENDIF (NOT CYGWIN)
-      ENDIF (WIN32)
-    ENDIF (HDF5_PACK_INSTALL_DOCS)
-    INSTALL (
+      if (WIN32)
+        set (release_files
+            ${release_files}
+            ${HDF4_SOURCE_DIR}/release_notes/INSTALL_Windows.txt
+        )
+      endif (WIN32)
+      if (CYGWIN)
+        set (release_files
+            ${release_files}
+            ${HDF4_SOURCE_DIR}/release_notes/INSTALL_Cygwin.txt
+        )
+      endif (CYGWIN)
+    endif (HDF4_PACK_INSTALL_DOCS)
+    install (
         FILES ${release_files}
         DESTINATION ${HDF4_INSTALL_DATA_DIR}
         COMPONENT hdfdocuments
     )
-  ENDIF (EXISTS "${HDF4_SOURCE_DIR}/release_notes" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/release_notes")
-ENDIF (NOT HDF4_EXTERNALLY_CONFIGURED)
+  endif (EXISTS "${HDF4_SOURCE_DIR}/release_notes" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/release_notes")
+endif (NOT HDF4_EXTERNALLY_CONFIGURED)
+
+if (CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
+  if (CMAKE_HOST_UNIX)
+    set (CMAKE_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}/HDF_Group/${HDF4_PACKAGE_NAME}/${HDF5_PACKAGE_VERSION}"
+      CACHE PATH "Install path prefix, prepended onto install directories." FORCE)
+  else (CMAKE_HOST_UNIX)
+    GetDefaultWindowsPrefixBase(CMAKE_GENERIC_PROGRAM_FILES)
+    set (CMAKE_INSTALL_PREFIX
+      "${CMAKE_GENERIC_PROGRAM_FILES}/HDF_Group/${HDF4_PACKAGE_NAME}/${HDF4_PACKAGE_VERSION}"
+      CACHE PATH "Install path prefix, prepended onto install directories." FORCE)
+    set (CMAKE_GENERIC_PROGRAM_FILES)
+  endif (CMAKE_HOST_UNIX)
+endif (CMAKE_INSTALL_PREFIX_INITIALIZED_TO_DEFAULT)
 
 #-----------------------------------------------------------------------------
 # Set the cpack variables
 #-----------------------------------------------------------------------------
-IF (NOT HDF4_EXTERNALLY_CONFIGURED AND NOT HDF4_NO_PACKAGES)
-  SET (CPACK_PACKAGE_VENDOR "HDF_Group")
-  SET (CPACK_PACKAGE_NAME "${HDF4_PACKAGE_NAME}")
-  SET (CPACK_PACKAGE_VERSION "${HDF4_PACKAGE_VERSION}")
-  SET (CPACK_PACKAGE_VERSION_MAJOR "${HDF4_PACKAGE_VERSION_MAJOR}")
-  SET (CPACK_PACKAGE_VERSION_MINOR "${HDF4_PACKAGE_VERSION_MINOR}")
-  SET (CPACK_PACKAGE_VERSION_PATCH "")
-  SET (CPACK_PACKAGE_INSTALL_DIRECTORY "${CPACK_PACKAGE_VENDOR}/${CPACK_PACKAGE_NAME}/${CPACK_PACKAGE_VERSION}")
-  SET (CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/release_notes/RELEASE.txt")
-  SET (CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/COPYING")
-  SET (CPACK_RESOURCE_FILE_README "${CMAKE_CURRENT_SOURCE_DIR}/release_notes/RELEASE.txt")
-  SET (CPACK_PACKAGE_RELOCATABLE TRUE)
+if (NOT HDF4_EXTERNALLY_CONFIGURED AND NOT HDF4_NO_PACKAGES)
+  set (CPACK_PACKAGE_VENDOR "HDF_Group")
+  set (CPACK_PACKAGE_NAME "${HDF4_PACKAGE_NAME}")
+  if (CDASH_LOCAL)
+    set (CPACK_PACKAGE_VERSION "${HDF4_PACKAGE_VERSION}")
+  else (CDASH_LOCAL)
+    set (CPACK_PACKAGE_VERSION "${HDF4_PACKAGE_VERSION_STRING}")
+  endif (CDASH_LOCAL)
+  set (CPACK_PACKAGE_VERSION_MAJOR "${HDF4_PACKAGE_VERSION_MAJOR}")
+  set (CPACK_PACKAGE_VERSION_MINOR "${HDF4_PACKAGE_VERSION_MINOR}")
+  set (CPACK_PACKAGE_VERSION_PATCH "")
+  set (CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/COPYING")
+  if (EXISTS "${HDF4_SOURCE_DIR}/release_notes")
+    set (CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/release_notes/RELEASE.txt")
+    set (CPACK_RESOURCE_FILE_README "${CMAKE_CURRENT_SOURCE_DIR}/release_notes/RELEASE.txt")
+  endif (EXISTS "${HDF4_SOURCE_DIR}/release_notes")
+  set (CPACK_PACKAGE_RELOCATABLE TRUE)
+  set (CPACK_PACKAGE_INSTALL_DIRECTORY "${CPACK_PACKAGE_VENDOR}/${CPACK_PACKAGE_NAME}/${CPACK_PACKAGE_VERSION}")
+  set (CPACK_PACKAGE_ICON "${HDF_RESOURCES_EXT_DIR}/hdf.bmp")
+
+  set (CPACK_GENERATOR "TGZ") 
+  if (WIN32)
+    set (CPACK_GENERATOR "ZIP") 
 
-  SET (CPACK_GENERATOR "TGZ") 
-  IF (WIN32)
-    LIST (APPEND CPACK_GENERATOR "NSIS") 
+    if (NSIS_EXECUTABLE)    
+      list (APPEND CPACK_GENERATOR "NSIS") 
+    endif (NSIS_EXECUTABLE)    
     # Installers for 32- vs. 64-bit CMake:
     #  - Root install directory (displayed to end user at installer-run time)
     #  - "NSIS package/display name" (text used in the installer GUI)
     #  - Registry key used to store info about the installation
-    IF (CMAKE_CL_64)
-      SET (CPACK_NSIS_INSTALL_ROOT "$PROGRAMFILES64")
-      SET (CPACK_NSIS_PACKAGE_NAME "${HDF4_PACKAGE_STRING} (Win64)")
-      SET (CPACK_PACKAGE_INSTALL_REGISTRY_KEY "${HDF4_PACKAGE_STRING}-${LIB_TYPE} (Win64)")
-    ELSE (CMAKE_CL_64)
-      SET (CPACK_NSIS_INSTALL_ROOT "$PROGRAMFILES")
-      SET (CPACK_NSIS_PACKAGE_NAME "${HDF4_PACKAGE_STRING}")
-      SET (CPACK_PACKAGE_INSTALL_REGISTRY_KEY "${HDF4_PACKAGE_STRING}-${LIB_TYPE}")
-    ENDIF (CMAKE_CL_64)
-    SET (CPACK_PACKAGE_INSTALL_DIRECTORY "${CPACK_PACKAGE_VENDOR}\\\\${CPACK_PACKAGE_NAME}\\\\${CPACK_PACKAGE_VERSION}")
-    SET (CPACK_PACKAGE_INSTALL_REGISTRY_KEY "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}-${LIB_TYPE}")
-    SET (CPACK_MONOLITHIC_INSTALL ON)
-    SET (CPACK_NSIS_CONTACT "${HDF4_PACKAGE_BUGREPORT}")
-    SET (CPACK_NSIS_MODIFY_PATH ON)
-  ELSEIF (APPLE)
-    LIST (APPEND CPACK_GENERATOR "DragNDrop") 
-    SET (CPACK_COMPONENTS_ALL_IN_ONE_PACKAGE ON)
-    SET (CPACK_PACKAGE_DEFAULT_LOCATION "/opt/${CPACK_PACKAGE_NAME}")
-    SET (CPACK_PACKAGING_INSTALL_PREFIX "/")
-    SET (CPACK_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}")
-    SET (CPACK_PACKAGE_ICON "${HDF4_RESOURCES_DIR}/hdf.gif")
-    SET (CPACK_SET_DESTDIR TRUE) # Required when packaging, and set CMAKE_INSTALL_PREFIX to "/".
+    set (CPACK_NSIS_PACKAGE_NAME "${HDF4_PACKAGE_STRING}")
+    if (CMAKE_CL_64)
+      set (CPACK_NSIS_INSTALL_ROOT "$PROGRAMFILES64")
+      set (CPACK_PACKAGE_INSTALL_REGISTRY_KEY "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION} (Win64)")
+    else (CMAKE_CL_64)
+      set (CPACK_NSIS_INSTALL_ROOT "$PROGRAMFILES")
+      set (CPACK_PACKAGE_INSTALL_REGISTRY_KEY "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}")
+    endif (CMAKE_CL_64)
+    # set the install/unistall icon used for the installer itself
+    # There is a bug in NSI that does not handle full unix paths properly.
+    set (CPACK_NSIS_MUI_ICON "${HDF_RESOURCES_EXT_DIR}\\\\hdf.ico")
+    set (CPACK_NSIS_MUI_UNIICON "${HDF_RESOURCES_EXT_DIR}\\\\hdf.ico")
+    # set the package header icon for MUI
+    set (CPACK_PACKAGE_ICON "${HDF_RESOURCES_EXT_DIR}\\\\hdf.bmp")
+    set (CPACK_NSIS_DISPLAY_NAME "${CPACK_NSIS_PACKAGE_NAME}")
+    set (CPACK_PACKAGE_INSTALL_DIRECTORY "${CPACK_PACKAGE_VENDOR}\\\\${CPACK_PACKAGE_NAME}\\\\${CPACK_PACKAGE_VERSION}")
+    set (CPACK_MONOLITHIC_INSTALL ON)
+    set (CPACK_NSIS_CONTACT "${HDF4_PACKAGE_BUGREPORT}")
+    set (CPACK_NSIS_MODIFY_PATH ON)
+    
+    if (WIX_EXECUTABLE)    
+      list (APPEND CPACK_GENERATOR "WIX") 
+    endif (WIX_EXECUTABLE)    
+#WiX variables
+    set (CPACK_WIX_UNINSTALL "1")
+# .. variable:: CPACK_WIX_LICENSE_RTF
+#  RTF License File
+#
+#  If CPACK_RESOURCE_FILE_LICENSE has an .rtf extension it is used as-is.
+#
+#  If CPACK_RESOURCE_FILE_LICENSE has an .txt extension it is implicitly
+#  converted to RTF by the WiX Generator.
+#  The expected encoding of the .txt file is UTF-8.
+#
+#  With CPACK_WIX_LICENSE_RTF you can override the license file used by the
+#  WiX Generator in case CPACK_RESOURCE_FILE_LICENSE is in an unsupported
+#  format or the .txt -> .rtf conversion does not work as expected.
+    set (CPACK_RESOURCE_FILE_LICENSE "${HDF4_BINARY_DIR}/COPYING.txt")
+# .. variable:: CPACK_WIX_PRODUCT_ICON
+#  The Icon shown next to the program name in Add/Remove programs.
+    set(CPACK_WIX_PRODUCT_ICON "${HDF_RESOURCES_EXT_DIR}\\\\hdf.ico")
+#
+# .. variable:: CPACK_WIX_UI_BANNER
+#
+#  The bitmap will appear at the top of all installer pages other than the
+#  welcome and completion dialogs.
+#
+#  If set, this image will replace the default banner image.
+#
+#  This image must be 493 by 58 pixels.
+#
+# .. variable:: CPACK_WIX_UI_DIALOG
+#
+#  Background bitmap used on the welcome and completion dialogs.
+#
+#  If this variable is set, the installer will replace the default dialog
+#  image.
+#
+#  This image must be 493 by 312 pixels.
+#
+  elseif (APPLE)
+    list (APPEND CPACK_GENERATOR "DragNDrop") 
+    set (CPACK_COMPONENTS_ALL_IN_ONE_PACKAGE ON)
+    set (CPACK_PACKAGING_INSTALL_PREFIX "/${CPACK_PACKAGE_INSTALL_DIRECTORY}")
+    set (CPACK_PACKAGE_ICON "${HDF_RESOURCES_EXT_DIR}/hdf.icns")
 
-    IF (HDF4_PACK_MACOSX_BUNDLE)
-      LIST (APPEND CPACK_GENERATOR "Bundle")
-      SET (CPACK_BUNDLE_NAME "${HDF4_PACKAGE_STRING}")
-      SET (CPACK_BUNDLE_LOCATION "/")    # make sure CMAKE_INSTALL_PREFIX ends in /
-      SET (CMAKE_INSTALL_PREFIX "/${CPACK_BUNDLE_NAME}.framework/Versions/${CPACK_PACKAGE_VERSION}/${CPACK_PACKAGE_NAME}/")
-      SET (CPACK_BUNDLE_ICON "${HDF4_RESOURCES_DIR}/hdf.gif")
-      SET (CPACK_BUNDLE_PLIST "${HDF4_BINARY_DIR}/CMakeFiles/Info.plist")
-      SET (CPACK_APPLE_GUI_INFO_STRING "Hierarchical Data Format (HDF) Software Library and Utilities")
-      SET (CPACK_APPLE_GUI_COPYRIGHT "Copyright © 2006-2014 by The HDF Group. All rights reserved.")
-      SET (CPACK_SHORT_VERSION_STRING "${CPACK_PACKAGE_VERSION}")
+    if (HDF4_PACK_MACOSX_BUNDLE)
+      list (APPEND CPACK_GENERATOR "Bundle")
+      set (CPACK_BUNDLE_NAME "${HDF4_PACKAGE_STRING}")
+      set (CPACK_BUNDLE_LOCATION "/")    # make sure CMAKE_INSTALL_PREFIX ends in /
+      set (CMAKE_INSTALL_PREFIX "/${CPACK_BUNDLE_NAME}.framework/Versions/${CPACK_PACKAGE_VERSION}/${CPACK_PACKAGE_NAME}/")
+      set (CPACK_BUNDLE_ICON "${HDF_RESOURCES_EXT_DIR}/hdf.icns")
+      set (CPACK_BUNDLE_PLIST "${HDF4_BINARY_DIR}/CMakeFiles/Info.plist")
+      set (CPACK_APPLE_GUI_INFO_STRING "Hierarchical Data Format (HDF) Software Library and Utilities")
+      set (CPACK_APPLE_GUI_COPYRIGHT "Copyright © 2006-2014 by The HDF Group. All rights reserved.")
+      set (CPACK_SHORT_VERSION_STRING "${CPACK_PACKAGE_VERSION}")
+      set (CPACK_APPLE_GUI_BUNDLE_NAME "${HDF4_PACKAGE_STRING}")
+      set (CPACK_APPLE_GUI_VERSION_STRING "${CPACK_PACKAGE_VERSION_STRING}")
+      set (CPACK_APPLE_GUI_SHORT_VERSION_STRING "${CPACK_PACKAGE_VERSION}")
       #-----------------------------------------------------------------------------
       # Configure the Info.plist file for the install bundle
       #-----------------------------------------------------------------------------
-      CONFIGURE_FILE (
-          ${HDF4_RESOURCES_DIR}/CPack.Info.plist.in
+      configure_file (
+          ${HDF_RESOURCES_EXT_DIR}/CPack.Info.plist.in
           ${HDF4_BINARY_DIR}/CMakeFiles/Info.plist @ONLY
       )
-    ENDIF (HDF4_PACK_MACOSX_BUNDLE)
-  ELSE (WIN32)
-    LIST (APPEND CPACK_GENERATOR "STGZ") 
-    SET (CPACK_PACKAGING_INSTALL_PREFIX "/${CPACK_PACKAGE_INSTALL_DIRECTORY}")
-    SET (CPACK_COMPONENTS_ALL_IN_ONE_PACKAGE ON)
+      configure_file (
+          ${HDF_RESOURCES_DIR}/PkgInfo.in
+          ${HDF4_BINARY_DIR}/CMakeFiles/PkgInfo @ONLY
+      )
+      configure_file (
+          ${HDF_RESOURCES_EXT_DIR}/version.plist.in
+          ${HDF4_BINARY_DIR}/CMakeFiles/version.plist @ONLY
+      )
+      install (
+          FILES ${HDF4_BINARY_DIR}/CMakeFiles/PkgInfo
+                ${HDF4_BINARY_DIR}/CMakeFiles/version.plist
+          DESTINATION ..
+      )
+    endif (HDF4_PACK_MACOSX_BUNDLE)
+  else (WIN32)
+    list (APPEND CPACK_GENERATOR "STGZ") 
+    set (CPACK_PACKAGING_INSTALL_PREFIX "/${CPACK_PACKAGE_INSTALL_DIRECTORY}")
+    set (CPACK_COMPONENTS_ALL_IN_ONE_PACKAGE ON)
 
-    SET (CPACK_DEBIAN_PACKAGE_SECTION "Libraries")
-    SET (CPACK_DEBIAN_PACKAGE_MAINTAINER "${HDF4_PACKAGE_BUGREPORT}")
+    set (CPACK_DEBIAN_PACKAGE_SECTION "Libraries")
+    set (CPACK_DEBIAN_PACKAGE_MAINTAINER "${HDF4_PACKAGE_BUGREPORT}")
     
-    SET (CPACK_RPM_COMPONENT_INSTALL ON)
-    SET (CPACK_RPM_PACKAGE_RELOCATABLE ON)
-    SET (CPACK_RPM_PACKAGE_LICENSE "BSD-style")
-    SET (CPACK_RPM_PACKAGE_GROUP "Development/Libraries")
-    SET (CPACK_RPM_PACKAGE_URL "${HDF4_PACKAGE_URL}")
-  ENDIF (WIN32)
-
-  INCLUDE(InstallRequiredSystemLibraries)
+    set (CPACK_RPM_COMPONENT_INSTALL ON)
+    set (CPACK_RPM_PACKAGE_RELOCATABLE ON)
+    set (CPACK_RPM_PACKAGE_LICENSE "BSD-style")
+    set (CPACK_RPM_PACKAGE_GROUP "Development/Libraries")
+    set (CPACK_RPM_PACKAGE_URL "${HDF4_PACKAGE_URL}")
+  endif (WIN32)
+  
+  # By default, do not warn when built on machines using only VS Express:
+  if (NOT DEFINED CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_NO_WARNINGS)
+    set (CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_NO_WARNINGS ON)
+  endif (NOT DEFINED CMAKE_INSTALL_SYSTEM_RUNTIME_LIBS_NO_WARNINGS)
+  include (InstallRequiredSystemLibraries)
 
-  SET (CPACK_INSTALL_CMAKE_PROJECTS "${HDF4_BINARY_DIR};HDF4;ALL;/")
+  set (CPACK_INSTALL_CMAKE_PROJECTS "${HDF4_BINARY_DIR};HDF4;ALL;/")
   
-  IF (HDF4_PACKAGE_EXTLIBS)
-    IF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
-      IF (JPEG_FOUND AND JPEG_USE_EXTERNAL)
-        SET (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${JPEG_INCLUDE_DIR_GEN};JPEG;libraries;/")
-        SET (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${JPEG_INCLUDE_DIR_GEN};JPEG;headers;/")
-        SET (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${JPEG_INCLUDE_DIR_GEN};JPEG;configinstall;/")
-      ENDIF (JPEG_FOUND AND JPEG_USE_EXTERNAL)
-      IF (ZLIB_FOUND AND ZLIB_USE_EXTERNAL)
-        SET (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${ZLIB_INCLUDE_DIR_GEN};ZLIB;libraries;/")
-        SET (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${ZLIB_INCLUDE_DIR_GEN};ZLIB;headers;/")
-        SET (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${ZLIB_INCLUDE_DIR_GEN};ZLIB;configinstall;/")
-      ENDIF (ZLIB_FOUND AND ZLIB_USE_EXTERNAL)
-      IF (SZIP_FOUND AND SZIP_USE_EXTERNAL)
-        SET (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${SZIP_INCLUDE_DIR_GEN};SZIP;libraries;/")
-        SET (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${SZIP_INCLUDE_DIR_GEN};SZIP;headers;/")
-        SET (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${SZIP_INCLUDE_DIR_GEN};SZIP;configinstall;/")
-      ENDIF (SZIP_FOUND AND SZIP_USE_EXTERNAL)
-    ENDIF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
-  ENDIF (HDF4_PACKAGE_EXTLIBS)
+  if (HDF4_PACKAGE_EXTLIBS)
+    if (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+      if (JPEG_FOUND AND JPEG_USE_EXTERNAL)
+        set (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${JPEG_INCLUDE_DIR_GEN};JPEG;libraries;/")
+        set (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${JPEG_INCLUDE_DIR_GEN};JPEG;headers;/")
+        set (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${JPEG_INCLUDE_DIR_GEN};JPEG;configinstall;/")
+      endif (JPEG_FOUND AND JPEG_USE_EXTERNAL)
+      if (ZLIB_FOUND AND ZLIB_USE_EXTERNAL)
+        set (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${ZLIB_INCLUDE_DIR_GEN};ZLIB;libraries;/")
+        set (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${ZLIB_INCLUDE_DIR_GEN};ZLIB;headers;/")
+        set (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${ZLIB_INCLUDE_DIR_GEN};ZLIB;configinstall;/")
+      endif (ZLIB_FOUND AND ZLIB_USE_EXTERNAL)
+      if (SZIP_FOUND AND SZIP_USE_EXTERNAL)
+        set (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${SZIP_INCLUDE_DIR_GEN};SZIP;libraries;/")
+        set (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${SZIP_INCLUDE_DIR_GEN};SZIP;headers;/")
+        set (CPACK_INSTALL_CMAKE_PROJECTS "${CPACK_INSTALL_CMAKE_PROJECTS};${SZIP_INCLUDE_DIR_GEN};SZIP;configinstall;/")
+      endif (SZIP_FOUND AND SZIP_USE_EXTERNAL)
+    endif (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+  endif (HDF4_PACKAGE_EXTLIBS)
 
-  INCLUDE (CPack)
+  include (CPack)
 
   #-----------------------------------------------------------------------------
   # Now list the cpack commands
   #-----------------------------------------------------------------------------
-  CPACK_ADD_COMPONENT (applications 
+  cpack_add_component (applications 
       DISPLAY_NAME "HDF4 Applications" 
       DEPENDS libraries
       GROUP Applications
   )
-  CPACK_ADD_COMPONENT (libraries 
+  cpack_add_component (libraries 
       DISPLAY_NAME "HDF4 Libraries"
       GROUP Runtime
   )
-  CPACK_ADD_COMPONENT (headers 
+  cpack_add_component (headers 
       DISPLAY_NAME "HDF4 Headers" 
       DEPENDS libraries
       GROUP Development
   )
-  CPACK_ADD_COMPONENT (hdfdocuments 
+  cpack_add_component (hdfdocuments 
       DISPLAY_NAME "HDF4 Documents"
       GROUP Documents
   )
-  CPACK_ADD_COMPONENT (configinstall 
+  cpack_add_component (configinstall 
       DISPLAY_NAME "HDF4 CMake files" 
       DEPENDS libraries
       GROUP Development
   )
 
-  IF (HDF4_BUILD_FORTRAN)
-    CPACK_ADD_COMPONENT (fortlibraries 
+  if (HDF4_BUILD_FORTRAN)
+    cpack_add_component (fortlibraries 
         DISPLAY_NAME "HDF4 Fortran Libraries" 
         DEPENDS libraries
         GROUP Runtime
     )
-  ENDIF (HDF4_BUILD_FORTRAN)
+  endif (HDF4_BUILD_FORTRAN)
 
-  IF (HDF4_BUILD_TOOLS)
-    CPACK_ADD_COMPONENT (toolsapplications 
+  if (HDF4_BUILD_TOOLS)
+    cpack_add_component (toolsapplications 
         DISPLAY_NAME "HDF4 Tools Applications" 
         DEPENDS libraries
         GROUP Applications
     )
-    CPACK_ADD_COMPONENT (toolsheaders 
+    cpack_add_component (toolsheaders 
         DISPLAY_NAME "HDF4 Tools Headers" 
         DEPENDS libraries
         GROUP Development
     )
-  ENDIF (HDF4_BUILD_TOOLS)
+  endif (HDF4_BUILD_TOOLS)
 
-  IF (HDF4_BUILD_UTILS)
-    CPACK_ADD_COMPONENT (utilsapplications 
+  if (HDF4_BUILD_UTILS)
+    cpack_add_component (utilsapplications 
         DISPLAY_NAME "HDF4 Utility Applications" 
         DEPENDS libraries
         GROUP Applications
     )
-    CPACK_ADD_COMPONENT (utilsheaders 
+    cpack_add_component (utilsheaders 
         DISPLAY_NAME "HDF4 Utility Headers" 
         DEPENDS libraries
         GROUP Development
     )
-  ENDIF (HDF4_BUILD_UTILS)
-ENDIF (NOT HDF4_EXTERNALLY_CONFIGURED AND NOT HDF4_NO_PACKAGES)
+  endif (HDF4_BUILD_UTILS)
+endif (NOT HDF4_EXTERNALLY_CONFIGURED AND NOT HDF4_NO_PACKAGES)
   
\ No newline at end of file
diff --git a/CMakeLists.txt b/CMakeLists.txt
index ba2cf13..3209dce 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,4 +1,4 @@
-cmake_minimum_required (VERSION 2.8.10)
+cmake_minimum_required (VERSION 2.8.11)
 PROJECT (HDF4 C CXX)
 
 #-----------------------------------------------------------------------------
@@ -19,8 +19,8 @@ PROJECT (HDF4 C CXX)
 #
 # HDF4_EXPORTED_TARGETS :
 #   Set this to the name of the targets variable which controls exports
-#   If unset (because parent project does not support/use the 
-#   INSTALL (EXPORT target...) syntax), then targets are not configured 
+#   If unset (because parent project does not support/use the
+#   install (EXPORT target...) syntax), then targets are not configured
 #   for export during install.
 #
 # HDF4_LIB_DEPENDENCIES :
@@ -38,37 +38,37 @@ PROJECT (HDF4 C CXX)
 # any project making use of this build of HDF4 will use the correct zlib
 #
 #   # Tell hdf4 that we are manually overriding certain settings
-#   SET (HDF4_EXTERNALLY_CONFIGURED 1)
+#   set (HDF4_EXTERNALLY_CONFIGURED 1)
 #   # Avoid duplicating names of installed libraries
-#   SET (HDF4_EXTERNAL_LIB_PREFIX "prj")
+#   set (HDF4_EXTERNAL_LIB_PREFIX "prj")
 #   # Targets linking to the HDF4 libs need to know their names
 #   # if they are changed in the sub project, they should be here too
-#   SET (HDF4_LIB_NAME "prjhdf4")
-#   SET (HDF4_MF_LIB_NAME "prjhdf4_mf")
-#   SET (HDF4_LIBRARY "${HDF4_LIB_NAME};${HDF4_MF_LIB_NAME}")
+#   set (HDF4_LIB_NAME "prjhdf4")
+#   set (HDF4_MF_LIB_NAME "prjhdf4_mf")
+#   set (HDF4_LIBRARY "${HDF4_LIB_NAME};${HDF4_MF_LIB_NAME}")
 #   # Export configuration to this export variable
-#   SET (HDF4_EXPORTED_TARGETS "project-targets")
+#   set (HDF4_EXPORTED_TARGETS "project-targets")
 #
 #   # Setup all necessary overrides for zlib so that HDF4 uses our
 #   # internally compiled zlib rather than any other version
-#   IF (HDF4_ENABLE_Z_LIB_SUPPORT)
+#   if (HDF4_ENABLE_Z_LIB_SUPPORT)
 #    # We must tell the main HDF4 library that it depends on our zlib 
-#     SET (HDF4_LIB_DEPENDENCIES prjzlib)    
+#     set (HDF4_LIB_DEPENDENCIES prjzlib)    
 #     # Override the zlib header file
-#     IF (PRJ_USE_SYSTEM_ZLIB)
-#       SET (H4_ZLIB_HEADER "zlib.h")
-#     ELSE (PRJ_USE_SYSTEM_ZLIB)
-#      SET (H4_ZLIB_HEADER "prj_zlib.h")
+#     if (PRJ_USE_SYSTEM_ZLIB)
+#       set (H4_ZLIB_HEADER "zlib.h")
+#     else (PRJ_USE_SYSTEM_ZLIB)
+#      set (H4_ZLIB_HEADER "prj_zlib.h")
 #       # Set vars that FindZlib would have set if used in sub project
-#       SET (ZLIB_INCLUDE_DIRS "${PRJ_ZLIB_INCLUDE_DIRS}")
-#       SET (ZLIB_LIBRARIES prjzlib)
-#     ENDIF (PRJ_USE_SYSTEM_ZLIB)
-#  ENDIF (HDF4_ENABLE_Z_LIB_SUPPORT)
+#       set (ZLIB_INCLUDE_DIRS "${PRJ_ZLIB_INCLUDE_DIRS}")
+#       set (ZLIB_LIBRARIES prjzlib)
+#     endif (PRJ_USE_SYSTEM_ZLIB)
+#  endif (HDF4_ENABLE_Z_LIB_SUPPORT)
 #   
 #   # Add the sub project
-#   ADD_SUBDIRECTORY (Utilities/hdf4.2.5)
+#   add_subdirectory (Utilities/hdf4.2.5)
 #   # Add the HDF4 dirs to our include path
-#   SET (HDF4_INCLUDE_DIR 
+#   set (HDF4_INCLUDE_DIR 
 #       ${PROJECT_SOURCE_DIR}/Utilities/hdf4.2.5/hdf/src
 #       ${PROJECT_BINARY_DIR}/Utilities/hdf4.2.5
 #       ${PROJECT_SOURCE_DIR}/Utilities/hdf4.2.5/mfhdf/libsrc
@@ -83,241 +83,241 @@ PROJECT (HDF4 C CXX)
 # organization feature. Default to ON for non-Express users. Express users must
 # explicitly turn off this option to build HDF5 in the Express IDE...
 #
-OPTION (HDF4_USE_FOLDERS "Enable folder grouping of projects in IDEs." ON)
-MARK_AS_ADVANCED (HDF4_USE_FOLDERS)
-IF (HDF4_USE_FOLDERS)
-  SET_PROPERTY (GLOBAL PROPERTY USE_FOLDERS ON)
-ENDIF (HDF4_USE_FOLDERS)
-OPTION (HDF4_NO_PACKAGES "CPACK - Disable packaging" OFF)
-MARK_AS_ADVANCED (HDF4_NO_PACKAGES)
+option (HDF4_USE_FOLDERS "Enable folder grouping of projects in IDEs." ON)
+mark_as_advanced (HDF4_USE_FOLDERS)
+if (HDF4_USE_FOLDERS)
+  set_property (GLOBAL PROPERTY USE_FOLDERS ON)
+endif (HDF4_USE_FOLDERS)
+option (HDF4_NO_PACKAGES "CPACK - Disable packaging" OFF)
+mark_as_advanced (HDF4_NO_PACKAGES)
 
 #-----------------------------------------------------------------------------
 # Set the core names of all the libraries
 #-----------------------------------------------------------------------------
-SET (HDF4_LIB_CORENAME              "hdf4")
-SET (HDF4_SRC_LIB_CORENAME          "hdf")
-SET (HDF4_SRC_FCSTUB_LIB_CORENAME   "hdf_fcstub")
-SET (HDF4_SRC_FORTRAN_LIB_CORENAME  "hdf_fortran")
-SET (HDF4_MF_LIB_CORENAME           "mfhdf")
-SET (HDF4_MF_XDR_LIB_CORENAME       "xdr")
-SET (HDF4_HDF_TEST_LIB_CORENAME     "hdf_test")
-SET (HDF4_HDF_TEST_FCSTUB_LIB_CORENAME     "hdf_test_fcstub")
-SET (HDF4_MF_FCSTUB_LIB_CORENAME    "mfhdf_fcstub")
-SET (HDF4_MF_FORTRAN_LIB_CORENAME   "mfhdf_fortran")
-SET (HDF4_MF_TEST_LIB_CORENAME      "mf_test")
-SET (HDF4_TOOLS_LIB_CORENAME        "h4tools")
+set (HDF4_LIB_CORENAME              "hdf4")
+set (HDF4_SRC_LIB_CORENAME          "hdf")
+set (HDF4_SRC_FCSTUB_LIB_CORENAME   "hdf_fcstub")
+set (HDF4_SRC_FORTRAN_LIB_CORENAME  "hdf_fortran")
+set (HDF4_MF_LIB_CORENAME           "mfhdf")
+set (HDF4_MF_XDR_LIB_CORENAME       "xdr")
+set (HDF4_HDF_TEST_LIB_CORENAME     "hdf_test")
+set (HDF4_HDF_TEST_FCSTUB_LIB_CORENAME     "hdf_test_fcstub")
+set (HDF4_MF_FCSTUB_LIB_CORENAME    "mfhdf_fcstub")
+set (HDF4_MF_FORTRAN_LIB_CORENAME   "mfhdf_fortran")
+set (HDF4_MF_TEST_LIB_CORENAME      "mf_test")
+set (HDF4_TOOLS_LIB_CORENAME        "h4tools")
 
 #-----------------------------------------------------------------------------
 # Set the true names of all the libraries if customized by external project
 #-----------------------------------------------------------------------------
-SET (HDF4_LIB_NAME              "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_LIB_CORENAME}")
-SET (HDF4_SRC_LIB_NAME          "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_SRC_LIB_CORENAME}")
-SET (HDF4_SRC_FCSTUB_LIB_NAME   "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_SRC_FCSTUB_LIB_CORENAME}")
-SET (HDF4_SRC_FORTRAN_LIB_NAME  "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_SRC_FORTRAN_LIB_CORENAME}")
-SET (HDF4_MF_LIB_NAME           "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_MF_LIB_CORENAME}")
-SET (HDF4_MF_XDR_LIB_NAME       "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_MF_XDR_LIB_CORENAME}")
-SET (HDF4_HDF_TEST_LIB_NAME     "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_HDF_TEST_LIB_CORENAME}")
-SET (HDF4_HDF_TEST_FCSTUB_LIB_NAME     "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_HDF_TEST_FCSTUB_LIB_CORENAME}")
-SET (HDF4_MF_FCSTUB_LIB_NAME    "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_MF_FCSTUB_LIB_CORENAME}")
-SET (HDF4_MF_FORTRAN_LIB_NAME   "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_MF_FORTRAN_LIB_CORENAME}")
-SET (HDF4_MF_TEST_LIB_NAME      "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_MF_TEST_LIB_CORENAME}")
-SET (HDF4_TOOLS_LIB_NAME        "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_TOOLS_LIB_CORENAME}")
+set (HDF4_LIB_NAME              "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_LIB_CORENAME}")
+set (HDF4_SRC_LIB_NAME          "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_SRC_LIB_CORENAME}")
+set (HDF4_SRC_FCSTUB_LIB_NAME   "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_SRC_FCSTUB_LIB_CORENAME}")
+set (HDF4_SRC_FORTRAN_LIB_NAME  "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_SRC_FORTRAN_LIB_CORENAME}")
+set (HDF4_MF_LIB_NAME           "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_MF_LIB_CORENAME}")
+set (HDF4_MF_XDR_LIB_NAME       "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_MF_XDR_LIB_CORENAME}")
+set (HDF4_HDF_TEST_LIB_NAME     "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_HDF_TEST_LIB_CORENAME}")
+set (HDF4_HDF_TEST_FCSTUB_LIB_NAME     "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_HDF_TEST_FCSTUB_LIB_CORENAME}")
+set (HDF4_MF_FCSTUB_LIB_NAME    "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_MF_FCSTUB_LIB_CORENAME}")
+set (HDF4_MF_FORTRAN_LIB_NAME   "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_MF_FORTRAN_LIB_CORENAME}")
+set (HDF4_MF_TEST_LIB_NAME      "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_MF_TEST_LIB_CORENAME}")
+set (HDF4_TOOLS_LIB_NAME        "${HDF4_EXTERNAL_LIB_PREFIX}${HDF4_TOOLS_LIB_CORENAME}")
 
 #-----------------------------------------------------------------------------
 # Set the target names of all the libraries
 #-----------------------------------------------------------------------------
-SET (HDF4_LIB_TARGET              ${HDF4_LIB_CORENAME})
-SET (HDF4_SRC_LIB_TARGET          ${HDF4_SRC_LIB_CORENAME})
-SET (HDF4_SRC_FCSTUB_LIB_TARGET   ${HDF4_SRC_FCSTUB_LIB_CORENAME})
-SET (HDF4_SRC_FORTRAN_LIB_TARGET  ${HDF4_SRC_FORTRAN_LIB_CORENAME})
-SET (HDF4_MF_LIB_TARGET           ${HDF4_MF_LIB_CORENAME})
-SET (HDF4_MF_XDR_LIB_TARGET       ${HDF4_MF_XDR_LIB_CORENAME})
-SET (HDF4_HDF_TEST_LIB_TARGET     ${HDF4_HDF_TEST_LIB_CORENAME})
-SET (HDF4_HDF_TEST_FCSTUB_LIB_TARGET     ${HDF4_HDF_TEST_FCSTUB_LIB_CORENAME})
-SET (HDF4_MF_FCSTUB_LIB_TARGET    ${HDF4_MF_FCSTUB_LIB_CORENAME})
-SET (HDF4_MF_FORTRAN_LIB_TARGET   ${HDF4_MF_FORTRAN_LIB_CORENAME})
-SET (HDF4_MF_TEST_LIB_TARGET      ${HDF4_MF_TEST_LIB_CORENAME})
-SET (HDF4_TOOLS_LIB_TARGET        ${HDF4_TOOLS_LIB_CORENAME})
+set (HDF4_LIB_TARGET              ${HDF4_LIB_CORENAME})
+set (HDF4_SRC_LIB_TARGET          ${HDF4_SRC_LIB_CORENAME})
+set (HDF4_SRC_FCSTUB_LIB_TARGET   ${HDF4_SRC_FCSTUB_LIB_CORENAME})
+set (HDF4_SRC_FORTRAN_LIB_TARGET  ${HDF4_SRC_FORTRAN_LIB_CORENAME})
+set (HDF4_MF_LIB_TARGET           ${HDF4_MF_LIB_CORENAME})
+set (HDF4_MF_XDR_LIB_TARGET       ${HDF4_MF_XDR_LIB_CORENAME})
+set (HDF4_HDF_TEST_LIB_TARGET     ${HDF4_HDF_TEST_LIB_CORENAME})
+set (HDF4_HDF_TEST_FCSTUB_LIB_TARGET     ${HDF4_HDF_TEST_FCSTUB_LIB_CORENAME})
+set (HDF4_MF_FCSTUB_LIB_TARGET    ${HDF4_MF_FCSTUB_LIB_CORENAME})
+set (HDF4_MF_FORTRAN_LIB_TARGET   ${HDF4_MF_FORTRAN_LIB_CORENAME})
+set (HDF4_MF_TEST_LIB_TARGET      ${HDF4_MF_TEST_LIB_CORENAME})
+set (HDF4_TOOLS_LIB_TARGET        ${HDF4_TOOLS_LIB_CORENAME})
 
 #-----------------------------------------------------------------------------
 # Define some CMake variables for use later in the project
 #-----------------------------------------------------------------------------
-SET (HDF4_RESOURCES_DIR       ${HDF4_SOURCE_DIR}/config/cmake)
-SET (HDF4_HDFSOURCE_DIR       ${HDF4_SOURCE_DIR}/hdf/src)
-SET (HDF4_HDF_TESTSOURCE_DIR  ${HDF4_SOURCE_DIR}/hdf/test)
-SET (HDF4_MFHDFSOURCE_DIR     ${HDF4_SOURCE_DIR}/mfhdf/libsrc)
-SET (HDF4_MFHDF_TEST_DIR      ${HDF4_SOURCE_DIR}/mfhdf/test)
-SET (HDF4_MFHDF_FORTRAN_DIR   ${HDF4_SOURCE_DIR}/mfhdf/fortran)
-SET (HDF4_MFHDF_XDR_DIR       ${HDF4_SOURCE_DIR}/mfhdf/xdr)
-
-IF (NOT HDF4_INSTALL_BIN_DIR)
-  SET (HDF4_INSTALL_BIN_DIR bin)
-  SET (HDF4_INSTALL_UTILS_BIN_DIR ${HDF4_INSTALL_BIN_DIR}) #${HDF4_INSTALL_BIN_DIR}/utils
-  SET (HDF4_INSTALL_TOOLS_BIN_DIR ${HDF4_INSTALL_BIN_DIR}) #${HDF4_INSTALL_BIN_DIR}/tools
-ENDIF (NOT HDF4_INSTALL_BIN_DIR)
-IF (NOT HDF4_INSTALL_LIB_DIR)
-  SET (HDF4_INSTALL_LIB_DIR lib)
-ENDIF (NOT HDF4_INSTALL_LIB_DIR)
-IF (NOT HDF4_INSTALL_INCLUDE_DIR)
-  SET (HDF4_INSTALL_INCLUDE_DIR include)
-ENDIF (NOT HDF4_INSTALL_INCLUDE_DIR)
-IF (NOT HDF4_INSTALL_DATA_DIR)
-  IF (NOT WIN32)
-    SET (HDF4_INSTALL_DATA_DIR share)
-    SET (HDF4_INSTALL_CMAKE_DIR share/cmake)
-  ELSE (NOT WIN32)
-    SET (HDF4_INSTALL_DATA_DIR ".")
-    SET (HDF4_INSTALL_CMAKE_DIR cmake)
-  ENDIF (NOT WIN32)
-ENDIF (NOT HDF4_INSTALL_DATA_DIR)
+set (HDF_RESOURCES_DIR        ${HDF4_SOURCE_DIR}/config/cmake)
+set (HDF_RESOURCES_EXT_DIR    ${HDF4_SOURCE_DIR}/config/cmake_ext_mod)
+set (HDF4_HDFSOURCE_DIR       ${HDF4_SOURCE_DIR}/hdf/src)
+set (HDF4_HDF_TESTSOURCE_DIR  ${HDF4_SOURCE_DIR}/hdf/test)
+set (HDF4_MFHDFSOURCE_DIR     ${HDF4_SOURCE_DIR}/mfhdf/libsrc)
+set (HDF4_MFHDF_TEST_DIR      ${HDF4_SOURCE_DIR}/mfhdf/test)
+set (HDF4_MFHDF_FORTRAN_DIR   ${HDF4_SOURCE_DIR}/mfhdf/fortran)
+set (HDF4_MFHDF_XDR_DIR       ${HDF4_SOURCE_DIR}/mfhdf/xdr)
+
+if (NOT HDF4_INSTALL_BIN_DIR)
+  set (HDF4_INSTALL_BIN_DIR bin)
+  set (HDF4_INSTALL_UTILS_BIN_DIR ${HDF4_INSTALL_BIN_DIR}) #${HDF4_INSTALL_BIN_DIR}/utils
+  set (HDF4_INSTALL_TOOLS_BIN_DIR ${HDF4_INSTALL_BIN_DIR}) #${HDF4_INSTALL_BIN_DIR}/tools
+endif (NOT HDF4_INSTALL_BIN_DIR)
+if (NOT HDF4_INSTALL_LIB_DIR)
+  set (HDF4_INSTALL_LIB_DIR lib)
+endif (NOT HDF4_INSTALL_LIB_DIR)
+if (NOT HDF4_INSTALL_INCLUDE_DIR)
+  set (HDF4_INSTALL_INCLUDE_DIR include)
+endif (NOT HDF4_INSTALL_INCLUDE_DIR)
+if (NOT HDF4_INSTALL_DATA_DIR)
+  if (NOT WIN32)
+    set (HDF4_INSTALL_DATA_DIR share)
+    set (HDF4_INSTALL_CMAKE_DIR share/cmake)
+  else (NOT WIN32)
+    set (HDF4_INSTALL_DATA_DIR ".")
+    set (HDF4_INSTALL_CMAKE_DIR cmake)
+  endif (NOT WIN32)
+endif (NOT HDF4_INSTALL_DATA_DIR)
 
 #-----------------------------------------------------------------------------
 # parse the full version number from hfile.h and include in H4_VERS_INFO
 #-----------------------------------------------------------------------------
-FILE (READ ${HDF4_HDFSOURCE_DIR}/hfile.h _hfile_h_contents)
-STRING (REGEX REPLACE ".*#define[ \t]+LIBVER_MAJOR[ \t]+([0-9]*).*$"
+file (READ ${HDF4_HDFSOURCE_DIR}/hfile.h _hfile_h_contents)
+string (REGEX REPLACE ".*#define[ \t]+LIBVER_MAJOR[ \t]+([0-9]*).*$"
     "\\1" H4_VERS_MAJOR ${_hfile_h_contents})
-STRING (REGEX REPLACE ".*#define[ \t]+LIBVER_MINOR[ \t]+([0-9]*).*$"
+string (REGEX REPLACE ".*#define[ \t]+LIBVER_MINOR[ \t]+([0-9]*).*$"
     "\\1" H4_VERS_MINOR ${_hfile_h_contents})
-STRING (REGEX REPLACE ".*#define[ \t]+LIBVER_RELEASE[ \t]+([0-9]*).*$"
+string (REGEX REPLACE ".*#define[ \t]+LIBVER_RELEASE[ \t]+([0-9]*).*$"
     "\\1" H4_VERS_RELEASE ${_hfile_h_contents})
-STRING (REGEX REPLACE ".*#define[ \t]+LIBVER_SUBRELEASE[ \t]+\"([0-9A-Za-z.]*)\".*$"
+string (REGEX REPLACE ".*#define[ \t]+LIBVER_SUBRELEASE[ \t]+\"([0-9A-Za-z.]*)\".*$"
     "\\1" H4_VERS_SUBRELEASE ${_hfile_h_contents})
-#MESSAGE (STATUS "VERSION: ${H4_VERS_MAJOR}.${H4_VERS_MINOR}.${H4_VERS_RELEASE}-${H4_VERS_SUBRELEASE}")
+#message (STATUS "VERSION: ${H4_VERS_MAJOR}.${H4_VERS_MINOR}.${H4_VERS_RELEASE}-${H4_VERS_SUBRELEASE}")
 
 #-----------------------------------------------------------------------------
 # Basic HDF4 stuff here
 #-----------------------------------------------------------------------------
-SET (HDF4_PACKAGE "hdf4")
-SET (HDF4_PACKAGE_NAME "HDF")
-SET (HDF4_PACKAGE_VERSION "${H4_VERS_MAJOR}.${H4_VERS_MINOR}.${H4_VERS_RELEASE}")
-SET (HDF4_PACKAGE_VERSION_MAJOR "${H4_VERS_MAJOR}.${H4_VERS_MINOR}")
-SET (HDF4_PACKAGE_VERSION_MINOR "${H4_VERS_RELEASE}")
-SET (HDF4_PACKAGE_VERSION_STRING "${HDF4_PACKAGE_VERSION}-${H4_VERS_SUBRELEASE}")
-SET (HDF4_PACKAGE_STRING "${HDF4_PACKAGE_NAME} ${HDF4_PACKAGE_VERSION_STRING}")
-SET (HDF5_PACKAGE_TARNAME "${HDF4_PACKAGE}${HDF_PACKAGE_EXT}")
-SET (HDF4_PACKAGE_URL "http://www.hdfgroup.org")
-SET (HDF4_PACKAGE_BUGREPORT "help at hdfgroup.org")
+set (HDF4_PACKAGE "hdf4")
+set (HDF4_PACKAGE_NAME "HDF")
+set (HDF4_PACKAGE_VERSION "${H4_VERS_MAJOR}.${H4_VERS_MINOR}.${H4_VERS_RELEASE}")
+set (HDF4_PACKAGE_VERSION_MAJOR "${H4_VERS_MAJOR}.${H4_VERS_MINOR}")
+set (HDF4_PACKAGE_VERSION_MINOR "${H4_VERS_RELEASE}")
+set (HDF4_PACKAGE_VERSION_STRING "${HDF4_PACKAGE_VERSION}")
+if (NOT "${H4_VERS_SUBRELEASE}" STREQUAL "")
+  set (HDF4_PACKAGE_VERSION_STRING "${HDF4_PACKAGE_VERSION_STRING}-${H4_VERS_SUBRELEASE}")
+endif (NOT "${H4_VERS_SUBRELEASE}" STREQUAL "")
+set (HDF4_PACKAGE_STRING "${HDF4_PACKAGE_NAME} ${HDF4_PACKAGE_VERSION_STRING}")
+set (HDF4_PACKAGE_TARNAME "${HDF4_PACKAGE}${HDF_PACKAGE_EXT}")
+set (HDF4_PACKAGE_URL "http://www.hdfgroup.org")
+set (HDF4_PACKAGE_BUGREPORT "help at hdfgroup.org")
 
 #-----------------------------------------------------------------------------
 # Include some macros for reusable code
 #-----------------------------------------------------------------------------
-INCLUDE (${HDF4_RESOURCES_DIR}/HDFMacros.cmake)
-INCLUDE (${HDF4_RESOURCES_DIR}/HDFLibMacros.cmake)
-INCLUDE (${HDF4_RESOURCES_DIR}/HDF4Macros.cmake)
+include (${HDF_RESOURCES_EXT_DIR}/HDFMacros.cmake)
+include (${HDF_RESOURCES_EXT_DIR}/HDFLibMacros.cmake)
+include (${HDF_RESOURCES_DIR}/HDF4Macros.cmake)
 
 #-----------------------------------------------------------------------------
 # Setup output Directories
 #-----------------------------------------------------------------------------
-IF (NOT HDF4_EXTERNALLY_CONFIGURED)
-  SET (CMAKE_RUNTIME_OUTPUT_DIRECTORY
+if (NOT HDF4_EXTERNALLY_CONFIGURED)
+  set (CMAKE_RUNTIME_OUTPUT_DIRECTORY
       ${PROJECT_BINARY_DIR}/bin CACHE PATH "Single Directory for all Executables."
   )
-  SET (CMAKE_LIBRARY_OUTPUT_DIRECTORY
+  set (CMAKE_LIBRARY_OUTPUT_DIRECTORY
       ${PROJECT_BINARY_DIR}/bin CACHE PATH "Single Directory for all Libraries"
   )
-  SET (CMAKE_ARCHIVE_OUTPUT_DIRECTORY
+  set (CMAKE_ARCHIVE_OUTPUT_DIRECTORY
       ${PROJECT_BINARY_DIR}/bin CACHE PATH "Single Directory for all static libraries."
   )
-  SET (CMAKE_Fortran_MODULE_DIRECTORY
+  set (CMAKE_Fortran_MODULE_DIRECTORY
       ${PROJECT_BINARY_DIR}/bin/fortran CACHE PATH "Single Directory for all fortran modules."
   )
-ELSE (NOT HDF4_EXTERNALLY_CONFIGURED)
+else (NOT HDF4_EXTERNALLY_CONFIGURED)
   # if we are externally configured, but the project uses old cmake scripts
   # this may not be set and utilities like Hdetect will fail
-  IF (NOT CMAKE_RUNTIME_OUTPUT_DIRECTORY)
-    SET (CMAKE_RUNTIME_OUTPUT_DIRECTORY ${EXECUTABLE_OUTPUT_PATH})
-  ENDIF (NOT CMAKE_RUNTIME_OUTPUT_DIRECTORY)
-ENDIF (NOT HDF4_EXTERNALLY_CONFIGURED)
+  if (NOT CMAKE_RUNTIME_OUTPUT_DIRECTORY)
+    set (CMAKE_RUNTIME_OUTPUT_DIRECTORY ${EXECUTABLE_OUTPUT_PATH})
+  endif (NOT CMAKE_RUNTIME_OUTPUT_DIRECTORY)
+endif (NOT HDF4_EXTERNALLY_CONFIGURED)
 
 #-----------------------------------------------------------------------------
 # Targets built within this project are exported at Install time for use
 # by other projects using FindHDF4.
 #-----------------------------------------------------------------------------
-IF (NOT HDF4_EXPORTED_TARGETS)
-  SET (HDF4_EXPORTED_TARGETS "hdf4-targets")
-ENDIF (NOT HDF4_EXPORTED_TARGETS)
+if (NOT HDF4_EXPORTED_TARGETS)
+  set (HDF4_EXPORTED_TARGETS "hdf4-targets")
+endif (NOT HDF4_EXPORTED_TARGETS)
 
 #-----------------------------------------------------------------------------
 # To include a library in the list exported by the project AT BUILD TIME,
 # add it to this variable. This is NOT used by Make Install, but for projects
 # which include hdf4 as a sub-project within their build tree
 #-----------------------------------------------------------------------------
-SET_GLOBAL_VARIABLE (HDF4_LIBRARIES_TO_EXPORT "")
-SET (EXTERNAL_HEADER_LIST "")
-SET (EXTERNAL_LIBRARY_LIST "")
-SET (EXTERNAL_LIBRARYDLL_LIST "")
+set_global_variable (HDF4_LIBRARIES_TO_EXPORT "")
+set (EXTERNAL_HEADER_LIST "")
+set (EXTERNAL_LIBRARY_LIST "")
+set (EXTERNAL_LIBRARYDLL_LIST "")
 
 #-----------------------------------------------------------------------------
 # Run all the CMake configuration tests for our build environment
 #-----------------------------------------------------------------------------
-INCLUDE (${HDF4_RESOURCES_DIR}/ConfigureChecks.cmake)
+include (${HDF_RESOURCES_DIR}/ConfigureChecks.cmake)
+
+set (CMAKE_INCLUDE_CURRENT_DIR_IN_INTERFACE ON)
 
 #-----------------------------------------------------------------------------
 # Option to Build Shared/Static libs, default is static
 #-----------------------------------------------------------------------------
-OPTION (BUILD_SHARED_LIBS "Build Shared Libraries" OFF)
-SET (LIB_TYPE STATIC)
-SET (H4_ENABLE_SHARED_LIB NO)
-SET (H4_ENABLE_STATIC_LIB NO)
-IF (BUILD_SHARED_LIBS)
-  SET (LIB_TYPE SHARED)
-  SET (H4_BUILT_AS_DYNAMIC_LIB 1)
-  SET (H4_ENABLE_SHARED_LIB YES)
-ELSE (BUILD_SHARED_LIBS)
-  SET (H4_BUILT_AS_STATIC_LIB 1)
-  SET (H4_ENABLE_STATIC_LIB YES)
-  IF (NOT WIN32)
-    # should this be a user setting : Everyone uses it anyway ?
-    ADD_DEFINITIONS (-DPIC)
-    IF (${CMAKE_SYSTEM_NAME} MATCHES "SunOS")
-      ADD_DEFINITIONS (-KPIC)
-    ENDIF (${CMAKE_SYSTEM_NAME} MATCHES "SunOS")
-  ENDIF (NOT WIN32)
-ENDIF (BUILD_SHARED_LIBS)
-
-ADD_DEFINITIONS (-DBIG_LONGS -DSWAP)
-ADD_DEFINITIONS (-DHAVE_CONFIG_H)
+option (BUILD_SHARED_LIBS "Build Shared Libraries" OFF)
+set (LIB_TYPE STATIC)
+set (H4_ENABLE_SHARED_LIB NO)
+set (H4_ENABLE_STATIC_LIB NO)
+if (BUILD_SHARED_LIBS)
+  set (LIB_TYPE SHARED)
+  set (H4_BUILT_AS_DYNAMIC_LIB 1)
+  set (H4_ENABLE_SHARED_LIB YES)
+else (BUILD_SHARED_LIBS)
+  set (H4_BUILT_AS_STATIC_LIB 1)
+  set (H4_ENABLE_STATIC_LIB YES)
+  set (CMAKE_POSITION_INDEPENDENT_CODE ON)
+endif (BUILD_SHARED_LIBS)
+
+add_definitions (-DBIG_LONGS -DSWAP)
+add_definitions (-DHAVE_CONFIG_H)
 
 #-----------------------------------------------------------------------------
 # Temporary disable optimization flag
 #-----------------------------------------------------------------------------
-IF(${CMAKE_SYSTEM_NAME} MATCHES "Darwin" OR CYGWIN)
-  FOREACH (flag_var
+if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin" OR CYGWIN)
+  foreach (flag_var
       CMAKE_C_FLAGS CMAKE_C_FLAGS_DEBUG CMAKE_C_FLAGS_RELEASE
       CMAKE_C_FLAGS_MINSIZEREL CMAKE_C_FLAGS_RELWITHDEBINFO
       CMAKE_CXX_FLAGS CMAKE_CXX_FLAGS_DEBUG CMAKE_CXX_FLAGS_RELEASE
       CMAKE_CXX_FLAGS_MINSIZEREL CMAKE_CXX_FLAGS_RELWITHDEBINFO)
-    IF (${flag_var} MATCHES "O3")
-      STRING (REGEX REPLACE "O3" "O0" ${flag_var} "${${flag_var}}")
-    ENDIF (${flag_var} MATCHES "O3")
-  ENDFOREACH (flag_var)
-ENDIF (${CMAKE_SYSTEM_NAME} MATCHES "Darwin" OR CYGWIN)
+    if (${flag_var} MATCHES "O3")
+      string (REGEX REPLACE "O3" "O0" ${flag_var} "${${flag_var}}")
+    endif (${flag_var} MATCHES "O3")
+  endforeach (flag_var)
+endif (${CMAKE_SYSTEM_NAME} MATCHES "Darwin" OR CYGWIN)
 
 #-----------------------------------------------------------------------------
 # Option to use code coverage
 #-----------------------------------------------------------------------------
-OPTION (HDF4_ENABLE_COVERAGE "Enable code coverage for Libraries and Programs" OFF)
-IF (HDF4_ENABLE_COVERAGE)
-    SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -g -O0 -fprofile-arcs -ftest-coverage")
-    SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -O0 -fprofile-arcs -ftest-coverage")
-    SET (LDFLAGS "${LDFLAGS} -fprofile-arcs -ftest-coverage")   
-ENDIF (HDF4_ENABLE_COVERAGE)
+option (HDF4_ENABLE_COVERAGE "Enable code coverage for Libraries and Programs" OFF)
+if (HDF4_ENABLE_COVERAGE)
+    set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -g -O0 -fprofile-arcs -ftest-coverage")
+    set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -g -O0 -fprofile-arcs -ftest-coverage")
+    set (LDFLAGS "${LDFLAGS} -fprofile-arcs -ftest-coverage")   
+endif (HDF4_ENABLE_COVERAGE)
 
 #-----------------------------------------------------------------------------
 # Option to use deprecated public API symbols
 #-----------------------------------------------------------------------------
-OPTION (HDF4_ENABLE_DEPRECATED_SYMBOLS "Enable deprecated public API symbols" ON)
-IF (HDF4_ENABLE_DEPRECATED_SYMBOLS)
-  SET (H4_NO_DEPRECATED_SYMBOLS 0)   
-ELSE (HDF4_ENABLE_DEPRECATED_SYMBOLS)
-  SET (H4_NO_DEPRECATED_SYMBOLS 1)   
-ENDIF (HDF4_ENABLE_DEPRECATED_SYMBOLS)
+option (HDF4_ENABLE_DEPRECATED_SYMBOLS "Enable deprecated public API symbols" ON)
+if (HDF4_ENABLE_DEPRECATED_SYMBOLS)
+  set (H4_NO_DEPRECATED_SYMBOLS 0)   
+else (HDF4_ENABLE_DEPRECATED_SYMBOLS)
+  set (H4_NO_DEPRECATED_SYMBOLS 1)   
+endif (HDF4_ENABLE_DEPRECATED_SYMBOLS)
 
 #-----------------------------------------------------------------------------
 # Include the main src and config directories
 #-----------------------------------------------------------------------------
-SET (HDF4_INCLUDE_DIRECTORIES
+set (HDF4_INCLUDE_DIRECTORIES
     ${HDF4_HDFSOURCE_DIR} 
     ${HDF4_MFHDFSOURCE_DIR} 
     ${HDF4_SOURCE_DIR} 
@@ -332,215 +332,215 @@ INCLUDE_DIRECTORIES (${HDF4_INCLUDE_DIRECTORIES} )
 # Certain systems may add /Debug or /Release to output paths
 # and we need to call the executable from inside the CMake configuration
 #-----------------------------------------------------------------------------
-SET (EXE_EXT "")
-IF (WIN32)
-  SET (EXE_EXT ".exe")
-  IF (NOT CYGWIN)
-    ADD_DEFINITIONS (-D_BIND_TO_CURRENT_VCLIBS_VERSION=1)
-    ADD_DEFINITIONS (-D_CRT_SECURE_NO_WARNINGS)
-    ADD_DEFINITIONS (-D_CONSOLE)
-  ENDIF (NOT CYGWIN)
-ENDIF (WIN32)
-
-IF (MSVC)
-  SET (CMAKE_MFC_FLAG 0)
-  SET (WIN_COMPILE_FLAGS "")
-  SET (WIN_LINK_FLAGS "")
-ENDIF (MSVC)
-
-SET (MAKE_SYSTEM)
-IF (CMAKE_BUILD_TOOL MATCHES "make")
-  SET (MAKE_SYSTEM 1)
-ENDIF (CMAKE_BUILD_TOOL MATCHES "make")
-
-SET (CFG_INIT "/${CMAKE_CFG_INTDIR}")
-IF (MAKE_SYSTEM)
-  SET (CFG_INIT "")
-ENDIF (MAKE_SYSTEM)
+set (EXE_EXT "")
+if (WIN32)
+  set (EXE_EXT ".exe")
+  if (NOT CYGWIN)
+    add_definitions (-D_BIND_TO_CURRENT_VCLIBS_VERSION=1)
+    add_definitions (-D_CRT_SECURE_NO_WARNINGS)
+    add_definitions (-D_CONSOLE)
+  endif (NOT CYGWIN)
+endif (WIN32)
+
+if (MSVC)
+  set (CMAKE_MFC_FLAG 0)
+  set (WIN_COMPILE_FLAGS "")
+  set (WIN_LINK_FLAGS "")
+endif (MSVC)
+
+set (MAKE_SYSTEM)
+if (CMAKE_BUILD_TOOL MATCHES "make")
+  set (MAKE_SYSTEM 1)
+endif (CMAKE_BUILD_TOOL MATCHES "make")
+
+set (CFG_INIT "/${CMAKE_CFG_INTDIR}")
+if (MAKE_SYSTEM)
+  set (CFG_INIT "")
+endif (MAKE_SYSTEM)
 
 #-----------------------------------------------------------------------------
 # Add some definitions for Debug Builds
 #-----------------------------------------------------------------------------
-IF (CMAKE_BUILD_TYPE MATCHES Debug)
+if (CMAKE_BUILD_TYPE MATCHES Debug)
   #-- NMake Makefiles will overwhelm the console with warnings if -Wall is used.
-  IF (NOT WIN32)
-    ADD_DEFINITIONS (-Wall)
-  ENDIF (NOT WIN32)
-ENDIF (CMAKE_BUILD_TYPE MATCHES Debug)
+  if (NOT WIN32)
+    add_definitions (-Wall)
+  endif (NOT WIN32)
+endif (CMAKE_BUILD_TYPE MATCHES Debug)
 
 #-----------------------------------------------------------------------------
 # Compiler specific flags : Shouldn't there be compiler tests for these
 #-----------------------------------------------------------------------------
-IF (CMAKE_COMPILER_IS_GNUCC)
-  IF (CMAKE_BUILD_TYPE MATCHES Debug)
-    SET (CMAKE_C_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_C_FLAGS} -std=c99 -finline-functions -fno-common")
-  ELSE (CMAKE_BUILD_TYPE MATCHES Debug)
-    SET (CMAKE_C_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_C_FLAGS} -std=c99 -fomit-frame-pointer -finline-functions -fno-common")
-  ENDIF (CMAKE_BUILD_TYPE MATCHES Debug)
-ENDIF (CMAKE_COMPILER_IS_GNUCC)
-IF (CMAKE_COMPILER_IS_GNUCXX)
-  IF (CMAKE_BUILD_TYPE MATCHES Debug)
-    SET (CMAKE_CXX_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_CXX_FLAGS} -finline-functions -fno-common")
-  ELSE (CMAKE_BUILD_TYPE MATCHES Debug)
-    SET (CMAKE_CXX_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_CXX_FLAGS} -fomit-frame-pointer -finline-functions -fno-common")
-  ENDIF (CMAKE_BUILD_TYPE MATCHES Debug)
-ENDIF (CMAKE_COMPILER_IS_GNUCXX)
+if (CMAKE_COMPILER_IS_GNUCC)
+  if (CMAKE_BUILD_TYPE MATCHES Debug)
+    set (CMAKE_C_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_C_FLAGS} -std=c99 -finline-functions -fno-common")
+  else (CMAKE_BUILD_TYPE MATCHES Debug)
+    set (CMAKE_C_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_C_FLAGS} -std=c99 -fomit-frame-pointer -finline-functions -fno-common")
+  endif (CMAKE_BUILD_TYPE MATCHES Debug)
+endif (CMAKE_COMPILER_IS_GNUCC)
+if (CMAKE_COMPILER_IS_GNUCXX)
+  if (CMAKE_BUILD_TYPE MATCHES Debug)
+    set (CMAKE_CXX_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_CXX_FLAGS} -finline-functions -fno-common")
+  else (CMAKE_BUILD_TYPE MATCHES Debug)
+    set (CMAKE_CXX_FLAGS "${CMAKE_ANSI_CFLAGS} ${CMAKE_CXX_FLAGS} -fomit-frame-pointer -finline-functions -fno-common")
+  endif (CMAKE_BUILD_TYPE MATCHES Debug)
+endif (CMAKE_COMPILER_IS_GNUCXX)
 
 #-----------------------------------------------------------------------------
 # Option to allow the user to disable compiler warnings
 #-----------------------------------------------------------------------------
-OPTION (HDF4_DISABLE_COMPILER_WARNINGS "Disable compiler warnings" OFF)
-IF (HDF4_DISABLE_COMPILER_WARNINGS)
+option (HDF4_DISABLE_COMPILER_WARNINGS "Disable compiler warnings" OFF)
+if (HDF4_DISABLE_COMPILER_WARNINGS)
   # MSVC uses /w to suppress warnings.  It also complains if another
   # warning level is given, so remove it.
-  IF (MSVC)
-    SET (HDF4_WARNINGS_BLOCKED 1)
-    STRING (REGEX REPLACE "(^| )([/-])W[0-9]( |$)" " " CMAKE_C_FLAGS "${CMAKE_C_FLAGS}")
-    SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /w")
-    STRING (REGEX REPLACE "(^| )([/-])W[0-9]( |$)" " " CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
-    SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /w")
-  ENDIF (MSVC)
-  IF (WIN32 AND NOT CYGWIN)
-    ADD_DEFINITIONS (-D_CRT_SECURE_NO_WARNINGS)
-  ENDIF (WIN32 AND NOT CYGWIN)
+  if (MSVC)
+    set (HDF4_WARNINGS_BLOCKED 1)
+    string (REGEX REPLACE "(^| )([/-])W[0-9]( |$)" " " CMAKE_C_FLAGS "${CMAKE_C_FLAGS}")
+    set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} /w")
+    string (REGEX REPLACE "(^| )([/-])W[0-9]( |$)" " " CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}")
+    set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /w")
+  endif (MSVC)
+  if (WIN32)
+    add_definitions (-D_CRT_SECURE_NO_WARNINGS)
+  endif (WIN32)
   # Borland uses -w- to suppress warnings.
-  IF (BORLAND)
-    SET (HDF4_WARNINGS_BLOCKED 1)
-    SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -w-")
-  ENDIF (BORLAND)
+  if (BORLAND)
+    set (HDF4_WARNINGS_BLOCKED 1)
+    set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -w-")
+  endif (BORLAND)
 
   # Most compilers use -w to suppress warnings.
-  IF (NOT HDF4_WARNINGS_BLOCKED)
-    SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -w")
-    SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -w")
-  ENDIF (NOT HDF4_WARNINGS_BLOCKED)
-ENDIF (HDF4_DISABLE_COMPILER_WARNINGS)
+  if (NOT HDF4_WARNINGS_BLOCKED)
+    set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -w")
+    set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -w")
+  endif (NOT HDF4_WARNINGS_BLOCKED)
+endif (HDF4_DISABLE_COMPILER_WARNINGS)
 
 #-----------------------------------------------------------------------------
 # This is in here to help some of the GCC based IDES like Eclipse
 # and code blocks parse the compiler errors and warnings better.
 #-----------------------------------------------------------------------------
-IF (CMAKE_COMPILER_IS_GNUCC)
-  SET (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fmessage-length=0")
-ENDIF (CMAKE_COMPILER_IS_GNUCC)
-IF (CMAKE_COMPILER_IS_GNUCXX)
-  SET (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fmessage-length=0")
-ENDIF (CMAKE_COMPILER_IS_GNUCXX)
+if (CMAKE_COMPILER_IS_GNUCC)
+  set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fmessage-length=0")
+endif (CMAKE_COMPILER_IS_GNUCC)
+if (CMAKE_COMPILER_IS_GNUCXX)
+  set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fmessage-length=0")
+endif (CMAKE_COMPILER_IS_GNUCXX)
 
 #-----------------------------------------------------------------------------
 # Option to Enable MPI Parallel
 #-----------------------------------------------------------------------------
-SET (CMAKE_MODULE_PATH ${HDF4_RESOURCES_DIR} ${CMAKE_MODULE_PATH})
-OPTION (HDF4_ENABLE_PARALLEL "Enable parallel build (requires MPI)" OFF)
-IF (HDF4_ENABLE_PARALLEL)
-  INCLUDE (FindMPI)
+set (CMAKE_MODULE_PATH ${HDF_RESOURCES_DIR} ${HDF_RESOURCES_EXT_DIR} ${CMAKE_MODULE_PATH})
+option (HDF4_ENABLE_PARALLEL "Enable parallel build (requires MPI)" OFF)
+if (HDF4_ENABLE_PARALLEL)
+  include (FindMPI)
   INCLUDE_DIRECTORIES (${MPI_C_INCLUDE_PATH})
-  IF (MPI_C_FOUND)
-    SET (H4_HAVE_PARALLEL 1)
+  if (MPI_C_FOUND)
+    set (H4_HAVE_PARALLEL 1)
     # MPI checks, only do these if MPI_C_FOUND is true, otherwise they always fail
     # and once set, they are cached as false and not regenerated
-    SET (CMAKE_REQUIRED_LIBRARIES "${MPI_C_LIBRARIES}" )
+    set (CMAKE_REQUIRED_LIBRARIES "${MPI_C_LIBRARIES}" )
     CHECK_FUNCTION_EXISTS (MPI_File_get_size H4_HAVE_MPI_GET_SIZE) 
     # Used by Fortran + MPI
     CHECK_SYMBOL_EXISTS (MPI_Comm_c2f "${MPI_C_INCLUDE_PATH}/mpi.h"  H4_HAVE_MPI_MULTI_LANG_Comm)
     CHECK_SYMBOL_EXISTS (MPI_Info_c2f "${MPI_C_INCLUDE_PATH}/mpi.h"  H4_HAVE_MPI_MULTI_LANG_Info)
-  ELSE (MPI_C_FOUND)
-    MESSAGE (STATUS "Parallel libraries not found")
-  ENDIF (MPI_C_FOUND)
-ENDIF (HDF4_ENABLE_PARALLEL)
+  else (MPI_C_FOUND)
+    message (STATUS "Parallel libraries not found")
+  endif (MPI_C_FOUND)
+endif (HDF4_ENABLE_PARALLEL)
 
 # Parallel IO usage requires MPI to be Linked and Included
-IF (H4_HAVE_PARALLEL)
-  SET (LINK_LIBS ${LINK_LIBS} ${MPI_C_LIBRARIES})
-  IF (MPI_C_LINK_FLAGS)
-    SET (CMAKE_EXE_LINKER_FLAGS ${MPI_C_LINK_FLAGS} ${CMAKE_EXE_LINKER_FLAGS})
-  ENDIF (MPI_C_LINK_FLAGS)
-ENDIF (H4_HAVE_PARALLEL)
+if (H4_HAVE_PARALLEL)
+  set (LINK_LIBS ${LINK_LIBS} ${MPI_C_LIBRARIES})
+  if (MPI_C_LINK_FLAGS)
+    set (CMAKE_EXE_LINKER_FLAGS "${MPI_C_LINK_FLAGS} ${CMAKE_EXE_LINKER_FLAGS}")
+  endif (MPI_C_LINK_FLAGS)
+endif (H4_HAVE_PARALLEL)
 
 #-----------------------------------------------------------------------------
 # Include user macros
 #-----------------------------------------------------------------------------
-INCLUDE (UserMacros.cmake)
+include (UserMacros.cmake)
 
-INCLUDE (CMakeFilters.cmake)
+include (CMakeFilters.cmake)
 
 #-----------------------------------------------------------------------------
 # Option for external libraries on windows
 #-----------------------------------------------------------------------------
-OPTION (HDF4_PACKAGE_EXTLIBS "CPACK - include external libraries" OFF)
-IF (NOT HDF4_EXTERNALLY_CONFIGURED)
-  IF (HDF4_PACKAGE_EXTLIBS)
-    SET (HDF4_NO_PACKAGES OFF CACHE BOOL "CPACK - Disable packaging" FORCE)
-    IF (HDF4_ENABLE_JPEG_LIB_SUPPORT AND JPEG_FOUND)
+option (HDF4_PACKAGE_EXTLIBS "CPACK - include external libraries" OFF)
+if (NOT HDF4_EXTERNALLY_CONFIGURED)
+  if (HDF4_PACKAGE_EXTLIBS)
+    set (HDF4_NO_PACKAGES OFF CACHE BOOL "CPACK - Disable packaging" FORCE)
+    if (HDF4_ENABLE_JPEG_LIB_SUPPORT AND JPEG_FOUND)
       PACKAGE_JPEG_LIBRARY (${HDF4_ALLOW_EXTERNAL_SUPPORT})
-    ENDIF (HDF4_ENABLE_JPEG_LIB_SUPPORT AND JPEG_FOUND)
+    endif (HDF4_ENABLE_JPEG_LIB_SUPPORT AND JPEG_FOUND)
 
-    IF (HDF4_ENABLE_Z_LIB_SUPPORT AND ZLIB_FOUND)
+    if (HDF4_ENABLE_Z_LIB_SUPPORT AND ZLIB_FOUND)
       PACKAGE_ZLIB_LIBRARY (${HDF4_ALLOW_EXTERNAL_SUPPORT})
-    ENDIF (HDF4_ENABLE_Z_LIB_SUPPORT AND ZLIB_FOUND)
+    endif (HDF4_ENABLE_Z_LIB_SUPPORT AND ZLIB_FOUND)
     
-    IF (HDF4_ENABLE_SZIP_SUPPORT AND SZIP_FOUND)
+    if (HDF4_ENABLE_SZIP_SUPPORT AND SZIP_FOUND)
       PACKAGE_SZIP_LIBRARY (${HDF4_ALLOW_EXTERNAL_SUPPORT})
-    ENDIF (HDF4_ENABLE_SZIP_SUPPORT AND SZIP_FOUND)
-  ENDIF (HDF4_PACKAGE_EXTLIBS)
-ENDIF (NOT HDF4_EXTERNALLY_CONFIGURED)
+    endif (HDF4_ENABLE_SZIP_SUPPORT AND SZIP_FOUND)
+  endif (HDF4_PACKAGE_EXTLIBS)
+endif (NOT HDF4_EXTERNALLY_CONFIGURED)
 
 #-----------------------------------------------------------------------------
 # Option to build HDF4 xdr Library
 #-----------------------------------------------------------------------------
-OPTION (HDF4_BUILD_XDR_LIB  "Build HDF4 XDR Library" OFF)
-IF (WIN32 AND NOT CYGWIN)
-  SET (HDF4_BUILD_XDR_LIB ON CACHE BOOL "Build HDF4 XDR Library" FORCE)
-ENDIF (WIN32 AND NOT CYGWIN)
+option (HDF4_BUILD_XDR_LIB  "Build HDF4 XDR Library" OFF)
+if (WIN32 AND NOT MINGW)
+  set (HDF4_BUILD_XDR_LIB ON CACHE BOOL "Build HDF4 XDR Library" FORCE)
+endif (WIN32 AND NOT MINGW)
 
-IF (HDF4_BUILD_XDR_LIB)
-  ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/mfhdf/xdr ${PROJECT_BINARY_DIR}/xdr)
-ENDIF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
+  add_subdirectory (${HDF4_SOURCE_DIR}/mfhdf/xdr ${PROJECT_BINARY_DIR}/xdr)
+endif (HDF4_BUILD_XDR_LIB)
 
 #-----------------------------------------------------------------------------
 # Add the HDF4 Library Target to the build
 #-----------------------------------------------------------------------------
-ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/hdf/src    ${PROJECT_BINARY_DIR}/hdf/src )
-ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/mfhdf/libsrc   ${PROJECT_BINARY_DIR}/mfhdf/libsrc)
+add_subdirectory (${HDF4_SOURCE_DIR}/hdf/src    ${PROJECT_BINARY_DIR}/hdf/src )
+add_subdirectory (${HDF4_SOURCE_DIR}/mfhdf/libsrc   ${PROJECT_BINARY_DIR}/mfhdf/libsrc)
 
-IF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
-  IF (JPEG_FOUND AND JPEG_USE_EXTERNAL)
-    ADD_DEPENDENCIES (${HDF4_SRC_LIB_TARGET} JPEG)
-  ENDIF (JPEG_FOUND AND JPEG_USE_EXTERNAL)
-  IF (ZLIB_FOUND AND ZLIB_USE_EXTERNAL)
-    ADD_DEPENDENCIES (${HDF4_SRC_LIB_TARGET} ZLIB)
-  ENDIF (ZLIB_FOUND AND ZLIB_USE_EXTERNAL)
-  IF (SZIP_FOUND AND SZIP_USE_EXTERNAL)
-    ADD_DEPENDENCIES (${HDF4_SRC_LIB_TARGET} SZIP)
-  ENDIF (SZIP_FOUND AND SZIP_USE_EXTERNAL)
-ENDIF (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+if (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
+  if (JPEG_FOUND AND JPEG_USE_EXTERNAL)
+    add_dependencies (${HDF4_SRC_LIB_TARGET} JPEG)
+  endif (JPEG_FOUND AND JPEG_USE_EXTERNAL)
+  if (ZLIB_FOUND AND ZLIB_USE_EXTERNAL)
+    add_dependencies (${HDF4_SRC_LIB_TARGET} ZLIB)
+  endif (ZLIB_FOUND AND ZLIB_USE_EXTERNAL)
+  if (SZIP_FOUND AND SZIP_USE_EXTERNAL)
+    add_dependencies (${HDF4_SRC_LIB_TARGET} SZIP)
+  endif (SZIP_FOUND AND SZIP_USE_EXTERNAL)
+endif (HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "SVN" OR HDF4_ALLOW_EXTERNAL_SUPPORT MATCHES "TGZ")
 
-IF (HDF4_BUILD_XDR_LIB)
-  ADD_DEPENDENCIES (${HDF4_MF_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET})
-ENDIF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
+  add_dependencies (${HDF4_MF_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET})
+endif (HDF4_BUILD_XDR_LIB)
 
 #-----------------------------------------------------------------------------
 # Dashboard and Testing Settings
 #-----------------------------------------------------------------------------
-OPTION (BUILD_TESTING "Build HDF4 Unit Testing" OFF)
-IF (BUILD_TESTING)
-  SET (DART_TESTING_TIMEOUT 1200
+option (BUILD_TESTING "Build HDF4 Unit Testing" OFF)
+if (BUILD_TESTING)
+  set (DART_TESTING_TIMEOUT 1200
       CACHE INTEGER
       "Timeout in seconds for each test (default 1200=20minutes)"
   )
-  ENABLE_TESTING ()
-  INCLUDE (CTest)
-  IF (NOT HDF4_EXTERNALLY_CONFIGURED)
-    IF (EXISTS "${HDF4_SOURCE_DIR}/hdf/test" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/hdf/test")
-      ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/hdf/test   ${PROJECT_BINARY_DIR}/hdf/test)
-    ENDIF (EXISTS "${HDF4_SOURCE_DIR}/hdf/test" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/hdf/test")
-    IF (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/test" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/test")
-      ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/mfhdf/test ${PROJECT_BINARY_DIR}/mfhdf/test)
-    ENDIF (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/test" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/test")
-  ENDIF (NOT HDF4_EXTERNALLY_CONFIGURED)
-  INCLUDE (${HDF4_SOURCE_DIR}/CTestConfig.cmake)
-  CONFIGURE_FILE (${HDF4_RESOURCES_DIR}/CTestCustom.cmake ${HDF4_BINARY_DIR}/CTestCustom.ctest @ONLY)
-ENDIF (BUILD_TESTING)
+  enable_testing ()
+  include (CTest)
+  if (NOT HDF4_EXTERNALLY_CONFIGURED)
+    if (EXISTS "${HDF4_SOURCE_DIR}/hdf/test" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/hdf/test")
+      add_subdirectory (${HDF4_SOURCE_DIR}/hdf/test   ${PROJECT_BINARY_DIR}/hdf/test)
+    endif (EXISTS "${HDF4_SOURCE_DIR}/hdf/test" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/hdf/test")
+    if (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/test" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/test")
+      add_subdirectory (${HDF4_SOURCE_DIR}/mfhdf/test ${PROJECT_BINARY_DIR}/mfhdf/test)
+    endif (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/test" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/test")
+  endif (NOT HDF4_EXTERNALLY_CONFIGURED)
+  include (${HDF4_SOURCE_DIR}/CTestConfig.cmake)
+  configure_file (${HDF_RESOURCES_DIR}/CTestCustom.cmake ${HDF4_BINARY_DIR}/CTestCustom.ctest @ONLY)
+endif (BUILD_TESTING)
 
 #-----------------------------------------------------------------------------
 # Option to build Fortran bindings/tests/examples
@@ -548,56 +548,56 @@ ENDIF (BUILD_TESTING)
 # so that fortran name mangling is detected before writing H4config.h
 #-----------------------------------------------------------------------------
 # Set default name mangling : overridden by Fortran detection in fortran dir
-SET (H4_F77_FUNC "H4_F77_FUNC(name,NAME) name ## _")
-SET (H4_F77_FUNC_ "H4_F77_FUNC_(name,NAME) name ## __")
-IF (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/fortran" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/fortran")
-  OPTION (HDF4_BUILD_FORTRAN "Build FORTRAN support" ON)
-  IF (HDF4_BUILD_FORTRAN)
-    IF (WIN32 AND NOT CYGWIN)
-      SET (H4_F77_FUNC "H4_F77_FUNC(name,NAME) NAME")
-      SET (H4_F77_FUNC_ "H4_F77_FUNC_(name,NAME) NAME")
-    ENDIF (WIN32 AND NOT CYGWIN)
-    INCLUDE (${HDF4_RESOURCES_DIR}/HDF4UseFortran.cmake)
-    ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/mfhdf/fortran ${PROJECT_BINARY_DIR}/mfhdf/fortran)
-    ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/hdf/fortran ${PROJECT_BINARY_DIR}/hdf/fortran)
-  ENDIF (HDF4_BUILD_FORTRAN)
-ENDIF (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/fortran" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/fortran")
-
-IF (MSVC)
-  SET (H4_HDSETVBUF "HDsetvbuf(F,S,M,Z) (((Z)>1)?setvbuf(F,S,M,Z):setvbuf(F,S,M,2))")
-ELSE (MSVC)
-  SET (H4_HDSETVBUF "NOP")
-ENDIF (MSVC)
+set (H4_F77_FUNC "H4_F77_FUNC(name,NAME) name ## _")
+set (H4_F77_FUNC_ "H4_F77_FUNC_(name,NAME) name ## __")
+if (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/fortran" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/fortran")
+  option (HDF4_BUILD_FORTRAN "Build FORTRAN support" ON)
+  if (HDF4_BUILD_FORTRAN)
+    if (WIN32)
+      set (H4_F77_FUNC "H4_F77_FUNC(name,NAME) NAME")
+      set (H4_F77_FUNC_ "H4_F77_FUNC_(name,NAME) NAME")
+    endif (WIN32)
+    include (${HDF_RESOURCES_DIR}/HDF4UseFortran.cmake)
+    add_subdirectory (${HDF4_SOURCE_DIR}/mfhdf/fortran ${PROJECT_BINARY_DIR}/mfhdf/fortran)
+    add_subdirectory (${HDF4_SOURCE_DIR}/hdf/fortran ${PROJECT_BINARY_DIR}/hdf/fortran)
+  endif (HDF4_BUILD_FORTRAN)
+endif (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/fortran" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/fortran")
+
+if (MSVC OR MINGW)
+  set (H4_HDSETVBUF "HDsetvbuf(F,S,M,Z) (((Z)>1)?setvbuf(F,S,M,Z):setvbuf(F,S,M,2))")
+else (MSVC OR MINGW)
+  set (H4_HDSETVBUF "NOP")
+endif (MSVC OR MINGW)
 
 #-----------------------------------------------------------------------------
 # Library utilities
 #-----------------------------------------------------------------------------
-ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/hdf   ${PROJECT_BINARY_DIR}/hdf)
-ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/mfhdf ${PROJECT_BINARY_DIR}/mfhdf)
+add_subdirectory (${HDF4_SOURCE_DIR}/hdf   ${PROJECT_BINARY_DIR}/hdf)
+add_subdirectory (${HDF4_SOURCE_DIR}/mfhdf ${PROJECT_BINARY_DIR}/mfhdf)
 
 #-----------------------------------------------------------------------------
 # Option to build HDF4 Examples
 #-----------------------------------------------------------------------------
-IF (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/examples" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/examples")
-  OPTION (HDF4_BUILD_EXAMPLES  "Build HDF4 Examples" OFF)
-  IF (HDF4_BUILD_EXAMPLES)
-    IF (HDF4_BUILD_FORTRAN)
-      IF (EXISTS "${HDF4_SOURCE_DIR}/hdf/fortran/examples" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/hdf/fortran/examples")
-        ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/hdf/fortran/examples     ${PROJECT_BINARY_DIR}/hdf/fortran/examples)
-      ENDIF (EXISTS "${HDF4_SOURCE_DIR}/hdf/fortran/examples" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/hdf/fortran/examples")
-      IF (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/fortran/examples" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/fortran/examples")
-        ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/mfhdf/fortran/examples     ${PROJECT_BINARY_DIR}/mfhdf/fortran/examples)
-      ENDIF (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/fortran/examples" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/fortran/examples")
-    ENDIF (HDF4_BUILD_FORTRAN)
+if (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/examples" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/examples")
+  option (HDF4_BUILD_EXAMPLES  "Build HDF4 Examples" OFF)
+  if (HDF4_BUILD_EXAMPLES)
+    if (HDF4_BUILD_FORTRAN)
+      if (EXISTS "${HDF4_SOURCE_DIR}/hdf/fortran/examples" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/hdf/fortran/examples")
+        add_subdirectory (${HDF4_SOURCE_DIR}/hdf/fortran/examples     ${PROJECT_BINARY_DIR}/hdf/fortran/examples)
+      endif (EXISTS "${HDF4_SOURCE_DIR}/hdf/fortran/examples" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/hdf/fortran/examples")
+      if (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/fortran/examples" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/fortran/examples")
+        add_subdirectory (${HDF4_SOURCE_DIR}/mfhdf/fortran/examples     ${PROJECT_BINARY_DIR}/mfhdf/fortran/examples)
+      endif (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/fortran/examples" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/fortran/examples")
+    endif (HDF4_BUILD_FORTRAN)
 
-    ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/hdf/examples    ${PROJECT_BINARY_DIR}/hdf/examples)
-    ADD_SUBDIRECTORY (${HDF4_SOURCE_DIR}/mfhdf/examples    ${PROJECT_BINARY_DIR}/mfhdf/examples)
-  ENDIF (HDF4_BUILD_EXAMPLES)
-ENDIF (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/examples" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/examples")
+    add_subdirectory (${HDF4_SOURCE_DIR}/hdf/examples    ${PROJECT_BINARY_DIR}/hdf/examples)
+    add_subdirectory (${HDF4_SOURCE_DIR}/mfhdf/examples    ${PROJECT_BINARY_DIR}/mfhdf/examples)
+  endif (HDF4_BUILD_EXAMPLES)
+endif (EXISTS "${HDF4_SOURCE_DIR}/mfhdf/examples" AND IS_DIRECTORY "${HDF4_SOURCE_DIR}/mfhdf/examples")
 
 #-----------------------------------------------------------------------------
 # Generate the H4config.h file containing user settings needed by compilation
 #-----------------------------------------------------------------------------
-CONFIGURE_FILE (${HDF4_RESOURCES_DIR}/h4config.h.in      ${PROJECT_BINARY_DIR}/h4config.h @ONLY)
+configure_file (${HDF_RESOURCES_DIR}/h4config.h.in      ${PROJECT_BINARY_DIR}/h4config.h @ONLY)
 
-INCLUDE (CMakeInstallation.cmake)
+include (CMakeInstallation.cmake)
diff --git a/COPYING b/COPYING
index 8c2b95e..825f1ce 100644
--- a/COPYING
+++ b/COPYING
@@ -4,7 +4,7 @@ Hierarchical Data Format (HDF) Software Library and Utilities
 ---------------------------------------------------------------------------
 
 Hierarchical Data Format (HDF) Software Library and Utilities
-Copyright 2006-2014 by The HDF Group.
+Copyright 2006-2015 by The HDF Group.
 
 NCSA Hierarchical Data Format (HDF) Software Library and Utilities
 Copyright 1988-2006 by the Board of Trustees of the University of Illinois.
diff --git a/CTestConfig.cmake b/CTestConfig.cmake
index 4731570..6bc8702 100644
--- a/CTestConfig.cmake
+++ b/CTestConfig.cmake
@@ -4,29 +4,29 @@
 ## # The following are required to uses Dart and the Cdash dashboard
 ##   ENABLE_TESTING()
 ##   INCLUDE(CTest)
-SET (CTEST_PROJECT_NAME "HDF4")
-SET (CTEST_NIGHTLY_START_TIME "18:00:00 CST")
+set (CTEST_PROJECT_NAME "HDF4")
+set (CTEST_NIGHTLY_START_TIME "18:00:00 CST")
 
-SET (CTEST_DROP_METHOD "http")
-IF (CDASH_LOCAL)
-  SET (CTEST_DROP_SITE "72.36.68.252")
-  SET (CTEST_DROP_LOCATION "/submit.php?project=HDF4")
-ELSE (CDASH_LOCAL)
-  SET (CTEST_DROP_SITE "cdash.hdfgroup.uiuc.edu")
-  SET (CTEST_DROP_LOCATION "/submit.php?project=HDF4")
-ENDIF (CDASH_LOCAL)
-SET (CTEST_DROP_SITE_CDASH TRUE)
+set (CTEST_DROP_METHOD "http")
+if (CDASH_LOCAL)
+  set (CTEST_DROP_SITE "72.36.68.252")
+  set (CTEST_DROP_LOCATION "/submit.php?project=HDF4")
+else (CDASH_LOCAL)
+  set (CTEST_DROP_SITE "cdash.hdfgroup.uiuc.edu")
+  set (CTEST_DROP_LOCATION "/submit.php?project=HDF4")
+endif (CDASH_LOCAL)
+set (CTEST_DROP_SITE_CDASH TRUE)
 
-SET (UPDATE_TYPE svn)
+set (UPDATE_TYPE svn)
 
-SET (VALGRIND_COMMAND "/usr/bin/valgrind")
-SET (VALGRIND_COMMAND_OPTIONS "-v --tool=memcheck --leak-check=full --track-fds=yes --num-callers=50 --show-reachable=yes --track-origins=yes --malloc-fill=0xff --free-fill=0xfe")
+set (VALGRIND_COMMAND "/usr/bin/valgrind")
+set (VALGRIND_COMMAND_OPTIONS "-v --tool=memcheck --leak-check=full --track-fds=yes --num-callers=50 --show-reachable=yes --track-origins=yes --malloc-fill=0xff --free-fill=0xfe")
 
-SET (CTEST_TEST_TIMEOUT 3600 CACHE STRING 
+set (CTEST_TEST_TIMEOUT 3600 CACHE STRING 
     "Maximum time allowed before CTest will kill the test.") 
-SET (DART_TESTING_TIMEOUT 3600 CACHE STRING 
+set (DART_TESTING_TIMEOUT 3600 CACHE STRING 
     "Maximum time allowed before CTest will kill the test." FORCE)
 
-SET(CTEST_SUBMIT_RETRY_DELAY 20 CACHE STRING
+set (CTEST_SUBMIT_RETRY_DELAY 20 CACHE STRING
     "How long to wait between timed-out CTest submissions.")
     
\ No newline at end of file
diff --git a/MANIFEST b/MANIFEST
index 3d285a4..da8c4d8 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -53,6 +53,7 @@
 ./bin/reconfigure
 ./bin/runtest
 ./bin/snapshot
+./bin/test-driver
 ./bin/timekeeper      _DO_NOT_DISTRIBUTE_
 ./bin/yodconfigure
 ./bin/h4vers
@@ -414,7 +415,6 @@
 ./hdf/util/hdfpack.out1
 ./hdf/util/hdfpack.out1.1
 ./hdf/util/hdfpack.out1.2
-./hdf/util/hdfrseq.c
 ./hdf/util/hdftopal.c
 ./hdf/util/hdftor8.c
 ./hdf/util/hdftor8.out1
@@ -433,7 +433,6 @@
 ./hdf/util/ristosds.input1
 ./hdf/util/ristosds.out1
 ./hdf/util/testutil.sh.in
-./hdf/util/vcompat.c
 ./hdf/util/vmake.c
 ./hdf/util/vshow.c
 ./hdf/util/writehdf.c
@@ -780,6 +779,7 @@
 ./mfhdf/hrepack/Makefile.in
 ./mfhdf/hrepack/hrepack.c
 ./mfhdf/hrepack/hrepack.h
+./mfhdf/hrepack/hrepack.sh.in
 ./mfhdf/hrepack/hrepack_all.sh.in
 ./mfhdf/hrepack/hrepack_an.c
 ./mfhdf/hrepack/hrepack_an.h
@@ -804,6 +804,8 @@
 ./mfhdf/hrepack/hrepack_vs.h
 ./mfhdf/hrepack/hrepack_dim.c
 ./mfhdf/hrepack/hrepack_dim.h
+./mfhdf/hrepack/hrepack_help.txt
+./mfhdf/hrepack/hrepack_check_help.txt
 ./mfhdf/hrepack/image24pixel.txt
 ./mfhdf/hrepack/image24plane.txt
 ./mfhdf/hrepack/image8.txt
@@ -1027,30 +1029,44 @@
 ./CMakeInstallation.cmake
 ./UserMacros.cmake
 
+./config/cmake/cacheinit.cmake
 ./config/cmake/ConfigureChecks.cmake
 ./config/cmake/CTestCustom.cmake
-./config/cmake/runTest.cmake
-./config/cmake/HDFMacros.cmake
-./config/cmake/HDFLibMacros.cmake
-./config/cmake/CheckTypeSize.cmake
-./config/cmake/h4config.h.in
-./config/cmake/HDFTests.c
 ./config/cmake/FindHDF4.cmake.in
-./config/cmake/FindSZIP.cmake
-./config/cmake/FindMPI.cmake
-./config/cmake/cacheinit.cmake
-./config/cmake/mccacheinit.cmake
-./config/cmake/HDF4Macros.cmake
-./config/cmake/HDF4UseFortran.cmake
+./config/cmake/h4config.h.in
 ./config/cmake/HDF4_Examples.cmake.in
+./config/cmake/hdf4-config-version.cmake.in
 ./config/cmake/hdf4-config.cmake.build.in
 ./config/cmake/hdf4-config.cmake.install.in
-./config/cmake/hdf4-config-version.cmake.in
-./config/cmake/CPack.Info.plist.in
-./config/cmake/hdf.gif
+./config/cmake/HDF4Macros.cmake
+./config/cmake/HDF4UseFortran.cmake
 ./config/cmake/libhdf4.settings.cmake.in
-./config/cmake/NSIS.template.in
+./config/cmake/mccacheinit.cmake
 ./config/cmake/NSIS.InstallOptions.ini.in
+./config/cmake/PkgInfo.in
+./config/cmake/README.txt.cmake.in
+
+./config/cmake_ext_mod/CheckTypeSize.cmake
+./config/cmake_ext_mod/ConfigureChecks.cmake
+./config/cmake_ext_mod/CPack.Info.plist.in
+./config/cmake_ext_mod/CTestCustom.cmake
+./config/cmake_ext_mod/FindMPI.cmake      _DO_NOT_DISTRIBUTE_
+./config/cmake_ext_mod/FindSZIP.cmake
+./config/cmake_ext_mod/GetTimeOfDayTest.cpp
+./config/cmake_ext_mod/grepTest.cmake
+./config/cmake_ext_mod/hdf.bmp
+./config/cmake_ext_mod/hdf.icns
+./config/cmake_ext_mod/hdf.ico
+./config/cmake_ext_mod/HDFCXXTests.cpp
+./config/cmake_ext_mod/HDFLibMacros.cmake
+./config/cmake_ext_mod/HDFMacros.cmake
+./config/cmake_ext_mod/HDFTests.c
+./config/cmake_ext_mod/HDFUseFortran.cmake
+./config/cmake_ext_mod/NSIS.InstallOptions.ini.in
+./config/cmake_ext_mod/NSIS.template.in
+./config/cmake_ext_mod/prunTest.cmake
+./config/cmake_ext_mod/runTest.cmake
+./config/cmake_ext_mod/version.plist.in
 
 # CMake-specific User Files
 ./config/cmake/UserMacros/Windows_MT.cmake
diff --git a/Makefile.in b/Makefile.in
index 546c708..e9a80c1 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -18,23 +18,51 @@
 #############################################################################
 
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -53,15 +81,15 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(am__configure_deps) $(srcdir)/Makefile.am \
-	$(srcdir)/Makefile.in $(srcdir)/libhdf4.settings.in \
-	$(top_srcdir)/bin/config.guess $(top_srcdir)/bin/config.sub \
-	$(top_srcdir)/bin/install-sh $(top_srcdir)/bin/ltmain.sh \
-	$(top_srcdir)/bin/missing $(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am $(top_srcdir)/configure \
-	COPYING bin/compile bin/config.guess bin/config.sub \
-	bin/depcomp bin/install-sh bin/ltmain.sh bin/missing \
-	bin/mkinstalldirs
+DIST_COMMON = $(top_srcdir)/config/commence.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/configure \
+	$(am__configure_deps) $(top_srcdir)/bin/mkinstalldirs \
+	$(srcdir)/libhdf4.settings.in COPYING bin/compile \
+	bin/config.guess bin/config.sub bin/depcomp bin/install-sh \
+	bin/missing bin/mkinstalldirs bin/ltmain.sh \
+	$(top_srcdir)/bin/compile $(top_srcdir)/bin/config.guess \
+	$(top_srcdir)/bin/config.sub $(top_srcdir)/bin/install-sh \
+	$(top_srcdir)/bin/ltmain.sh $(top_srcdir)/bin/missing
 subdir = .
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 am__aclocal_m4_deps = $(top_srcdir)/configure.ac
@@ -73,15 +101,28 @@ mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs
 CONFIG_HEADER = $(top_builddir)/hdf/src/h4config.h
 CONFIG_CLEAN_FILES = libhdf4.settings
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 SOURCES =
 DIST_SOURCES =
-RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
-	html-recursive info-recursive install-data-recursive \
-	install-dvi-recursive install-exec-recursive \
-	install-html-recursive install-info-recursive \
-	install-pdf-recursive install-ps-recursive install-recursive \
-	installcheck-recursive installdirs-recursive pdf-recursive \
-	ps-recursive uninstall-recursive
+RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
+	ctags-recursive dvi-recursive html-recursive info-recursive \
+	install-data-recursive install-dvi-recursive \
+	install-exec-recursive install-html-recursive \
+	install-info-recursive install-pdf-recursive \
+	install-ps-recursive install-recursive installcheck-recursive \
+	installdirs-recursive pdf-recursive ps-recursive \
+	tags-recursive uninstall-recursive
 am__can_run_installinfo = \
   case $$AM_UPDATE_INFO_DIR in \
     n|no|NO) false;; \
@@ -118,9 +159,29 @@ am__installdirs = "$(DESTDIR)$(settingsdir)"
 DATA = $(settings_DATA)
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
   distclean-recursive maintainer-clean-recursive
-AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
-	$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
+am__recursive_targets = \
+  $(RECURSIVE_TARGETS) \
+  $(RECURSIVE_CLEAN_TARGETS) \
+  $(am__extra_recursive_targets)
+AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
 	cscope distdir dist dist-all distcheck
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 CSCOPE = cscope
@@ -169,6 +230,7 @@ am__distuninstallcheck_listfiles = $(distuninstallcheck_listfiles) \
 distcleancheck_listfiles = find . -type f -print
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -253,6 +315,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -414,14 +477,13 @@ uninstall-settingsDATA:
 # (1) if the variable is set in 'config.status', edit 'config.status'
 #     (which will cause the Makefiles to be regenerated when you run 'make');
 # (2) otherwise, pass the desired values on the 'make' command line.
-$(RECURSIVE_TARGETS) $(RECURSIVE_CLEAN_TARGETS):
-	@fail= failcom='exit 1'; \
-	for f in x $$MAKEFLAGS; do \
-	  case $$f in \
-	    *=* | --[!k]*);; \
-	    *k*) failcom='fail=yes';; \
-	  esac; \
-	done; \
+$(am__recursive_targets):
+	@fail=; \
+	if $(am__make_keepgoing); then \
+	  failcom='fail=yes'; \
+	else \
+	  failcom='exit 1'; \
+	fi; \
 	dot_seen=no; \
 	target=`echo $@ | sed s/-recursive//`; \
 	case "$@" in \
@@ -442,31 +504,13 @@ $(RECURSIVE_TARGETS) $(RECURSIVE_CLEAN_TARGETS):
 	if test "$$dot_seen" = "no"; then \
 	  $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
 	fi; test -z "$$fail"
-tags-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
-	done
-ctags-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
-	done
-cscopelist-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) cscopelist); \
-	done
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-recursive
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
@@ -482,12 +526,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
 	  fi; \
 	done; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -499,15 +538,11 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-recursive
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -516,18 +551,16 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
-
 cscope: cscope.files
 	test ! -s cscope.files \
 	  || $(CSCOPE) -b -q $(AM_CSCOPEFLAGS) $(CSCOPEFLAGS) -i cscope.files $(CSCOPE_ARGS)
-
 clean-cscope:
 	-rm -f cscope.files
+cscope.files: clean-cscope cscopelist
+cscopelist: cscopelist-recursive
 
-cscope.files: clean-cscope cscopelist-recursive cscopelist
-
-cscopelist: cscopelist-recursive $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -625,10 +658,16 @@ dist-xz: distdir
 	$(am__post_remove_distdir)
 
 dist-tarZ: distdir
+	@echo WARNING: "Support for shar distribution archives is" \
+	               "deprecated." >&2
+	@echo WARNING: "It will be removed altogether in Automake 2.0" >&2
 	tardir=$(distdir) && $(am__tar) | compress -c >$(distdir).tar.Z
 	$(am__post_remove_distdir)
 
 dist-shar: distdir
+	@echo WARNING: "Support for distribution archives compressed with" \
+		       "legacy program 'compress' is deprecated." >&2
+	@echo WARNING: "It will be removed altogether in Automake 2.0" >&2
 	shar $(distdir) | GZIP=$(GZIP_ENV) gzip -c >$(distdir).shar.gz
 	$(am__post_remove_distdir)
 
@@ -670,9 +709,10 @@ distcheck: dist
 	  && dc_destdir="$${TMPDIR-/tmp}/am-dc-$$$$/" \
 	  && am__cwd=`pwd` \
 	  && $(am__cd) $(distdir)/_build \
-	  && ../configure --srcdir=.. --prefix="$$dc_install_base" \
+	  && ../configure \
 	    $(AM_DISTCHECK_CONFIGURE_FLAGS) \
 	    $(DISTCHECK_CONFIGURE_FLAGS) \
+	    --srcdir=.. --prefix="$$dc_install_base" \
 	  && $(MAKE) $(AM_MAKEFLAGS) \
 	  && $(MAKE) $(AM_MAKEFLAGS) dvi \
 	  && $(MAKE) $(AM_MAKEFLAGS) check \
@@ -831,16 +871,13 @@ ps-am:
 
 uninstall-am: uninstall-settingsDATA
 
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) \
-	cscopelist-recursive ctags-recursive install-am install-strip \
-	tags-recursive
+.MAKE: $(am__recursive_targets) install-am install-strip
 
-.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
-	all all-am am--refresh check check-am clean clean-cscope \
-	clean-generic clean-libtool cscope cscopelist \
-	cscopelist-recursive ctags ctags-recursive dist dist-all \
-	dist-bzip2 dist-gzip dist-lzip dist-shar dist-tarZ dist-xz \
-	dist-zip distcheck distclean distclean-generic \
+.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am \
+	am--refresh check check-am clean clean-cscope clean-generic \
+	clean-libtool cscope cscopelist-am ctags ctags-am dist \
+	dist-all dist-bzip2 dist-gzip dist-lzip dist-shar dist-tarZ \
+	dist-xz dist-zip distcheck distclean distclean-generic \
 	distclean-libtool distclean-tags distcleancheck distdir \
 	distuninstallcheck dvi dvi-am html html-am info info-am \
 	install install-am install-data install-data-am install-dvi \
@@ -850,8 +887,8 @@ uninstall-am: uninstall-settingsDATA
 	install-settingsDATA install-strip installcheck \
 	installcheck-am installdirs installdirs-am maintainer-clean \
 	maintainer-clean-generic mostlyclean mostlyclean-generic \
-	mostlyclean-libtool pdf pdf-am ps ps-am tags tags-recursive \
-	uninstall uninstall-am uninstall-settingsDATA
+	mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \
+	uninstall-am uninstall-settingsDATA
 
 
 # 'make install' will now install examples, the same as 'make install-all'.
diff --git a/README.txt b/README.txt
index 2351cd2..6d397d9 100644
--- a/README.txt
+++ b/README.txt
@@ -1,4 +1,4 @@
-HDF version 4.2.10 released on 2014-02-09
+HDF version 4.2.11 released on 2015-02-09
 ===================================================
 
 Obtaining the latest version of HDF4
diff --git a/UserMacros.cmake b/UserMacros.cmake
index 4c680ed..65ea5d4 100644
--- a/UserMacros.cmake
+++ b/UserMacros.cmake
@@ -8,14 +8,14 @@
 # Option to Build with User Defined Values
 #-----------------------------------------------------------------------------
 MACRO (MACRO_USER_DEFINED_LIBS)
-  SET (USER_DEFINED_VALUE "FALSE")
+  set (USER_DEFINED_VALUE "FALSE")
 ENDMACRO (MACRO_USER_DEFINED_LIBS)
 
 #-------------------------------------------------------------------------------
-OPTION (BUILD_USER_DEFINED_LIBS "Build With User Defined Values" OFF)
-IF (BUILD_USER_DEFINED_LIBS)
+option (BUILD_USER_DEFINED_LIBS "Build With User Defined Values" OFF)
+if (BUILD_USER_DEFINED_LIBS)
   MACRO_USER_DEFINED_LIBS ()
-ENDIF (BUILD_USER_DEFINED_LIBS)
+endif (BUILD_USER_DEFINED_LIBS)
 #-----------------------------------------------------------------------------
 #------------------- E X A M P L E   E N D -----------------------------------
 #-----------------------------------------------------------------------------
diff --git a/aclocal.m4 b/aclocal.m4
index 5172af3..1ecfa26 100644
--- a/aclocal.m4
+++ b/aclocal.m4
@@ -1,6 +1,6 @@
-# generated automatically by aclocal 1.12.3 -*- Autoconf -*-
+# generated automatically by aclocal 1.14.1 -*- Autoconf -*-
 
-# Copyright (C) 1996-2012 Free Software Foundation, Inc.
+# Copyright (C) 1996-2013 Free Software Foundation, Inc.
 
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -11,6 +11,7 @@
 # even the implied warranty of MERCHANTABILITY or FITNESS FOR A
 # PARTICULAR PURPOSE.
 
+m4_ifndef([AC_CONFIG_MACRO_DIRS], [m4_defun([_AM_CONFIG_MACRO_DIRS], [])m4_defun([AC_CONFIG_MACRO_DIRS], [_AM_CONFIG_MACRO_DIRS($@)])])
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
 m4_if(m4_defn([AC_AUTOCONF_VERSION]), [2.69],,
@@ -19,7 +20,7 @@ You have another version of autoconf.  It may work, but is not guaranteed to.
 If you have problems, you may need to regenerate the build system entirely.
 To do so, use the procedure documented by the package, typically 'autoreconf'.])])
 
-# Copyright (C) 2002-2012 Free Software Foundation, Inc.
+# Copyright (C) 2002-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -31,10 +32,10 @@ To do so, use the procedure documented by the package, typically 'autoreconf'.])
 # generated from the m4 files accompanying Automake X.Y.
 # (This private macro should not be called outside this file.)
 AC_DEFUN([AM_AUTOMAKE_VERSION],
-[am__api_version='1.12'
+[am__api_version='1.14'
 dnl Some users find AM_AUTOMAKE_VERSION and mistake it for a way to
 dnl require some minimum version.  Point them to the right macro.
-m4_if([$1], [1.12.3], [],
+m4_if([$1], [1.14.1], [],
       [AC_FATAL([Do not call $0, use AM_INIT_AUTOMAKE([$1]).])])dnl
 ])
 
@@ -50,14 +51,14 @@ m4_define([_AM_AUTOCONF_VERSION], [])
 # Call AM_AUTOMAKE_VERSION and AM_AUTOMAKE_VERSION so they can be traced.
 # This function is AC_REQUIREd by AM_INIT_AUTOMAKE.
 AC_DEFUN([AM_SET_CURRENT_AUTOMAKE_VERSION],
-[AM_AUTOMAKE_VERSION([1.12.3])dnl
+[AM_AUTOMAKE_VERSION([1.14.1])dnl
 m4_ifndef([AC_AUTOCONF_VERSION],
   [m4_copy([m4_PACKAGE_VERSION], [AC_AUTOCONF_VERSION])])dnl
 _AM_AUTOCONF_VERSION(m4_defn([AC_AUTOCONF_VERSION]))])
 
 # AM_AUX_DIR_EXPAND                                         -*- Autoconf -*-
 
-# Copyright (C) 2001-2012 Free Software Foundation, Inc.
+# Copyright (C) 2001-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -110,7 +111,7 @@ am_aux_dir=`cd $ac_aux_dir && pwd`
 
 # AM_CONDITIONAL                                            -*- Autoconf -*-
 
-# Copyright (C) 1997-2012 Free Software Foundation, Inc.
+# Copyright (C) 1997-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -141,7 +142,7 @@ AC_CONFIG_COMMANDS_PRE(
 Usually this means the macro was only invoked conditionally.]])
 fi])])
 
-# Copyright (C) 1999-2012 Free Software Foundation, Inc.
+# Copyright (C) 1999-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -332,7 +333,7 @@ _AM_SUBST_NOTMAKE([am__nodep])dnl
 
 # Generate code to set up dependency tracking.              -*- Autoconf -*-
 
-# Copyright (C) 1999-2012 Free Software Foundation, Inc.
+# Copyright (C) 1999-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -343,7 +344,7 @@ _AM_SUBST_NOTMAKE([am__nodep])dnl
 # ------------------------------
 AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
 [{
-  # Autoconf 2.62 quotes --file arguments for eval, but not when files
+  # Older Autoconf quotes --file arguments for eval, but not when files
   # are listed without --file.  Let's play safe and only enable the eval
   # if we detect the quoting.
   case $CONFIG_FILES in
@@ -372,7 +373,7 @@ AC_DEFUN([_AM_OUTPUT_DEPENDENCY_COMMANDS],
     DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
     test -z "$DEPDIR" && continue
     am__include=`sed -n 's/^am__include = //p' < "$mf"`
-    test -z "am__include" && continue
+    test -z "$am__include" && continue
     am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
     # Find all dependency output files, they are included files with
     # $(DEPDIR) in their names.  We invoke sed twice because it is the
@@ -408,7 +409,7 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
 
 # Do all the work for Automake.                             -*- Autoconf -*-
 
-# Copyright (C) 1996-2012 Free Software Foundation, Inc.
+# Copyright (C) 1996-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -417,6 +418,12 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
 # This macro actually does too much.  Some checks are only needed if
 # your package does certain things.  But this isn't really a big deal.
 
+dnl Redefine AC_PROG_CC to automatically invoke _AM_PROG_CC_C_O.
+m4_define([AC_PROG_CC],
+m4_defn([AC_PROG_CC])
+[_AM_PROG_CC_C_O
+])
+
 # AM_INIT_AUTOMAKE(PACKAGE, VERSION, [NO-DEFINE])
 # AM_INIT_AUTOMAKE([OPTIONS])
 # -----------------------------------------------
@@ -429,7 +436,7 @@ AC_DEFUN([AM_OUTPUT_DEPENDENCY_COMMANDS],
 # arguments mandatory, and then we can depend on a new Autoconf
 # release and drop the old call support.
 AC_DEFUN([AM_INIT_AUTOMAKE],
-[AC_PREREQ([2.62])dnl
+[AC_PREREQ([2.65])dnl
 dnl Autoconf wants to disallow AM_ names.  We explicitly allow
 dnl the ones we care about.
 m4_pattern_allow([^AM_[A-Z]+FLAGS$])dnl
@@ -459,8 +466,7 @@ AC_SUBST([CYGPATH_W])
 dnl Distinguish between old-style and new-style calls.
 m4_ifval([$2],
 [AC_DIAGNOSE([obsolete],
-[$0: two- and three-arguments forms are deprecated.  For more info, see:
-http://www.gnu.org/software/automake/manual/automake.html#Modernize-AM_INIT_AUTOMAKE-invocation])
+             [$0: two- and three-arguments forms are deprecated.])
 m4_ifval([$3], [_AM_SET_OPTION([no-define])])dnl
  AC_SUBST([PACKAGE], [$1])dnl
  AC_SUBST([VERSION], [$2])],
@@ -514,22 +520,60 @@ AC_PROVIDE_IFELSE([AC_PROG_OBJC],
 		  [_AM_DEPENDENCIES([OBJC])],
 		  [m4_define([AC_PROG_OBJC],
 			     m4_defn([AC_PROG_OBJC])[_AM_DEPENDENCIES([OBJC])])])dnl
-dnl Support for Objective C++ was only introduced in Autoconf 2.65,
-dnl but we still cater to Autoconf 2.62.
-m4_ifdef([AC_PROG_OBJCXX],
-[AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
+AC_PROVIDE_IFELSE([AC_PROG_OBJCXX],
 		  [_AM_DEPENDENCIES([OBJCXX])],
 		  [m4_define([AC_PROG_OBJCXX],
-			     m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])])dnl
+			     m4_defn([AC_PROG_OBJCXX])[_AM_DEPENDENCIES([OBJCXX])])])dnl
 ])
-_AM_IF_OPTION([silent-rules], [AC_REQUIRE([AM_SILENT_RULES])])dnl
-dnl The 'parallel-tests' driver may need to know about EXEEXT, so add the
-dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen.  This macro
-dnl is hooked onto _AC_COMPILER_EXEEXT early, see below.
+AC_REQUIRE([AM_SILENT_RULES])dnl
+dnl The testsuite driver may need to know about EXEEXT, so add the
+dnl 'am__EXEEXT' conditional if _AM_COMPILER_EXEEXT was seen.  This
+dnl macro is hooked onto _AC_COMPILER_EXEEXT early, see below.
 AC_CONFIG_COMMANDS_PRE(dnl
 [m4_provide_if([_AM_COMPILER_EXEEXT],
   [AM_CONDITIONAL([am__EXEEXT], [test -n "$EXEEXT"])])])dnl
-])
+
+# POSIX will say in a future version that running "rm -f" with no argument
+# is OK; and we want to be able to make that assumption in our Makefile
+# recipes.  So use an aggressive probe to check that the usage we want is
+# actually supported "in the wild" to an acceptable degree.
+# See automake bug#10828.
+# To make any issue more visible, cause the running configure to be aborted
+# by default if the 'rm' program in use doesn't match our expectations; the
+# user can still override this though.
+if rm -f && rm -fr && rm -rf; then : OK; else
+  cat >&2 <<'END'
+Oops!
+
+Your 'rm' program seems unable to run without file operands specified
+on the command line, even when the '-f' option is present.  This is contrary
+to the behaviour of most rm programs out there, and not conforming with
+the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
+
+Please tell bug-automake at gnu.org about your system, including the value
+of your $PATH and any error possibly output before this message.  This
+can help us improve future automake versions.
+
+END
+  if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
+    echo 'Configuration will proceed anyway, since you have set the' >&2
+    echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
+    echo >&2
+  else
+    cat >&2 <<'END'
+Aborting the configuration process, to ensure you take notice of the issue.
+
+You can download and install GNU coreutils to get an 'rm' implementation
+that behaves properly: <http://www.gnu.org/software/coreutils/>.
+
+If you want to complete the configuration process using your problematic
+'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
+to "yes", and re-run configure.
+
+END
+    AC_MSG_ERROR([Your 'rm' program is bad, sorry.])
+  fi
+fi])
 
 dnl Hook into '_AC_COMPILER_EXEEXT' early to learn its expansion.  Do not
 dnl add the conditional right here, as _AC_COMPILER_EXEEXT may be further
@@ -537,7 +581,6 @@ dnl mangled by Autoconf and run in a shell conditional statement.
 m4_define([_AC_COMPILER_EXEEXT],
 m4_defn([_AC_COMPILER_EXEEXT])[m4_provide([_AM_COMPILER_EXEEXT])])
 
-
 # When config.status generates a header, we must update the stamp-h file.
 # This file resides in the same directory as the config header
 # that is generated.  The stamp files are numbered to have different names.
@@ -559,7 +602,7 @@ for _am_header in $config_headers :; do
 done
 echo "timestamp for $_am_arg" >`AS_DIRNAME(["$_am_arg"])`/stamp-h[]$_am_stamp_count])
 
-# Copyright (C) 2001-2012 Free Software Foundation, Inc.
+# Copyright (C) 2001-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -580,7 +623,7 @@ if test x"${install_sh}" != xset; then
 fi
 AC_SUBST([install_sh])])
 
-# Copyright (C) 2003-2012 Free Software Foundation, Inc.
+# Copyright (C) 2003-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -602,7 +645,7 @@ AC_SUBST([am__leading_dot])])
 # Add --enable-maintainer-mode option to configure.         -*- Autoconf -*-
 # From Jim Meyering
 
-# Copyright (C) 1996-2012 Free Software Foundation, Inc.
+# Copyright (C) 1996-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -635,11 +678,9 @@ AC_MSG_CHECKING([whether to enable maintainer-specific portions of Makefiles])
 ]
 )
 
-AU_DEFUN([jm_MAINTAINER_MODE], [AM_MAINTAINER_MODE])
-
 # Check to see how 'make' treats includes.	            -*- Autoconf -*-
 
-# Copyright (C) 2001-2012 Free Software Foundation, Inc.
+# Copyright (C) 2001-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -689,7 +730,7 @@ rm -f confinc confmf
 
 # Fake the existence of programs that GNU maintainers use.  -*- Autoconf -*-
 
-# Copyright (C) 1997-2012 Free Software Foundation, Inc.
+# Copyright (C) 1997-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -704,8 +745,8 @@ AC_SUBST($1)])
 
 # AM_MISSING_HAS_RUN
 # ------------------
-# Define MISSING if not defined so far and test if it supports --run.
-# If it does, set am_missing_run to use it, otherwise, to nothing.
+# Define MISSING if not defined so far and test if it is modern enough.
+# If it is, set am_missing_run to use it, otherwise, to nothing.
 AC_DEFUN([AM_MISSING_HAS_RUN],
 [AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
 AC_REQUIRE_AUX_FILE([missing])dnl
@@ -718,8 +759,8 @@ if test x"${MISSING+set}" != xset; then
   esac
 fi
 # Use eval to expand $SHELL
-if eval "$MISSING --run true"; then
-  am_missing_run="$MISSING --run "
+if eval "$MISSING --is-lightweight"; then
+  am_missing_run="$MISSING "
 else
   am_missing_run=
   AC_MSG_WARN(['missing' script is too old or missing])
@@ -728,7 +769,7 @@ fi
 
 # Helper functions for option handling.                     -*- Autoconf -*-
 
-# Copyright (C) 2001-2012 Free Software Foundation, Inc.
+# Copyright (C) 2001-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -757,9 +798,73 @@ AC_DEFUN([_AM_SET_OPTIONS],
 AC_DEFUN([_AM_IF_OPTION],
 [m4_ifset(_AM_MANGLE_OPTION([$1]), [$2], [$3])])
 
+# Copyright (C) 1999-2013 Free Software Foundation, Inc.
+#
+# This file is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# _AM_PROG_CC_C_O
+# ---------------
+# Like AC_PROG_CC_C_O, but changed for automake.  We rewrite AC_PROG_CC
+# to automatically call this.
+AC_DEFUN([_AM_PROG_CC_C_O],
+[AC_REQUIRE([AM_AUX_DIR_EXPAND])dnl
+AC_REQUIRE_AUX_FILE([compile])dnl
+AC_LANG_PUSH([C])dnl
+AC_CACHE_CHECK(
+  [whether $CC understands -c and -o together],
+  [am_cv_prog_cc_c_o],
+  [AC_LANG_CONFTEST([AC_LANG_PROGRAM([])])
+  # Make sure it works both with $CC and with simple cc.
+  # Following AC_PROG_CC_C_O, we do the test twice because some
+  # compilers refuse to overwrite an existing .o file with -o,
+  # though they will create one.
+  am_cv_prog_cc_c_o=yes
+  for am_i in 1 2; do
+    if AM_RUN_LOG([$CC -c conftest.$ac_ext -o conftest2.$ac_objext]) \
+         && test -f conftest2.$ac_objext; then
+      : OK
+    else
+      am_cv_prog_cc_c_o=no
+      break
+    fi
+  done
+  rm -f core conftest*
+  unset am_i])
+if test "$am_cv_prog_cc_c_o" != yes; then
+   # Losing compiler, so override with the script.
+   # FIXME: It is wrong to rewrite CC.
+   # But if we don't then we get into trouble of one sort or another.
+   # A longer-term fix would be to have automake use am__CC in this case,
+   # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
+   CC="$am_aux_dir/compile $CC"
+fi
+AC_LANG_POP([C])])
+
+# For backward compatibility.
+AC_DEFUN_ONCE([AM_PROG_CC_C_O], [AC_REQUIRE([AC_PROG_CC])])
+
+# Copyright (C) 2001-2013 Free Software Foundation, Inc.
+#
+# This file is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# AM_RUN_LOG(COMMAND)
+# -------------------
+# Run COMMAND, save the exit status in ac_status, and log it.
+# (This has been adapted from Autoconf's _AC_RUN_LOG macro.)
+AC_DEFUN([AM_RUN_LOG],
+[{ echo "$as_me:$LINENO: $1" >&AS_MESSAGE_LOG_FD
+   ($1) >&AS_MESSAGE_LOG_FD 2>&AS_MESSAGE_LOG_FD
+   ac_status=$?
+   echo "$as_me:$LINENO: \$? = $ac_status" >&AS_MESSAGE_LOG_FD
+   (exit $ac_status); }])
+
 # Check to make sure that the build environment is sane.    -*- Autoconf -*-
 
-# Copyright (C) 1996-2012 Free Software Foundation, Inc.
+# Copyright (C) 1996-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -840,7 +945,67 @@ AC_CONFIG_COMMANDS_PRE(
 rm -f conftest.file
 ])
 
-# Copyright (C) 2001-2012 Free Software Foundation, Inc.
+# Copyright (C) 2009-2013 Free Software Foundation, Inc.
+#
+# This file is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# AM_SILENT_RULES([DEFAULT])
+# --------------------------
+# Enable less verbose build rules; with the default set to DEFAULT
+# ("yes" being less verbose, "no" or empty being verbose).
+AC_DEFUN([AM_SILENT_RULES],
+[AC_ARG_ENABLE([silent-rules], [dnl
+AS_HELP_STRING(
+  [--enable-silent-rules],
+  [less verbose build output (undo: "make V=1")])
+AS_HELP_STRING(
+  [--disable-silent-rules],
+  [verbose build output (undo: "make V=0")])dnl
+])
+case $enable_silent_rules in @%:@ (((
+  yes) AM_DEFAULT_VERBOSITY=0;;
+   no) AM_DEFAULT_VERBOSITY=1;;
+    *) AM_DEFAULT_VERBOSITY=m4_if([$1], [yes], [0], [1]);;
+esac
+dnl
+dnl A few 'make' implementations (e.g., NonStop OS and NextStep)
+dnl do not support nested variable expansions.
+dnl See automake bug#9928 and bug#10237.
+am_make=${MAKE-make}
+AC_CACHE_CHECK([whether $am_make supports nested variables],
+   [am_cv_make_support_nested_variables],
+   [if AS_ECHO([['TRUE=$(BAR$(V))
+BAR0=false
+BAR1=true
+V=1
+am__doit:
+	@$(TRUE)
+.PHONY: am__doit']]) | $am_make -f - >/dev/null 2>&1; then
+  am_cv_make_support_nested_variables=yes
+else
+  am_cv_make_support_nested_variables=no
+fi])
+if test $am_cv_make_support_nested_variables = yes; then
+  dnl Using '$V' instead of '$(V)' breaks IRIX make.
+  AM_V='$(V)'
+  AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
+else
+  AM_V=$AM_DEFAULT_VERBOSITY
+  AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
+fi
+AC_SUBST([AM_V])dnl
+AM_SUBST_NOTMAKE([AM_V])dnl
+AC_SUBST([AM_DEFAULT_V])dnl
+AM_SUBST_NOTMAKE([AM_DEFAULT_V])dnl
+AC_SUBST([AM_DEFAULT_VERBOSITY])dnl
+AM_BACKSLASH='\'
+AC_SUBST([AM_BACKSLASH])dnl
+_AM_SUBST_NOTMAKE([AM_BACKSLASH])dnl
+])
+
+# Copyright (C) 2001-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -868,7 +1033,7 @@ fi
 INSTALL_STRIP_PROGRAM="\$(install_sh) -c -s"
 AC_SUBST([INSTALL_STRIP_PROGRAM])])
 
-# Copyright (C) 2006-2012 Free Software Foundation, Inc.
+# Copyright (C) 2006-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -887,7 +1052,7 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
 
 # Check how to create a tarball.                            -*- Autoconf -*-
 
-# Copyright (C) 2004-2012 Free Software Foundation, Inc.
+# Copyright (C) 2004-2013 Free Software Foundation, Inc.
 #
 # This file is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -906,76 +1071,114 @@ AC_DEFUN([AM_SUBST_NOTMAKE], [_AM_SUBST_NOTMAKE($@)])
 # Substitute a variable $(am__untar) that extract such
 # a tarball read from stdin.
 #     $(am__untar) < result.tar
+#
 AC_DEFUN([_AM_PROG_TAR],
 [# Always define AMTAR for backward compatibility.  Yes, it's still used
 # in the wild :-(  We should find a proper way to deprecate it ...
 AC_SUBST([AMTAR], ['$${TAR-tar}'])
-m4_if([$1], [v7],
-     [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
-     [m4_case([$1], [ustar],, [pax],,
-              [m4_fatal([Unknown tar format])])
-AC_MSG_CHECKING([how to create a $1 tar archive])
-# Loop over all known methods to create a tar archive until one works.
+
+# We'll loop over all known methods to create a tar archive until one works.
 _am_tools='gnutar m4_if([$1], [ustar], [plaintar]) pax cpio none'
-_am_tools=${am_cv_prog_tar_$1-$_am_tools}
-# Do not fold the above two line into one, because Tru64 sh and
-# Solaris sh will not grok spaces in the rhs of '-'.
-for _am_tool in $_am_tools
-do
-  case $_am_tool in
-  gnutar)
-    for _am_tar in tar gnutar gtar;
-    do
-      AM_RUN_LOG([$_am_tar --version]) && break
-    done
-    am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
-    am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
-    am__untar="$_am_tar -xf -"
-    ;;
-  plaintar)
-    # Must skip GNU tar: if it does not support --format= it doesn't create
-    # ustar tarball either.
-    (tar --version) >/dev/null 2>&1 && continue
-    am__tar='tar chf - "$$tardir"'
-    am__tar_='tar chf - "$tardir"'
-    am__untar='tar xf -'
-    ;;
-  pax)
-    am__tar='pax -L -x $1 -w "$$tardir"'
-    am__tar_='pax -L -x $1 -w "$tardir"'
-    am__untar='pax -r'
-    ;;
-  cpio)
-    am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
-    am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
-    am__untar='cpio -i -H $1 -d'
-    ;;
-  none)
-    am__tar=false
-    am__tar_=false
-    am__untar=false
-    ;;
-  esac
 
-  # If the value was cached, stop now.  We just wanted to have am__tar
-  # and am__untar set.
-  test -n "${am_cv_prog_tar_$1}" && break
+m4_if([$1], [v7],
+  [am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'],
+
+  [m4_case([$1],
+    [ustar],
+     [# The POSIX 1988 'ustar' format is defined with fixed-size fields.
+      # There is notably a 21 bits limit for the UID and the GID.  In fact,
+      # the 'pax' utility can hang on bigger UID/GID (see automake bug#8343
+      # and bug#13588).
+      am_max_uid=2097151 # 2^21 - 1
+      am_max_gid=$am_max_uid
+      # The $UID and $GID variables are not portable, so we need to resort
+      # to the POSIX-mandated id(1) utility.  Errors in the 'id' calls
+      # below are definitely unexpected, so allow the users to see them
+      # (that is, avoid stderr redirection).
+      am_uid=`id -u || echo unknown`
+      am_gid=`id -g || echo unknown`
+      AC_MSG_CHECKING([whether UID '$am_uid' is supported by ustar format])
+      if test $am_uid -le $am_max_uid; then
+         AC_MSG_RESULT([yes])
+      else
+         AC_MSG_RESULT([no])
+         _am_tools=none
+      fi
+      AC_MSG_CHECKING([whether GID '$am_gid' is supported by ustar format])
+      if test $am_gid -le $am_max_gid; then
+         AC_MSG_RESULT([yes])
+      else
+        AC_MSG_RESULT([no])
+        _am_tools=none
+      fi],
 
-  # tar/untar a dummy directory, and stop if the command works
-  rm -rf conftest.dir
-  mkdir conftest.dir
-  echo GrepMe > conftest.dir/file
-  AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
+  [pax],
+    [],
+
+  [m4_fatal([Unknown tar format])])
+
+  AC_MSG_CHECKING([how to create a $1 tar archive])
+
+  # Go ahead even if we have the value already cached.  We do so because we
+  # need to set the values for the 'am__tar' and 'am__untar' variables.
+  _am_tools=${am_cv_prog_tar_$1-$_am_tools}
+
+  for _am_tool in $_am_tools; do
+    case $_am_tool in
+    gnutar)
+      for _am_tar in tar gnutar gtar; do
+        AM_RUN_LOG([$_am_tar --version]) && break
+      done
+      am__tar="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$$tardir"'
+      am__tar_="$_am_tar --format=m4_if([$1], [pax], [posix], [$1]) -chf - "'"$tardir"'
+      am__untar="$_am_tar -xf -"
+      ;;
+    plaintar)
+      # Must skip GNU tar: if it does not support --format= it doesn't create
+      # ustar tarball either.
+      (tar --version) >/dev/null 2>&1 && continue
+      am__tar='tar chf - "$$tardir"'
+      am__tar_='tar chf - "$tardir"'
+      am__untar='tar xf -'
+      ;;
+    pax)
+      am__tar='pax -L -x $1 -w "$$tardir"'
+      am__tar_='pax -L -x $1 -w "$tardir"'
+      am__untar='pax -r'
+      ;;
+    cpio)
+      am__tar='find "$$tardir" -print | cpio -o -H $1 -L'
+      am__tar_='find "$tardir" -print | cpio -o -H $1 -L'
+      am__untar='cpio -i -H $1 -d'
+      ;;
+    none)
+      am__tar=false
+      am__tar_=false
+      am__untar=false
+      ;;
+    esac
+
+    # If the value was cached, stop now.  We just wanted to have am__tar
+    # and am__untar set.
+    test -n "${am_cv_prog_tar_$1}" && break
+
+    # tar/untar a dummy directory, and stop if the command works.
+    rm -rf conftest.dir
+    mkdir conftest.dir
+    echo GrepMe > conftest.dir/file
+    AM_RUN_LOG([tardir=conftest.dir && eval $am__tar_ >conftest.tar])
+    rm -rf conftest.dir
+    if test -s conftest.tar; then
+      AM_RUN_LOG([$am__untar <conftest.tar])
+      AM_RUN_LOG([cat conftest.dir/file])
+      grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
+    fi
+  done
   rm -rf conftest.dir
-  if test -s conftest.tar; then
-    AM_RUN_LOG([$am__untar <conftest.tar])
-    grep GrepMe conftest.dir/file >/dev/null 2>&1 && break
-  fi
-done
-rm -rf conftest.dir
 
-AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
-AC_MSG_RESULT([$am_cv_prog_tar_$1])])
+  AC_CACHE_VAL([am_cv_prog_tar_$1], [am_cv_prog_tar_$1=$_am_tool])
+  AC_MSG_RESULT([$am_cv_prog_tar_$1])])
+
 AC_SUBST([am__tar])
 AC_SUBST([am__untar])
 ]) # _AM_PROG_TAR
diff --git a/bin/cmakehdf4 b/bin/cmakehdf4
index f7b6ac5..19f0c47 100755
--- a/bin/cmakehdf4
+++ b/bin/cmakehdf4
@@ -23,9 +23,24 @@ makelog="#${progname}_2build.log"
 testlog="#${progname}_3test.log"
 packlog="#${progname}_4pack.log"
 installlog="#${progname}_5install.log"
-srcdir="../hdf4"	# expected source directory
 exit_code=0
 
+# This command should be in the source directory's bin/
+# and should have invoked as "$srcdir/bin/$progname" or
+# "bin/$progname". So, by striping bin/$program from $0,
+# we can find $srcdir.
+if [ $0 == bin/$progname ]; then
+    srcdir="."		# current directory
+else
+    # $0 is $srdir/bin/$progname
+    srcdir=`echo $0 | sed -e s%/bin/$progname\$%%`
+fi
+# Sanity check
+if [ ! -r $srcdir/bin/$progname ]; then
+    echo "encountered error while trying to find srcdir($srdir)"
+    exit 1
+fi
+
 #=============
 # Function definitions
 #=============
@@ -99,7 +114,7 @@ fi
 echo Running Cmake for HDF4-${version} ...
 
 #      4. Configure the C library, tools and tests with this command:
-STEP "Configure..." "cmake -C ../hdf4/config/cmake/cacheinit.cmake -G 'Unix Makefiles' -DCMAKE_INSTALL_PREFIX:PATH="." -DHDF4_ALLOW_EXTERNAL_SUPPORT:STRING="SVN" -DHDF4_PACKAGE_EXTLIBS:BOOL=ON -DHDF4_BUILD_TOOLS:BOOL=ON -DHDF4_BUILD_UTILS:BOOL=ON -DBUILD_TESTING:BOOL=ON ../hdf4" $configlog
+STEP "Configure..." "cmake -C $srcdir/config/cmake/cacheinit.cmake -G 'Unix Makefiles' -DCMAKE_INSTALL_PREFIX:PATH="." -DHDF4_ALLOW_EXTERNAL_SUPPORT:STRING="SVN" -DHDF4_PACKAGE_EXTLIBS:BOOL=ON -DHDF4_BUILD_TOOLS:BOOL=ON -DHDF4_BUILD_UTILS:BOOL=ON -DBUILD_TESTING:BOOL=ON $srcdir" $configlog
       
 #      5. Build the C library, tools and tests with this command:
 STEP "Build the library, tools and tests, ..." "cmake --build . --config Release" $makelog
@@ -111,7 +126,7 @@ STEP "Test the library and tools..." "ctest . -C Release" $testlog
 STEP "Create an install image..." "cpack -C Release CPackConfig.cmake" $packlog
       
 #      8. Install with this command:
-STEP "Install..." "./HDF-4.2.10-Linux.sh --skip-license" $installlog
+STEP "Install..." "./HDF-${version}-Linux.sh --skip-license" $installlog
 # save the last exit code
 exit_code=$?
 
@@ -286,8 +301,8 @@ set($ENV{LC_MESSAGES}  "en_EN")
 #-----------------------------------------------------------------------------
 # Initialize the CTEST commands
 #------------------------------
-SET (CTEST_CMAKE_COMMAND "\"${CMAKE_COMMAND}\"")
-SET (CTEST_CONFIGURE_COMMAND
+set (CTEST_CMAKE_COMMAND "\"${CMAKE_COMMAND}\"")
+set (CTEST_CONFIGURE_COMMAND
     "${CTEST_CMAKE_COMMAND} -C \"${CTEST_SOURCE_DIRECTORY}/config/cmake/cacheinit.cmake\" -DCMAKE_BUILD_TYPE:STRING=${CTEST_BUILD_CONFIGURATION} ${BUILD_OPTIONS} \"-G${CTEST_CMAKE_GENERATOR}\" \"${CTEST_SOURCE_DIRECTORY}\"")
 
 # Print summary information.
diff --git a/bin/reconfigure b/bin/reconfigure
index 0aa0cc7..5276e74 100755
--- a/bin/reconfigure
+++ b/bin/reconfigure
@@ -19,11 +19,11 @@
 
 # HDF4 currently uses the following versions of the autotools:
 AUTOCONF_VERSION="autoconf (GNU Autoconf) 2.69"
-AUTOMAKE_VERSION="automake (GNU automake) 1.12.3"
+AUTOMAKE_VERSION="automake (GNU automake) 1.14.1"
 AUTOHEADER_VERSION="autoheader (GNU Autoconf) 2.69"
-ACLOCAL_VERSION="aclocal (GNU automake) 1.12.3"
+ACLOCAL_VERSION="aclocal (GNU automake) 1.14.1"
 LIBTOOL_VERSION="(GNU libtool) 2.4.2"
-M4_VERSION="m4 (GNU M4) 1.4.16"
+M4_VERSION="m4 (GNU M4) 1.4.17"
 
 #
 # When upgrading automake's version, don't forget to also update its
@@ -37,19 +37,19 @@ if test -z ${AUTOCONF}; then
   AUTOCONF=/mnt/hdf/packages/autoconf/autoconf-2.69/bin/autoconf
 fi
 if test -z ${AUTOMAKE}; then
-  AUTOMAKE=/mnt/hdf/packages/automake/automake-1.12.3/bin/automake-1.12
+  AUTOMAKE=/mnt/hdf/packages/automake/automake-1.14.1/bin/automake-1.14
 fi
 if test -z ${AUTOHEADER}; then
   AUTOHEADER=/mnt/hdf/packages/autoconf/autoconf-2.69/bin/autoheader
 fi
 if test -z ${ACLOCAL}; then
-  ACLOCAL=/mnt/hdf/packages/automake/automake-1.12.3/bin/aclocal-1.12
+  ACLOCAL=/mnt/hdf/packages/automake/automake-1.14.1/bin/aclocal-1.14
 fi
 if test -z ${LIBTOOL}; then
   LIBTOOL=/mnt/hdf/packages/libtool/libtool-2.4.2/bin/libtool
 fi
 if test -z ${M4}; then
-  M4=/mnt/hdf/packages/m4/m4-1.4.16/bin/m4
+  M4=/mnt/hdf/packages/m4/m4-1.4.17/bin/m4
 fi
 
 # Check version numbers of all autotools against the "correct" versions
diff --git a/bin/release b/bin/release
index adfbf2a..8e9516d 100755
--- a/bin/release
+++ b/bin/release
@@ -40,45 +40,113 @@
 USAGE()
 {
 cat << EOF
-Usage: $0 [--nocheck] [-d <dir>] [-h] <methods> ...
-   -d DIR	The name of the directory where the releas(es) should be
-                placed.  By default, the directory is ./releases
-
+Usage: $0 -d <dir> [-h] [--nocheck] [--private] <methods> ...
+   -d <dir>	The name of the directory where the releas(es) should be
+                placed.
+   -h           print the help page.
    --nocheck	Ignore errors in MANIFEST file.
-         
    --private	Make a private release with today's date in version information.
          
+This must be run at the top level of the source directory.
 The other command-line options are the names of the programs to use
 for compressing the resulting tar archive (if none are given then
 "tar md5" is assumed):
-
     tar		-- use tar and don't do any compressing.
-    compress	-- use compress and append ".Z" to the output name.
     gzip	-- use gzip with "-9" and append ".gz" to the output name.
     bzip2       -- use bzip2 with "-9" and append ".bz2" to the output name.
+    zip		-- convert all text files to DOS style and form a zip file for Windows use.
     md5         -- produce a md5 checksum in addition to the archive.
 
 Examples:
 
-    $ release
-    releases/hdf-4.2.4.tar
-    releases/hdf-4.2.4.tar.md5
+    $ bin/release -d /tmp
+    /tmp/hdf-4.2.11-RELEASE.txt
+    /tmp/hdf-4.2.11.tar
+    /tmp/hdf-4.2.11.tar.md5
 
-    $ release gzip
-    releases/hdf-4.2.4.tar.gz
+    $ bin/release -d /tmp gzip
+    /tmp/hdf-4.2.11-RELEASE.txt
+    /tmp/hdf-4.2.11.tar.gz
 
-    $ release -d /tmp tar compress gzip bzip2 md5
-    /tmp/hdf-4.2.4.tar
-    /tmp/hdf-4.2.4.tar.Z
-    /tmp/hdf-4.2.4.tar.gz
-    /tmp/hdf-4.2.4.tar.bz2
-    /tmp/hdf-4.2.4.tar.md5
+    $ bin/release -d /tmp tar gzip zip md5
+    /tmp/hdf-4.2.11-RELEASE.txt
+    /tmp/hdf-4.2.11.tar
+    /tmp/hdf-4.2.11.tar.gz
+    /tmp/hdf-4.2.11.tar.md5
+    /tmp/hdf-4.2.11.zip
 
 EOF
 
 }
 
-# This command must be run at the top level of the hdf4 source directory.
+# Function name: tar2zip
+# Convert the release tarball to a Windows zipball.
+#
+# Programmer: Albert Cheng
+# Creation date: 2014-04-23
+#
+# Modifications
+#
+# Steps:
+# 1. untar the tarball in a temporay directory;
+#    Note: do this in a temporary directory to avoid changing
+#    the original source directory which maybe around.
+# 2. convert all its text files to DOS (LF-CR) style;
+# 3. form a zip file which is usable by Windows users.
+#
+# Parameters:
+# $1 version
+# $2 release tarball
+# $3 output zipball file name
+#
+# Returns 0 if successful; 1 otherwise
+#
+tar2zip()
+{
+    if [ $# -ne 3 ]; then
+	echo "usage: tar2zip <tarfilename> <zipfilename>"
+	return 1
+    fi
+    ztmpdir=/tmp/tmpdir$$
+    mkdir -p $ztmpdir
+    version=$1
+    tarfile=$2
+    zipfile=$3
+
+    # step 1: untar tarball in ztmpdir
+    (cd $ztmpdir; tar xf -) < $tarfile
+    # sanity check
+    if [ ! -d $ztmpdir/$version ]; then
+	echo "untar did not create $ztmpdir/$version source dir"
+	# cleanup
+	rm -rf $ztmpdir
+	return 1
+    fi
+    # step 2: convert text files
+    # There maybe a simpler way to do this.
+    # options used in unix2dos:
+    # -k   Keep the date stamp 
+    # -q   quiet mode
+    # grep redirect output to /dev/null because -q or -s are not portable.
+    find $ztmpdir/$version | \
+	while read inf; do \
+	    if file $inf | grep "$inf\: .*text" > /dev/null 2>&1 ; then \
+		unix2dos -q -k $inf; \
+	    fi\
+	done
+    # step 3: make zipball
+    # -9 maximum compression
+    # -y Store symbolic links as such in the zip archive
+    # -r recursive
+    # -q quiet
+    (cd $ztmpdir; zip -9 -y -r -q $version.zip $version)
+    mv $ztmpdir/$version.zip $zipfile
+
+    # cleanup
+    rm -rf $ztmpdir
+}
+
+# This command must be run at the top level of the hdf5 source directory.
 # Verify this requirement.
 if [ ! \( -f configure -a -f bin/release \) ]; then
     echo "$0 must be run at the top level of the hdf4 source directory"
@@ -97,18 +165,11 @@ today=`date +%Y%m%d`
 pmode='no'
 tmpdir="../#release_tmp.$$"	# tmp work directory
 
-# artifacts from hdf5, not currently used for hdf4
-#DOC_URL=http://svn.hdfgroup.uiuc.edu/hdf4doc/trunk
-#CPPLUS_RM_NAME=cpplus_RM
-
 # Restore previous Version information
 RESTORE_VERSION()
 {
     if [ X-${VERS_OLD} != X- ]; then
 	echo restoring version information back to $VERS_OLD
-# configure/libtool to be considered after initial release script works
-#	rm -f config/lt_vers.am
-#	cp $tmpdir/lt_vers.am config/lt_vers.am
 	bin/h4vers -s $VERS_OLD
 	VERS_OLD=
     fi
@@ -164,10 +225,6 @@ trap RESTORE_VERSION 0
 
 if [ X$pmode = Xyes ]; then
     VERS_OLD=$VERS
-    # Copy old version of config/lt_vers.am, since it's hard to
-    # "undo" changes to it.
-# configure - later
-#    cp config/lt_vers.am $tmpdir
     # Set version information to m.n.r-of$today.
     # (h4vers does not correctly handle just m.n.r-$today.)
     VERS=`echo $VERS | sed -e s/-.*//`-of$today
@@ -175,7 +232,7 @@ if [ X$pmode = Xyes ]; then
     bin/h4vers -s $VERS
 fi
 
-# Store hdf4-$VERS ("hdf-4.2.4", e.g.) to a variable to avoid typos
+# Store hdf4-$VERS ("hdf-4.2.11", e.g.) to a variable to avoid typos
 HDF4_VERS=hdf-$VERS
 
 test "$verbose" && echo "Releasing $HDF4_VERS to $DEST" 1>&2
@@ -200,7 +257,6 @@ grep '^\.' MANIFEST | grep -v _DO_NOT_DISTRIBUTE_ >$MANIFEST
 
 # Prepare the source tree for a release.
 ln -s `pwd` $tmpdir/$HDF4_VERS || exit 1
-mv Makefile $tmpdir/Makefile.x 2>/dev/null #might fail
 # Save a backup copy of Makefile if exists.
 test -f Makefile && mv Makefile $tmpdir/Makefile.x
 cp -p Makefile.dist Makefile
@@ -229,10 +285,6 @@ for comp in $methods; do
 	tar)
 	    cp -p $tmpdir/$HDF4_VERS.tar $DEST/$HDF4_VERS.tar
 	    ;;
-	compress)
-	    test "$verbose" && echo "   Running compress..." 1>&2
-	    compress -c <$tmpdir/$HDF4_VERS.tar >$DEST/$HDF4_VERS.tar.Z
-	    ;;
 	gzip)
 	    test "$verbose" && echo "   Running gzip..." 1>&2
 	    gzip -9 <$tmpdir/$HDF4_VERS.tar >$DEST/$HDF4_VERS.tar.gz
@@ -241,32 +293,25 @@ for comp in $methods; do
 	    test "$verbose" && echo "   Running bzip2..." 1>&2
 	    bzip2 -9 <$tmpdir/$HDF4_VERS.tar >$DEST/$HDF4_VERS.tar.bz2
 	    ;;
+	zip)
+	    test "$verbose" && echo "   Creating zip ball..." 1>&2
+	    tar2zip $HDF4_VERS $tmpdir/$HDF4_VERS.tar $DEST/$HDF4_VERS.zip 1>&2
+	    ;;
 	md5)
 	    test "$verbose" && echo "   Creating checksum..." 1>&2
 	    (cd $tmpdir; md5sum $HDF4_VERS.tar ) > $DEST/$HDF4_VERS.tar.md5
 	    ;;
-# doc option from hdf5 - not supported for hdf4
-#	doc)
-#	    test "$verbose" && echo "   Creating docs..." 1>&2
-#	    # Check out docs from svn repo
-#	    (cd $tmpdir; svn co $DOC_URL > /dev/null) || exit 1
-#	    # Create doxygen C++ RM
-#	    (cd c++/src && doxygen cpp_doc_config > /dev/null ) || exit 1
-#	    # Replace version of C++ RM with just-created version
-#	    rm -rf $tmpdir/trunk/html/$CPPLUS_RM_NAME
-#	    mv c++/src/$CPPLUS_RM_NAME $tmpdir/trunk/html/$CPPLUS_RM_NAME
-#	    # Compress the docs and move them to the release area
-#	    mv $tmpdir/trunk $tmpdir/${HDF4_VERS}_docs
-#	    (cd $tmpdir && tar cf ${HDF4_VERS}_docs.tar ${HDF4_VERS}_docs)
-#	    mv $tmpdir/${HDF4_VERS}_docs.tar $DEST
-#	    ;;
+	*)
+	    echo "***Error*** Unknown method $comp"
+	    exit 1
+	    ;;
     esac
 done
 
 # Copy the RELEASE.txt to the release area.
 cp release_notes/RELEASE.txt $DEST/$HDF4_VERS-RELEASE.txt
 
-# Restore previous Makefile if existed.
+# Remove distributed Makefile and restore previous Makefile if existed.
 rm -f Makefile
 test -f $tmpdir/Makefile.x && mv $tmpdir/Makefile.x Makefile
 
diff --git a/bin/test-driver b/bin/test-driver
new file mode 100755
index 0000000..d306056
--- /dev/null
+++ b/bin/test-driver
@@ -0,0 +1,139 @@
+#! /bin/sh
+# test-driver - basic testsuite driver script.
+
+scriptversion=2013-07-13.22; # UTC
+
+# Copyright (C) 2011-2013 Free Software Foundation, Inc.
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program.  If not, see <http://www.gnu.org/licenses/>.
+
+# As a special exception to the GNU General Public License, if you
+# distribute this file as part of a program that contains a
+# configuration script generated by Autoconf, you may include it under
+# the same distribution terms that you use for the rest of that program.
+
+# This file is maintained in Automake, please report
+# bugs to <bug-automake at gnu.org> or send patches to
+# <automake-patches at gnu.org>.
+
+# Make unconditional expansion of undefined variables an error.  This
+# helps a lot in preventing typo-related bugs.
+set -u
+
+usage_error ()
+{
+  echo "$0: $*" >&2
+  print_usage >&2
+  exit 2
+}
+
+print_usage ()
+{
+  cat <<END
+Usage:
+  test-driver --test-name=NAME --log-file=PATH --trs-file=PATH
+              [--expect-failure={yes|no}] [--color-tests={yes|no}]
+              [--enable-hard-errors={yes|no}] [--]
+              TEST-SCRIPT [TEST-SCRIPT-ARGUMENTS]
+The '--test-name', '--log-file' and '--trs-file' options are mandatory.
+END
+}
+
+test_name= # Used for reporting.
+log_file=  # Where to save the output of the test script.
+trs_file=  # Where to save the metadata of the test run.
+expect_failure=no
+color_tests=no
+enable_hard_errors=yes
+while test $# -gt 0; do
+  case $1 in
+  --help) print_usage; exit $?;;
+  --version) echo "test-driver $scriptversion"; exit $?;;
+  --test-name) test_name=$2; shift;;
+  --log-file) log_file=$2; shift;;
+  --trs-file) trs_file=$2; shift;;
+  --color-tests) color_tests=$2; shift;;
+  --expect-failure) expect_failure=$2; shift;;
+  --enable-hard-errors) enable_hard_errors=$2; shift;;
+  --) shift; break;;
+  -*) usage_error "invalid option: '$1'";;
+   *) break;;
+  esac
+  shift
+done
+
+missing_opts=
+test x"$test_name" = x && missing_opts="$missing_opts --test-name"
+test x"$log_file"  = x && missing_opts="$missing_opts --log-file"
+test x"$trs_file"  = x && missing_opts="$missing_opts --trs-file"
+if test x"$missing_opts" != x; then
+  usage_error "the following mandatory options are missing:$missing_opts"
+fi
+
+if test $# -eq 0; then
+  usage_error "missing argument"
+fi
+
+if test $color_tests = yes; then
+  # Keep this in sync with 'lib/am/check.am:$(am__tty_colors)'.
+  red='' # Red.
+  grn='' # Green.
+  lgn='' # Light green.
+  blu='' # Blue.
+  mgn='' # Magenta.
+  std=''     # No color.
+else
+  red= grn= lgn= blu= mgn= std=
+fi
+
+do_exit='rm -f $log_file $trs_file; (exit $st); exit $st'
+trap "st=129; $do_exit" 1
+trap "st=130; $do_exit" 2
+trap "st=141; $do_exit" 13
+trap "st=143; $do_exit" 15
+
+# Test script is run here.
+"$@" >$log_file 2>&1
+estatus=$?
+if test $enable_hard_errors = no && test $estatus -eq 99; then
+  estatus=1
+fi
+
+case $estatus:$expect_failure in
+  0:yes) col=$red res=XPASS recheck=yes gcopy=yes;;
+  0:*)   col=$grn res=PASS  recheck=no  gcopy=no;;
+  77:*)  col=$blu res=SKIP  recheck=no  gcopy=yes;;
+  99:*)  col=$mgn res=ERROR recheck=yes gcopy=yes;;
+  *:yes) col=$lgn res=XFAIL recheck=no  gcopy=yes;;
+  *:*)   col=$red res=FAIL  recheck=yes gcopy=yes;;
+esac
+
+# Report outcome to console.
+echo "${col}${res}${std}: $test_name"
+
+# Register the test result, and other relevant metadata.
+echo ":test-result: $res" > $trs_file
+echo ":global-test-result: $res" >> $trs_file
+echo ":recheck: $recheck" >> $trs_file
+echo ":copy-in-global-log: $gcopy" >> $trs_file
+
+# Local Variables:
+# mode: shell-script
+# sh-indentation: 2
+# eval: (add-hook 'write-file-hooks 'time-stamp)
+# time-stamp-start: "scriptversion="
+# time-stamp-format: "%:y-%02m-%02d.%02H"
+# time-stamp-time-zone: "UTC"
+# time-stamp-end: "; # UTC"
+# End:
diff --git a/config/cmake/CTestCustom.cmake b/config/cmake/CTestCustom.cmake
index 0c4d718..634dc21 100644
--- a/config/cmake/CTestCustom.cmake
+++ b/config/cmake/CTestCustom.cmake
@@ -1,6 +1,6 @@
-SET (CTEST_CUSTOM_MAXIMUM_NUMBER_OF_WARNINGS 1500)
+set (CTEST_CUSTOM_MAXIMUM_NUMBER_OF_WARNINGS 1500)
 
-SET (CTEST_CUSTOM_WARNING_EXCEPTION
+set (CTEST_CUSTOM_WARNING_EXCEPTION
     ${CTEST_CUSTOM_WARNING_EXCEPTION}
     "note.*expected.*void.*but argument is of type.*volatile"
     "SZIP.src.*:[ \t]*warning"
@@ -11,7 +11,7 @@ SET (CTEST_CUSTOM_WARNING_EXCEPTION
 )
  
  
-SET (CTEST_CUSTOM_MEMCHECK_IGNORE
+set (CTEST_CUSTOM_MEMCHECK_IGNORE
     ${CTEST_CUSTOM_MEMCHECK_IGNORE}
     hdfpack-clear-refs
     hdfpalette-clear-refs
diff --git a/config/cmake/CheckTypeSize.cmake b/config/cmake/CheckTypeSize.cmake
deleted file mode 100644
index 8d51a64..0000000
--- a/config/cmake/CheckTypeSize.cmake
+++ /dev/null
@@ -1,48 +0,0 @@
-#
-# Check if the type exists and determine size of type.  if the type
-# exists, the size will be stored to the variable.
-#
-# CHECK_TYPE_SIZE - macro which checks the size of type
-# VARIABLE - variable to store size if the type exists.
-# HAVE_${VARIABLE} - does the variable exists or not
-#
-
-MACRO (HDF_CHECK_TYPE_SIZE TYPE VARIABLE)
-  SET (CMAKE_ALLOW_UNKNOWN_VARIABLE_READ_ACCESS 1)
-  IF ("HAVE_${VARIABLE}" MATCHES "^HAVE_${VARIABLE}$")
-    SET (MACRO_CHECK_TYPE_SIZE_FLAGS 
-        "-DCHECK_TYPE_SIZE_TYPE=\"${TYPE}\" ${CMAKE_REQUIRED_FLAGS}"
-    )
-    FOREACH (def HAVE_SYS_TYPES_H HAVE_STDINT_H HAVE_STDDEF_H HAVE_INTTYPES_H)
-      IF ("${def}")
-        SET (MACRO_CHECK_TYPE_SIZE_FLAGS "${MACRO_CHECK_TYPE_SIZE_FLAGS} -D${def}")
-      ENDIF("${def}")
-    ENDFOREACH (def)
-
-    MESSAGE (STATUS "Check size of ${TYPE}")
-    IF (CMAKE_REQUIRED_LIBRARIES)
-      SET (CHECK_TYPE_SIZE_ADD_LIBRARIES 
-          "-DLINK_LIBRARIES:STRING=${CMAKE_REQUIRED_LIBRARIES}"
-      )
-    ENDIF (CMAKE_REQUIRED_LIBRARIES)
-    TRY_RUN (${VARIABLE} HAVE_${VARIABLE}
-        ${CMAKE_BINARY_DIR}
-        ${HDF4_RESOURCES_DIR}/CheckTypeSize.c
-        CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${MACRO_CHECK_TYPE_SIZE_FLAGS}
-        "${CHECK_TYPE_SIZE_ADD_LIBRARIES}"
-        OUTPUT_VARIABLE OUTPUT
-    )
-    IF (HAVE_${VARIABLE})
-      MESSAGE (STATUS "Check size of ${TYPE} - done")
-      FILE (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeOutput.log 
-          "Determining size of ${TYPE} passed with the following output:\n${OUTPUT}\n\n"
-      )
-    ELSE (HAVE_${VARIABLE})
-      MESSAGE (STATUS "Check size of ${TYPE} - failed")
-      FILE (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log 
-          "Determining size of ${TYPE} failed with the following output:\n${OUTPUT}\n\n"
-      )
-    ENDIF (HAVE_${VARIABLE})
-  ENDIF ("HAVE_${VARIABLE}" MATCHES "^HAVE_${VARIABLE}$")
-  SET (CMAKE_ALLOW_UNKNOWN_VARIABLE_READ_ACCESS)
-ENDMACRO (HDF_CHECK_TYPE_SIZE)
diff --git a/config/cmake/ConfigureChecks.cmake b/config/cmake/ConfigureChecks.cmake
index 341c91c..fada58b 100644
--- a/config/cmake/ConfigureChecks.cmake
+++ b/config/cmake/ConfigureChecks.cmake
@@ -1,365 +1,20 @@
 #-----------------------------------------------------------------------------
 # Include all the necessary files for macros
 #-----------------------------------------------------------------------------
-INCLUDE (${CMAKE_ROOT}/Modules/CheckFunctionExists.cmake)
-INCLUDE (${CMAKE_ROOT}/Modules/CheckIncludeFile.cmake)
-INCLUDE (${CMAKE_ROOT}/Modules/CheckIncludeFileCXX.cmake)
-INCLUDE (${CMAKE_ROOT}/Modules/CheckIncludeFiles.cmake)
-INCLUDE (${CMAKE_ROOT}/Modules/CheckLibraryExists.cmake)
-INCLUDE (${CMAKE_ROOT}/Modules/CheckSymbolExists.cmake)
-INCLUDE (${CMAKE_ROOT}/Modules/CheckTypeSize.cmake)
-INCLUDE (${CMAKE_ROOT}/Modules/CheckVariableExists.cmake)
-INCLUDE (${CMAKE_ROOT}/Modules/CheckFortranFunctionExists.cmake)
-INCLUDE (${CMAKE_ROOT}/Modules/TestBigEndian.cmake)
-INCLUDE (${CMAKE_ROOT}/Modules/TestForSTDNamespace.cmake)
-
-#-----------------------------------------------------------------------------
-# Always SET this for now IF we are on an OS X box
-#-----------------------------------------------------------------------------
-IF (APPLE)
-  LIST(LENGTH CMAKE_OSX_ARCHITECTURES ARCH_LENGTH)
-  IF(ARCH_LENGTH GREATER 1)
-    set (CMAKE_OSX_ARCHITECTURES "" CACHE STRING "" FORCE)
-    message(FATAL_ERROR "Building Universal Binaries on OS X is NOT supported by the HDF5 project. This is"
-    "due to technical reasons. The best approach would be build each architecture in separate directories"
-    "and use the 'lipo' tool to combine them into a single executable or library. The 'CMAKE_OSX_ARCHITECTURES'"
-    "variable has been set to a blank value which will build the default architecture for this system.")
-  ENDIF()
-  SET (H4_AC_APPLE_UNIVERSAL_BUILD 0)
-ENDIF (APPLE)
+set (HDF_PREFIX "H4")
+include (${HDF_RESOURCES_EXT_DIR}/ConfigureChecks.cmake)
+include (${CMAKE_ROOT}/Modules/TestForSTDNamespace.cmake)
 
 #-----------------------------------------------------------------------------
 # Option to Build HDF4 versions of NetCDF-3 APIS
 #-----------------------------------------------------------------------------
-OPTION (HDF4_ENABLE_NETCDF "Build HDF4 versions of NetCDF-3 APIS" ON)
-IF (HDF4_ENABLE_NETCDF)
-  SET (H4_HAVE_NETCDF 1)
-ENDIF (HDF4_ENABLE_NETCDF)
-
-#-----------------------------------------------------------------------------
-# This MACRO checks IF the symbol exists in the library and IF it
-# does, it appends library to the list.
-#-----------------------------------------------------------------------------
-SET (LINK_LIBS "")
-MACRO (CHECK_LIBRARY_EXISTS_CONCAT LIBRARY SYMBOL VARIABLE)
-  CHECK_LIBRARY_EXISTS ("${LIBRARY};${LINK_LIBS}" ${SYMBOL} "" ${VARIABLE})
-  IF (${VARIABLE})
-    SET (LINK_LIBS ${LINK_LIBS} ${LIBRARY})
-  ENDIF (${VARIABLE})
-ENDMACRO (CHECK_LIBRARY_EXISTS_CONCAT)
-
-# ----------------------------------------------------------------------
-# WINDOWS Hard code Values
-# ----------------------------------------------------------------------
-
-SET (WINDOWS)
-IF (WIN32)
-  IF (MINGW)
-    SET (WINDOWS 1) # MinGW tries to imitate Windows
-    SET (CMAKE_REQUIRED_FLAGS "-DWIN32_LEAN_AND_MEAN=1 -DNOGDI=1")
-  ENDIF (MINGW)
-  SET (CMAKE_REQUIRED_LIBRARIES "ws2_32.lib;wsock32.lib")
-  IF (NOT UNIX AND NOT CYGWIN AND NOT MINGW)
-    SET (WINDOWS 1)
-    SET (CMAKE_REQUIRED_FLAGS "/DWIN32_LEAN_AND_MEAN=1 /DNOGDI=1")
-  ENDIF (NOT UNIX AND NOT CYGWIN AND NOT MINGW)
-ENDIF (WIN32)
-
-IF (WINDOWS)
-  SET (H4_HAVE_STDDEF_H 1)
-  SET (H4_HAVE_SYS_STAT_H 1)
-  SET (H4_HAVE_SYS_TYPES_H 1)
-  SET (H4_HAVE_LIBM 1)
-  SET (H4_HAVE_STRDUP 1)
-  SET (H4_HAVE_SYSTEM 1)
-  SET (H4_HAVE_LONGJMP 1)
-  IF (NOT MINGW)
-    SET (H4_HAVE_GETHOSTNAME 1)
-  ENDIF (NOT MINGW)
-  IF (NOT UNIX AND NOT CYGWIN AND NOT MINGW)
-    SET (H4_HAVE_GETCONSOLESCREENBUFFERINFO 1)
-  ENDIF (NOT UNIX AND NOT CYGWIN AND NOT MINGW)
-  SET (H4_HAVE_FUNCTION 1)
-  SET (H4_HAVE_TIMEZONE 1)
-  IF (MINGW)
-    SET (H4_HAVE_WINSOCK2_H 1)
-  ENDIF (MINGW)
-  SET (H4_HAVE_LIBWS2_32 1)
-  SET (H4_HAVE_LIBWSOCK32 1)
-ENDIF (WINDOWS)
-
-# ----------------------------------------------------------------------
-# END of WINDOWS Hard code Values
-# ----------------------------------------------------------------------
-
-IF (CYGWIN)
-  CHECK_LIBRARY_EXISTS_CONCAT ("rpc" xdr_opaque     H4_HAVE_RPC)
-ENDIF (CYGWIN)
-
-#-----------------------------------------------------------------------------
-#  Check for the math library "m"
-#-----------------------------------------------------------------------------
-IF (NOT WINDOWS)
-  CHECK_LIBRARY_EXISTS_CONCAT ("m" ceil     H4_HAVE_LIBM)
-  CHECK_LIBRARY_EXISTS_CONCAT ("ws2_32" WSAStartup  H4_HAVE_LIBWS2_32)
-  CHECK_LIBRARY_EXISTS_CONCAT ("wsock32" gethostbyname H4_HAVE_LIBWSOCK32)
-ENDIF (NOT WINDOWS)
-
-CHECK_LIBRARY_EXISTS_CONCAT ("ucb"    gethostname  H4_HAVE_LIBUCB)
-CHECK_LIBRARY_EXISTS_CONCAT ("socket" connect      H4_HAVE_LIBSOCKET)
-CHECK_LIBRARY_EXISTS ("c" gethostbyname "" NOT_NEED_LIBNSL)
-
-IF (NOT NOT_NEED_LIBNSL)
-  CHECK_LIBRARY_EXISTS_CONCAT ("nsl"    gethostbyname  H4_HAVE_LIBNSL)
-ENDIF (NOT NOT_NEED_LIBNSL)
-
-# For other tests to use the same libraries
-SET (CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} ${LINK_LIBS})
-
-SET (USE_INCLUDES "")
-IF (WINDOWS)
-  SET (USE_INCLUDES ${USE_INCLUDES} "windows.h")
-ENDIF (WINDOWS)
-
-IF (NOT WINDOWS)
-  TEST_BIG_ENDIAN(H4_WORDS_BIGENDIAN)
-ENDIF (NOT WINDOWS)
-
-# For other specific tests, use this MACRO.
-MACRO (HDF_FUNCTION_TEST OTHER_TEST)
-  IF ("H4_${OTHER_TEST}" MATCHES "^H4_${OTHER_TEST}$")
-    SET (MACRO_CHECK_FUNCTION_DEFINITIONS "-D${OTHER_TEST} ${CMAKE_REQUIRED_FLAGS}")
-    SET (OTHER_TEST_ADD_LIBRARIES)
-    IF (CMAKE_REQUIRED_LIBRARIES)
-      SET (OTHER_TEST_ADD_LIBRARIES "-DLINK_LIBRARIES:STRING=${CMAKE_REQUIRED_LIBRARIES}")
-    ENDIF (CMAKE_REQUIRED_LIBRARIES)
-
-    FOREACH (def ${HDF_EXTRA_TEST_DEFINITIONS})
-      SET (MACRO_CHECK_FUNCTION_DEFINITIONS "${MACRO_CHECK_FUNCTION_DEFINITIONS} -D${def}=${${def}}")
-    ENDFOREACH (def)
-
-    FOREACH (def
-        HAVE_SYS_TIME_H
-        HAVE_UNISTD_H
-        HAVE_SYS_TYPES_H
-        HAVE_SYS_SOCKET_H
-    )
-      IF ("${H4_${def}}")
-        SET (MACRO_CHECK_FUNCTION_DEFINITIONS "${MACRO_CHECK_FUNCTION_DEFINITIONS} -D${def}")
-      ENDIF ("${H4_${def}}")
-    ENDFOREACH (def)
-
-    IF (LARGEFILE)
-      SET (MACRO_CHECK_FUNCTION_DEFINITIONS
-          "${MACRO_CHECK_FUNCTION_DEFINITIONS} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE"
-      )
-    ENDIF (LARGEFILE)
-
-    #MESSAGE (STATUS "Performing ${OTHER_TEST}")
-    TRY_COMPILE (${OTHER_TEST}
-        ${CMAKE_BINARY_DIR}
-        ${HDF4_RESOURCES_DIR}/HDFTests.c
-        CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${MACRO_CHECK_FUNCTION_DEFINITIONS}
-        "${OTHER_TEST_ADD_LIBRARIES}"
-        OUTPUT_VARIABLE OUTPUT
-    )
-    IF (${OTHER_TEST})
-      SET (H4_${OTHER_TEST} 1 CACHE INTERNAL "Other test ${FUNCTION}")
-      MESSAGE (STATUS "Performing Other Test ${OTHER_TEST} - Success")
-    ELSE (${OTHER_TEST})
-      MESSAGE (STATUS "Performing Other Test ${OTHER_TEST} - Failed")
-      SET (H4_${OTHER_TEST} "" CACHE INTERNAL "Other test ${FUNCTION}")
-      FILE (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log
-          "Performing Other Test ${OTHER_TEST} failed with the following output:\n"
-          "${OUTPUT}\n"
-      )
-    ENDIF (${OTHER_TEST})
-  ENDIF ("H4_${OTHER_TEST}" MATCHES "^H4_${OTHER_TEST}$")
-ENDMACRO (HDF_FUNCTION_TEST)
-
-#-----------------------------------------------------------------------------
-HDF_FUNCTION_TEST (STDC_HEADERS)
-
-#-----------------------------------------------------------------------------
-# Check IF header file exists and add it to the list.
-#-----------------------------------------------------------------------------
-MACRO (CHECK_INCLUDE_FILE_CONCAT FILE VARIABLE)
-  CHECK_INCLUDE_FILES ("${USE_INCLUDES};${FILE}" ${VARIABLE})
-  IF (${VARIABLE})
-    SET (USE_INCLUDES ${USE_INCLUDES} ${FILE})
-  ENDIF (${VARIABLE})
-ENDMACRO (CHECK_INCLUDE_FILE_CONCAT)
-
-#-----------------------------------------------------------------------------
-#  Check for the existence of certain header files
-#-----------------------------------------------------------------------------
-CHECK_INCLUDE_FILE_CONCAT ("unistd.h"        H4_HAVE_UNISTD_H)
-CHECK_INCLUDE_FILE_CONCAT ("sys/stat.h"      H4_HAVE_SYS_STAT_H)
-CHECK_INCLUDE_FILE_CONCAT ("sys/types.h"     H4_HAVE_SYS_TYPES_H)
-CHECK_INCLUDE_FILE_CONCAT ("stddef.h"        H4_HAVE_STDDEF_H)
-CHECK_INCLUDE_FILE_CONCAT ("stdint.h"        H4_HAVE_STDINT_H)
-
-# IF the c compiler found stdint, check the C++ as well. On some systems this
-# file will be found by C but not C++, only do this test IF the C++ compiler
-# has been initialized (e.g. the project also includes some c++)
-IF (H4_HAVE_STDINT_H AND CMAKE_CXX_COMPILER_LOADED)
-  CHECK_INCLUDE_FILE_CXX ("stdint.h" H4_HAVE_STDINT_H_CXX)
-  IF (NOT H4_HAVE_STDINT_H_CXX)
-    SET (H4_HAVE_STDINT_H "" CACHE INTERNAL "Have includes HAVE_STDINT_H")
-    SET (USE_INCLUDES ${USE_INCLUDES} "stdint.h")
-  ENDIF (NOT H4_HAVE_STDINT_H_CXX)
-ENDIF (H4_HAVE_STDINT_H AND CMAKE_CXX_COMPILER_LOADED)
-
-# Windows
-IF (NOT CYGWIN)
-  CHECK_INCLUDE_FILE_CONCAT ("winsock2.h"      H4_HAVE_WINSOCK2_H)
-ENDIF (NOT CYGWIN)
-CHECK_INCLUDE_FILE_CONCAT ("pthread.h"       H4_HAVE_PTHREAD_H)
-CHECK_INCLUDE_FILE_CONCAT ("string.h"        H4_HAVE_STRING_H)
-CHECK_INCLUDE_FILE_CONCAT ("strings.h"       H4_HAVE_STRINGS_H)
-CHECK_INCLUDE_FILE_CONCAT ("stdlib.h"        H4_HAVE_STDLIB_H)
-CHECK_INCLUDE_FILE_CONCAT ("memory.h"        H4_HAVE_MEMORY_H)
-CHECK_INCLUDE_FILE_CONCAT ("dlfcn.h"         H4_HAVE_DLFCN_H)
-CHECK_INCLUDE_FILE_CONCAT ("inttypes.h"      H4_HAVE_INTTYPES_H)
-
-#-----------------------------------------------------------------------------
-#  Check for large file support
-#-----------------------------------------------------------------------------
-
-# The linux-lfs option is deprecated.
-SET (LINUX_LFS 0)
-
-SET (HDF_EXTRA_FLAGS)
-IF (NOT WINDOWS)
-  # Linux Specific flags
-#  Removed _POSIX_SOURCE due to OS X build errors
-    SET (HDF_EXTRA_FLAGS -D_BSD_SOURCE)
-  OPTION (HDF_ENABLE_LARGE_FILE "Enable support for large (64-bit) files on Linux." ON)
-  IF (HDF_ENABLE_LARGE_FILE)
-    SET (msg "Performing TEST_LFS_WORKS")
-    TRY_RUN (TEST_LFS_WORKS_RUN   TEST_LFS_WORKS_COMPILE
-        ${HDF4_BINARY_DIR}/CMake
-        ${HDF4_RESOURCES_DIR}/HDFTests.c
-        CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=-DTEST_LFS_WORKS
-        OUTPUT_VARIABLE OUTPUT
-    )
-    IF (TEST_LFS_WORKS_COMPILE)
-      IF (TEST_LFS_WORKS_RUN  MATCHES 0)
-        SET (TEST_LFS_WORKS 1 CACHE INTERNAL ${msg})
-        SET (LARGEFILE 1)
-        SET (HDF_EXTRA_FLAGS ${HDF_EXTRA_FLAGS} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE)
-        MESSAGE (STATUS "${msg}... yes")
-      ELSE (TEST_LFS_WORKS_RUN  MATCHES 0)
-        SET (TEST_LFS_WORKS "" CACHE INTERNAL ${msg})
-        MESSAGE (STATUS "${msg}... no")
-        FILE (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log
-              "Test TEST_LFS_WORKS Run failed with the following output and exit code:\n ${OUTPUT}\n"
-        )
-      ENDIF (TEST_LFS_WORKS_RUN  MATCHES 0)
-    ELSE (TEST_LFS_WORKS_COMPILE )
-      SET (TEST_LFS_WORKS "" CACHE INTERNAL ${msg})
-      MESSAGE (STATUS "${msg}... no")
-      FILE (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log
-          "Test TEST_LFS_WORKS Compile failed with the following output:\n ${OUTPUT}\n"
-      )
-    ENDIF (TEST_LFS_WORKS_COMPILE)
-  ENDIF (HDF_ENABLE_LARGE_FILE)
-  SET (CMAKE_REQUIRED_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS} ${HDF_EXTRA_FLAGS})
-ENDIF (NOT WINDOWS)
-
-ADD_DEFINITIONS (${HDF_EXTRA_FLAGS})
-
-#-----------------------------------------------------------------------------
-#  Check the size in bytes of all the int and float types
-#-----------------------------------------------------------------------------
-MACRO (H4_CHECK_TYPE_SIZE type var)
-  SET (aType ${type})
-  SET (aVar  ${var})
-#  MESSAGE (STATUS "Checking size of ${aType} and storing into ${aVar}")
-  CHECK_TYPE_SIZE (${aType}   ${aVar})
-  IF (NOT ${aVar})
-    SET (${aVar} 0 CACHE INTERNAL "SizeOf for ${aType}")
-#    MESSAGE (STATUS "Size of ${aType} was NOT Found")
-  ENDIF (NOT ${aVar})
-ENDMACRO (H4_CHECK_TYPE_SIZE)
-
-
-H4_CHECK_TYPE_SIZE (char           H4_SIZEOF_CHAR)
-H4_CHECK_TYPE_SIZE (short          H4_SIZEOF_SHORT)
-H4_CHECK_TYPE_SIZE (int            H4_SIZEOF_INT)
-H4_CHECK_TYPE_SIZE (unsigned       H4_SIZEOF_UNSIGNED)
-IF (NOT APPLE)
-  H4_CHECK_TYPE_SIZE (long         H4_SIZEOF_LONG)
-ENDIF (NOT APPLE)
-H4_CHECK_TYPE_SIZE ("long long"    H4_SIZEOF_LONG_LONG)
-H4_CHECK_TYPE_SIZE (__int64        H4_SIZEOF___INT64)
-IF (NOT H4_SIZEOF___INT64)
-  SET (H4_SIZEOF___INT64 0)
-ENDIF (NOT H4_SIZEOF___INT64)
-
-H4_CHECK_TYPE_SIZE (float          H4_SIZEOF_FLOAT)
-H4_CHECK_TYPE_SIZE (double         H4_SIZEOF_DOUBLE)
-H4_CHECK_TYPE_SIZE ("long double"  H4_SIZEOF_LONG_DOUBLE)
-
-H4_CHECK_TYPE_SIZE (int8_t         H4_SIZEOF_INT8_T)
-H4_CHECK_TYPE_SIZE (uint8_t        H4_SIZEOF_UINT8_T)
-H4_CHECK_TYPE_SIZE (int_least8_t   H4_SIZEOF_INT_LEAST8_T)
-H4_CHECK_TYPE_SIZE (uint_least8_t  H4_SIZEOF_UINT_LEAST8_T)
-H4_CHECK_TYPE_SIZE (int_fast8_t    H4_SIZEOF_INT_FAST8_T)
-H4_CHECK_TYPE_SIZE (uint_fast8_t   H4_SIZEOF_UINT_FAST8_T)
-
-H4_CHECK_TYPE_SIZE (int16_t        H4_SIZEOF_INT16_T)
-H4_CHECK_TYPE_SIZE (uint16_t       H4_SIZEOF_UINT16_T)
-H4_CHECK_TYPE_SIZE (int_least16_t  H4_SIZEOF_INT_LEAST16_T)
-H4_CHECK_TYPE_SIZE (uint_least16_t H4_SIZEOF_UINT_LEAST16_T)
-H4_CHECK_TYPE_SIZE (int_fast16_t   H4_SIZEOF_INT_FAST16_T)
-H4_CHECK_TYPE_SIZE (uint_fast16_t  H4_SIZEOF_UINT_FAST16_T)
-
-H4_CHECK_TYPE_SIZE (int32_t        H4_SIZEOF_INT32_T)
-H4_CHECK_TYPE_SIZE (uint32_t       H4_SIZEOF_UINT32_T)
-H4_CHECK_TYPE_SIZE (int_least32_t  H4_SIZEOF_INT_LEAST32_T)
-H4_CHECK_TYPE_SIZE (uint_least32_t H4_SIZEOF_UINT_LEAST32_T)
-H4_CHECK_TYPE_SIZE (int_fast32_t   H4_SIZEOF_INT_FAST32_T)
-H4_CHECK_TYPE_SIZE (uint_fast32_t  H4_SIZEOF_UINT_FAST32_T)
+option (HDF4_ENABLE_NETCDF "Build HDF4 versions of NetCDF-3 APIS" ON)
+if (HDF4_ENABLE_NETCDF)
+  set (${HDF_PREFIX}_HAVE_NETCDF 1)
+endif (HDF4_ENABLE_NETCDF)
 
-H4_CHECK_TYPE_SIZE (int64_t        H4_SIZEOF_INT64_T)
-H4_CHECK_TYPE_SIZE (uint64_t       H4_SIZEOF_UINT64_T)
-H4_CHECK_TYPE_SIZE (int_least64_t  H4_SIZEOF_INT_LEAST64_T)
-H4_CHECK_TYPE_SIZE (uint_least64_t H4_SIZEOF_UINT_LEAST64_T)
-H4_CHECK_TYPE_SIZE (int_fast64_t   H4_SIZEOF_INT_FAST64_T)
-H4_CHECK_TYPE_SIZE (uint_fast64_t  H4_SIZEOF_UINT_FAST64_T)
-IF (NOT APPLE)
-  H4_CHECK_TYPE_SIZE (size_t       H4_SIZEOF_SIZE_T)
-  H4_CHECK_TYPE_SIZE (ssize_t      H4_SIZEOF_SSIZE_T)
-  IF (NOT H4_SIZEOF_SSIZE_T)
-    SET (H4_SIZEOF_SSIZE_T 0)
-  ENDIF (NOT H4_SIZEOF_SSIZE_T)
-ENDIF (NOT APPLE)
-H4_CHECK_TYPE_SIZE (off_t          H4_SIZEOF_OFF_T)
-H4_CHECK_TYPE_SIZE (off64_t        H4_SIZEOF_OFF64_T)
-IF (NOT H4_SIZEOF_OFF64_T)
-  SET (H4_SIZEOF_OFF64_T 0)
-ENDIF (NOT H4_SIZEOF_OFF64_T)
-
-
-#-----------------------------------------------------------------------------
-# Check for some functions that are used
-#
-CHECK_FUNCTION_EXISTS (fork              H4_HAVE_FORK)
-CHECK_FUNCTION_EXISTS (strdup            H4_HAVE_STRDUP)
-CHECK_FUNCTION_EXISTS (system            H4_HAVE_SYSTEM)
-CHECK_FUNCTION_EXISTS (wait              H4_HAVE_WAIT)
-CHECK_FUNCTION_EXISTS (vfork             H4_HAVE_VFORK)
-#-----------------------------------------------------------------------------
-
-#-----------------------------------------------------------------------------
-# Check a bunch of other functions
-#-----------------------------------------------------------------------------
-IF (NOT WINDOWS)
-  FOREACH (test
-      STDC_HEADERS
-      HAVE_FUNCTION
-  )
-    HDF_FUNCTION_TEST (${test})
-  ENDFOREACH (test)
-ENDIF (NOT WINDOWS)
+if (CYGWIN)
+  CHECK_LIBRARY_EXISTS_CONCAT ("tirpc" xdr_opaque     ${${HDF_PREFIX}}_HAVE_RPC)
+  CHECK_INCLUDE_FILE_CONCAT ("rpc/types.h"     ${HDF_PREFIX}_HAVE_RPC_TYPES_H)
+  CHECK_INCLUDE_FILE_CONCAT ("rpc/xdr.h"     ${HDF_PREFIX}_HAVE_RPC_XDR_H)
+endif (CYGWIN)
diff --git a/config/cmake/FindHDF4.cmake.in b/config/cmake/FindHDF4.cmake.in
index 55a29b0..0976b39 100644
--- a/config/cmake/FindHDF4.cmake.in
+++ b/config/cmake/FindHDF4.cmake.in
@@ -34,18 +34,18 @@
 # To aid in finding HDF4 as part of a subproject set
 # HDF4_ROOT_DIR_HINT to the location where @HDF4_PACKAGE@@HDF_PACKAGE_EXT at -config.cmake lies
 
-INCLUDE (SelectLibraryConfigurations)
-INCLUDE (FindPackageHandleStandardArgs)
+include (SelectLibraryConfigurations)
+include (FindPackageHandleStandardArgs)
 
 # The HINTS option should only be used for values computed from the system.
-SET (_HDF4_HINTS
+set (_HDF4_HINTS
     $ENV{HOME}/.local
     $ENV{HDF4_ROOT}
     $ENV{HDF4_ROOT_DIR_HINT}
 )
 # Hard-coded guesses should still go in PATHS. This ensures that the user
 # environment can always override hard guesses.
-SET (_HDF4_PATHS
+set (_HDF4_PATHS
     $ENV{HOME}/.local
     $ENV{HDF4_ROOT}
     $ENV{HDF4_ROOT_DIR_HINT}
@@ -74,9 +74,9 @@ FIND_PATH (HDF4_INCLUDE_DIRS "hdf.h"
 
 # For backwards compatibility we set HDF4_INCLUDE_DIR to the value of
 # HDF4_INCLUDE_DIRS
-SET ( HDF4_INCLUDE_DIR "${HDF4_INCLUDE_DIRS}" )
+set ( HDF4_INCLUDE_DIR "${HDF4_INCLUDE_DIRS}" )
 
-IF (HDF4_INCLUDE_DIR)
-  SET (HDF4_FOUND "YES")
-  INCLUDE (${HDF4_ROOT_DIR}/@HDF4_PACKAGE@@HDF_PACKAGE_EXT at -config.cmake)
-ENDIF (HDF4_INCLUDE_DIR)
+if (HDF4_INCLUDE_DIR)
+  set (HDF4_FOUND "YES")
+  include (${HDF4_ROOT_DIR}/@HDF4_PACKAGE@@HDF_PACKAGE_EXT at -config.cmake)
+endif (HDF4_INCLUDE_DIR)
diff --git a/config/cmake/FindMPI.cmake b/config/cmake/FindMPI.cmake
deleted file mode 100644
index b16c9c3..0000000
--- a/config/cmake/FindMPI.cmake
+++ /dev/null
@@ -1,628 +0,0 @@
-# - Find a Message Passing Interface (MPI) implementation
-# The Message Passing Interface (MPI) is a library used to write
-# high-performance distributed-memory parallel applications, and
-# is typically deployed on a cluster. MPI is a standard interface
-# (defined by the MPI forum) for which many implementations are
-# available. All of them have somewhat different include paths,
-# libraries to link against, etc., and this module tries to smooth
-# out those differences.
-#
-# === Variables ===
-#
-# This module will set the following variables per language in your project,
-# where <lang> is one of C, CXX, or Fortran:
-#   MPI_<lang>_FOUND           TRUE if FindMPI found MPI flags for <lang>
-#   MPI_<lang>_COMPILER        MPI Compiler wrapper for <lang>
-#   MPI_<lang>_COMPILE_FLAGS   Compilation flags for MPI programs
-#   MPI_<lang>_INCLUDE_PATH    Include path(s) for MPI header
-#   MPI_<lang>_LINK_FLAGS      Linking flags for MPI programs
-#   MPI_<lang>_LIBRARIES       All libraries to link MPI programs against
-# Additionally, FindMPI sets the following variables for running MPI
-# programs from the command line:
-#   MPIEXEC                    Executable for running MPI programs
-#   MPIEXEC_NUMPROC_FLAG       Flag to pass to MPIEXEC before giving
-#                              it the number of processors to run on
-#   MPIEXEC_PREFLAGS           Flags to pass to MPIEXEC directly
-#                              before the executable to run.
-#   MPIEXEC_POSTFLAGS          Flags to pass to MPIEXEC after other flags
-# === Usage ===
-#
-# To use this module, simply call FindMPI from a CMakeLists.txt file, or
-# run find_package(MPI), then run CMake.  If you are happy with the auto-
-# detected configuration for your language, then you're done.  If not, you
-# have two options:
-#   1. Set MPI_<lang>_COMPILER to the MPI wrapper (mpicc, etc.) of your
-#      choice and reconfigure.  FindMPI will attempt to determine all the
-#      necessary variables using THAT compiler's compile and link flags.
-#   2. If this fails, or if your MPI implementation does not come with
-#      a compiler wrapper, then set both MPI_<lang>_LIBRARIES and
-#      MPI_<lang>_INCLUDE_PATH.  You may also set any other variables
-#      listed above, but these two are required.  This will circumvent
-#      autodetection entirely.
-# When configuration is successful, MPI_<lang>_COMPILER will be set to the
-# compiler wrapper for <lang>, if it was found.  MPI_<lang>_FOUND and other
-# variables above will be set if any MPI implementation was found for <lang>,
-# regardless of whether a compiler was found.
-#
-# When using MPIEXEC to execute MPI applications, you should typically use
-# all of the MPIEXEC flags as follows:
-#   ${MPIEXEC} ${MPIEXEC_NUMPROC_FLAG} PROCS
-#     ${MPIEXEC_PREFLAGS} EXECUTABLE ${MPIEXEC_POSTFLAGS} ARGS
-# where PROCS is the number of processors on which to execute the program,
-# EXECUTABLE is the MPI program, and ARGS are the arguments to pass to the
-# MPI program.
-#
-# === Backward Compatibility ===
-#
-# For backward compatibility with older versions of FindMPI, these
-# variables are set, but deprecated:
-#   MPI_FOUND           MPI_COMPILER        MPI_LIBRARY
-#   MPI_COMPILE_FLAGS   MPI_INCLUDE_PATH    MPI_EXTRA_LIBRARY
-#   MPI_LINK_FLAGS      MPI_LIBRARIES
-# In new projects, please use the MPI_<lang>_XXX equivalents.
-
-#=============================================================================
-# Copyright 2001-2011 Kitware, Inc.
-# Copyright 2010-2011 Todd Gamblin tgamblin at llnl.gov
-# Copyright 2001-2009 Dave Partyka
-#
-# Distributed under the OSI-approved BSD License (the "License");
-# see accompanying file Copyright.txt for details.
-#
-# This software is distributed WITHOUT ANY WARRANTY; without even the
-# implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
-# See the License for more information.
-#=============================================================================
-# (To distribute this file outside of CMake, substitute the full
-#  License text for the above reference.)
-
-# include this to handle the QUIETLY and REQUIRED arguments
-include(${CMAKE_ROOT}/Modules/FindPackageHandleStandardArgs.cmake)
-include(GetPrerequisites)
-
-#
-# This part detects MPI compilers, attempting to wade through the mess of compiler names in
-# a sensible way.
-#
-# The compilers are detected in this order:
-#
-# 1. Try to find the most generic availble MPI compiler, as this is usually set up by
-#    cluster admins.  e.g., if plain old mpicc is available, we'll use it and assume it's
-#    the right compiler.
-#
-# 2. If a generic mpicc is NOT found, then we attempt to find one that matches
-#    CMAKE_<lang>_COMPILER_ID. e.g. if you are using XL compilers, we'll try to find mpixlc
-#    and company, but not mpiicc.  This hopefully prevents toolchain mismatches.
-#
-# If you want to force a particular MPI compiler other than what we autodetect (e.g. if you
-# want to compile regular stuff with GNU and parallel stuff with Intel), you can always set
-# your favorite MPI_<lang>_COMPILER explicitly and this stuff will be ignored.
-#
-
-# Start out with the generic MPI compiler names, as these are most commonly used.
-set(_MPI_C_COMPILER_NAMES                  mpicc    mpcc      mpicc_r mpcc_r)
-set(_MPI_CXX_COMPILER_NAMES                mpicxx   mpiCC     mpcxx   mpCC    mpic++   mpc++
-                                           mpicxx_r mpiCC_r   mpcxx_r mpCC_r  mpic++_r mpc++_r)
-set(_MPI_Fortran_COMPILER_NAMES            mpif95   mpif95_r  mpf95   mpf95_r
-                                           mpif90   mpif90_r  mpf90   mpf90_r
-                                           mpif77   mpif77_r  mpf77   mpf77_r)
-
-# GNU compiler names
-set(_MPI_GNU_C_COMPILER_NAMES              mpigcc mpgcc mpigcc_r mpgcc_r)
-set(_MPI_GNU_CXX_COMPILER_NAMES            mpig++ mpg++ mpig++_r mpg++_r)
-set(_MPI_GNU_Fortran_COMPILER_NAMES        mpigfortran mpgfortran mpigfortran_r mpgfortran_r
-                                           mpig77 mpig77_r mpg77 mpg77_r)
-
-# Intel MPI compiler names
-set(_MPI_Intel_C_COMPILER_NAMES            mpiicc)
-set(_MPI_Intel_CXX_COMPILER_NAMES          mpiicpc  mpiicxx mpiic++ mpiiCC)
-set(_MPI_Intel_Fortran_COMPILER_NAMES      mpiifort mpiif95 mpiif90 mpiif77)
-
-# PGI compiler names
-set(_MPI_PGI_C_COMPILER_NAMES              mpipgcc mppgcc)
-set(_MPI_PGI_CXX_COMPILER_NAMES            mpipgCC mppgCC)
-set(_MPI_PGI_Fortran_COMPILER_NAMES        mpipgf95 mpipgf90 mppgf95 mppgf90 mpipgf77 mppgf77)
-
-# XLC MPI Compiler names
-set(_MPI_XL_C_COMPILER_NAMES               mpxlc      mpxlc_r    mpixlc     mpixlc_r)
-set(_MPI_XL_CXX_COMPILER_NAMES             mpixlcxx   mpixlC     mpixlc++   mpxlcxx   mpxlc++   mpixlc++   mpxlCC
-                                           mpixlcxx_r mpixlC_r   mpixlc++_r mpxlcxx_r mpxlc++_r mpixlc++_r mpxlCC_r)
-set(_MPI_XL_Fortran_COMPILER_NAMES         mpixlf95   mpixlf95_r mpxlf95 mpxlf95_r
-                                           mpixlf90   mpixlf90_r mpxlf90 mpxlf90_r
-                                           mpixlf77   mpixlf77_r mpxlf77 mpxlf77_r
-                                           mpixlf     mpixlf_r   mpxlf   mpxlf_r)
-
-# append vendor-specific compilers to the list if we either don't know the compiler id,
-# or if we know it matches the regular compiler.
-foreach (lang C CXX Fortran)
-  foreach (id GNU Intel PGI XL)
-    if (NOT CMAKE_${lang}_COMPILER_ID OR "${CMAKE_${lang}_COMPILER_ID}" STREQUAL "${id}")
-      list(APPEND _MPI_${lang}_COMPILER_NAMES ${_MPI_${id}_${lang}_COMPILER_NAMES})
-    endif()
-    unset(_MPI_${id}_${lang}_COMPILER_NAMES)    # clean up the namespace here
-  endforeach()
-endforeach()
-
-
-# Names to try for MPI exec
-set(_MPI_EXEC_NAMES                        mpiexec mpirun lamexec srun)
-
-# Grab the path to MPI from the registry if we're on windows.
-set(_MPI_PREFIX_PATH)
-if(WIN32)
-  list(APPEND _MPI_PREFIX_PATH "[HKEY_LOCAL_MACHINE\\SOFTWARE\\MPICH\\SMPD;binary]/..")
-  list(APPEND _MPI_PREFIX_PATH "[HKEY_LOCAL_MACHINE\\SOFTWARE\\MPICH2;Path]")
-  list(APPEND _MPI_PREFIX_PATH "$ENV{ProgramW6432}/MPICH2/")
-endif()
-
-# Build a list of prefixes to search for MPI.
-foreach(SystemPrefixDir ${CMAKE_SYSTEM_PREFIX_PATH})
-  foreach(MpiPackageDir ${_MPI_PREFIX_PATH})
-    if(EXISTS ${SystemPrefixDir}/${MpiPackageDir})
-      list(APPEND _MPI_PREFIX_PATH "${SystemPrefixDir}/${MpiPackageDir}")
-    endif()
-  endforeach()
-endforeach()
-
-
-#
-# interrogate_mpi_compiler(lang try_libs)
-#
-# Attempts to extract compiler and linker args from an MPI compiler. The arguments set
-# by this function are:
-#
-#   MPI_<lang>_INCLUDE_PATH    MPI_<lang>_LINK_FLAGS     MPI_<lang>_FOUND
-#   MPI_<lang>_COMPILE_FLAGS   MPI_<lang>_LIBRARIES
-#
-# MPI_<lang>_COMPILER must be set beforehand to the absolute path to an MPI compiler for
-# <lang>.  Additionally, MPI_<lang>_INCLUDE_PATH and MPI_<lang>_LIBRARIES may be set
-# to skip autodetection.
-#
-# If try_libs is TRUE, this will also attempt to find plain MPI libraries in the usual
-# way.  In general, this is not as effective as interrogating the compilers, as it
-# ignores language-specific flags and libraries.  However, some MPI implementations
-# (Windows implementations) do not have compiler wrappers, so this approach must be used.
-#
-function (interrogate_mpi_compiler lang try_libs)
-  # MPI_${lang}_NO_INTERROGATE will be set to a compiler name when the *regular* compiler was
-  # discovered to be the MPI compiler.  This happens on machines like the Cray XE6 that use
-  # modules to set cc, CC, and ftn to the MPI compilers.  If the user force-sets another MPI
-  # compiler, MPI_${lang}_COMPILER won't be equal to MPI_${lang}_NO_INTERROGATE, and we'll
-  # inspect that compiler anew.  This allows users to set new compilers w/o rm'ing cache.
-  string(COMPARE NOTEQUAL "${MPI_${lang}_NO_INTERROGATE}" "${MPI_${lang}_COMPILER}" interrogate)
-
-  # If MPI is set already in the cache, don't bother with interrogating the compiler.
-  if (interrogate AND ((NOT MPI_${lang}_INCLUDE_PATH) OR (NOT MPI_${lang}_LIBRARIES)))
-    if (MPI_${lang}_COMPILER)
-      # Check whether the -showme:compile option works. This indicates that we have either OpenMPI
-      # or a newer version of LAM-MPI, and implies that -showme:link will also work.
-      execute_process(
-        COMMAND ${MPI_${lang}_COMPILER} -showme:compile
-        OUTPUT_VARIABLE  MPI_COMPILE_CMDLINE OUTPUT_STRIP_TRAILING_WHITESPACE
-        ERROR_VARIABLE   MPI_COMPILE_CMDLINE ERROR_STRIP_TRAILING_WHITESPACE
-        RESULT_VARIABLE  MPI_COMPILER_RETURN)
-
-      if (MPI_COMPILER_RETURN EQUAL 0)
-        # If we appear to have -showme:compile, then we should
-        # also have -showme:link. Try it.
-        execute_process(
-          COMMAND ${MPI_${lang}_COMPILER} -showme:link
-          OUTPUT_VARIABLE  MPI_LINK_CMDLINE OUTPUT_STRIP_TRAILING_WHITESPACE
-          ERROR_VARIABLE   MPI_LINK_CMDLINE ERROR_STRIP_TRAILING_WHITESPACE
-          RESULT_VARIABLE  MPI_COMPILER_RETURN)
-
-        if (MPI_COMPILER_RETURN EQUAL 0)
-          # We probably have -showme:incdirs and -showme:libdirs as well,
-          # so grab that while we're at it.
-          execute_process(
-            COMMAND ${MPI_${lang}_COMPILER} -showme:incdirs
-            OUTPUT_VARIABLE  MPI_INCDIRS OUTPUT_STRIP_TRAILING_WHITESPACE
-            ERROR_VARIABLE   MPI_INCDIRS ERROR_STRIP_TRAILING_WHITESPACE)
-
-          execute_process(
-            COMMAND ${MPI_${lang}_COMPILER} -showme:libdirs
-            OUTPUT_VARIABLE  MPI_LIBDIRS OUTPUT_STRIP_TRAILING_WHITESPACE
-            ERROR_VARIABLE   MPI_LIBDIRS ERROR_STRIP_TRAILING_WHITESPACE)
-
-        else()
-          # reset things here if something went wrong.
-          set(MPI_COMPILE_CMDLINE)
-          set(MPI_LINK_CMDLINE)
-        endif()
-      endif ()
-
-      # Older versions of LAM-MPI have "-showme". Try to find that.
-      if (NOT MPI_COMPILER_RETURN EQUAL 0)
-        execute_process(
-          COMMAND ${MPI_${lang}_COMPILER} -showme
-          OUTPUT_VARIABLE  MPI_COMPILE_CMDLINE OUTPUT_STRIP_TRAILING_WHITESPACE
-          ERROR_VARIABLE   MPI_COMPILE_CMDLINE ERROR_STRIP_TRAILING_WHITESPACE
-          RESULT_VARIABLE  MPI_COMPILER_RETURN)
-      endif()
-
-      # MVAPICH uses -compile-info and -link-info.  Try them.
-      if (NOT MPI_COMPILER_RETURN EQUAL 0)
-        execute_process(
-          COMMAND ${MPI_${lang}_COMPILER} -compile-info
-          OUTPUT_VARIABLE  MPI_COMPILE_CMDLINE OUTPUT_STRIP_TRAILING_WHITESPACE
-          ERROR_VARIABLE   MPI_COMPILE_CMDLINE ERROR_STRIP_TRAILING_WHITESPACE
-          RESULT_VARIABLE  MPI_COMPILER_RETURN)
-
-        # If we have compile-info, also have link-info.
-        if (MPI_COMPILER_RETURN EQUAL 0)
-          execute_process(
-            COMMAND ${MPI_${lang}_COMPILER} -link-info
-            OUTPUT_VARIABLE  MPI_LINK_CMDLINE OUTPUT_STRIP_TRAILING_WHITESPACE
-            ERROR_VARIABLE   MPI_LINK_CMDLINE ERROR_STRIP_TRAILING_WHITESPACE
-            RESULT_VARIABLE  MPI_COMPILER_RETURN)
-        endif()
-
-        # make sure we got compile and link.  Reset vars if something's wrong.
-        if (NOT MPI_COMPILER_RETURN EQUAL 0)
-          set(MPI_COMPILE_CMDLINE)
-          set(MPI_LINK_CMDLINE)
-        endif()
-      endif()
-
-      # MPICH just uses "-show". Try it.
-      if (NOT MPI_COMPILER_RETURN EQUAL 0)
-        execute_process(
-          COMMAND ${MPI_${lang}_COMPILER} -show
-          OUTPUT_VARIABLE  MPI_COMPILE_CMDLINE OUTPUT_STRIP_TRAILING_WHITESPACE
-          ERROR_VARIABLE   MPI_COMPILE_CMDLINE ERROR_STRIP_TRAILING_WHITESPACE
-          RESULT_VARIABLE  MPI_COMPILER_RETURN)
-      endif()
-
-      if (MPI_COMPILER_RETURN EQUAL 0)
-        # We have our command lines, but we might need to copy MPI_COMPILE_CMDLINE
-        # into MPI_LINK_CMDLINE, if we didn't find the link line.
-        if (NOT MPI_LINK_CMDLINE)
-          set(MPI_LINK_CMDLINE ${MPI_COMPILE_CMDLINE})
-        endif()
-      else()
-        message(STATUS "Unable to determine MPI from MPI driver ${MPI_${lang}_COMPILER}")
-        set(MPI_COMPILE_CMDLINE)
-        set(MPI_LINK_CMDLINE)
-      endif()
-
-      # Here, we're done with the interrogation part, and we'll try to extract args we care
-      # about from what we learned from the compiler wrapper scripts.
-
-      # If interrogation came back with something, extract our variable from the MPI command line
-      if (MPI_COMPILE_CMDLINE OR MPI_LINK_CMDLINE)
-        # Extract compile flags from the compile command line.
-        string(REGEX MATCHALL "(^| )-[Df]([^\" ]+|\"[^\"]+\")" MPI_ALL_COMPILE_FLAGS "${MPI_COMPILE_CMDLINE}")
-        set(MPI_COMPILE_FLAGS_WORK)
-
-        foreach(FLAG ${MPI_ALL_COMPILE_FLAGS})
-          if (MPI_COMPILE_FLAGS_WORK)
-            set(MPI_COMPILE_FLAGS_WORK "${MPI_COMPILE_FLAGS_WORK} ${FLAG}")
-          else()
-            set(MPI_COMPILE_FLAGS_WORK ${FLAG})
-          endif()
-        endforeach()
-
-        # Extract include paths from compile command line
-        string(REGEX MATCHALL "(^| )-I([^\" ]+|\"[^\"]+\")" MPI_ALL_INCLUDE_PATHS "${MPI_COMPILE_CMDLINE}")
-        foreach(IPATH ${MPI_ALL_INCLUDE_PATHS})
-          string(REGEX REPLACE "^ ?-I" "" IPATH ${IPATH})
-          string(REGEX REPLACE "//" "/" IPATH ${IPATH})
-          list(APPEND MPI_INCLUDE_PATH_WORK ${IPATH})
-        endforeach()
-
-        # try using showme:incdirs if extracting didn't work.
-        if (NOT MPI_INCLUDE_PATH_WORK)
-          set(MPI_INCLUDE_PATH_WORK ${MPI_INCDIRS})
-          separate_arguments(MPI_INCLUDE_PATH_WORK)
-        endif()
-
-        # If all else fails, just search for mpi.h in the normal include paths.
-        if (NOT MPI_INCLUDE_PATH_WORK)
-          set(MPI_HEADER_PATH "MPI_HEADER_PATH-NOTFOUND" CACHE FILEPATH "Cleared" FORCE)
-          find_path(MPI_HEADER_PATH mpi.h
-            HINTS ${_MPI_BASE_DIR} ${_MPI_PREFIX_PATH}
-            PATH_SUFFIXES include)
-          set(MPI_INCLUDE_PATH_WORK ${MPI_HEADER_PATH})
-        endif()
-
-        # Extract linker paths from the link command line
-        string(REGEX MATCHALL "(^| |-Wl,)-L([^\" ]+|\"[^\"]+\")" MPI_ALL_LINK_PATHS "${MPI_LINK_CMDLINE}")
-        set(MPI_LINK_PATH)
-        foreach(LPATH ${MPI_ALL_LINK_PATHS})
-          string(REGEX REPLACE "^(| |-Wl,)-L" "" LPATH ${LPATH})
-          string(REGEX REPLACE "//" "/" LPATH ${LPATH})
-          list(APPEND MPI_LINK_PATH ${LPATH})
-        endforeach()
-
-        # try using showme:libdirs if extracting didn't work.
-        if (NOT MPI_LINK_PATH)
-          set(MPI_LINK_PATH ${MPI_LIBDIRS})
-          separate_arguments(MPI_LINK_PATH)
-        endif()
-
-        # Extract linker flags from the link command line
-        string(REGEX MATCHALL "(^| )-Wl,([^\" ]+|\"[^\"]+\")" MPI_ALL_LINK_FLAGS "${MPI_LINK_CMDLINE}")
-        set(MPI_LINK_FLAGS_WORK)
-        foreach(FLAG ${MPI_ALL_LINK_FLAGS})
-          if (MPI_LINK_FLAGS_WORK)
-            set(MPI_LINK_FLAGS_WORK "${MPI_LINK_FLAGS_WORK} ${FLAG}")
-          else()
-            set(MPI_LINK_FLAGS_WORK ${FLAG})
-          endif()
-        endforeach()
-
-        # Extract the set of libraries to link against from the link command
-        # line
-        string(REGEX MATCHALL "(^| )-l([^\" ]+|\"[^\"]+\")" MPI_LIBNAMES "${MPI_LINK_CMDLINE}")
-
-        # Determine full path names for all of the libraries that one needs
-        # to link against in an MPI program
-        foreach(LIB ${MPI_LIBNAMES})
-          string(REGEX REPLACE "^ ?-l" "" LIB ${LIB})
-          # MPI_LIB is cached by find_library, but we don't want that.  Clear it first.
-          set(MPI_LIB "MPI_LIB-NOTFOUND" CACHE FILEPATH "Cleared" FORCE)
-          find_library(MPI_LIB NAMES ${LIB} HINTS ${MPI_LINK_PATH})
-
-          if (MPI_LIB)
-            list(APPEND MPI_LIBRARIES_WORK ${MPI_LIB})
-          elseif (NOT MPI_FIND_QUIETLY)
-            message(WARNING "Unable to find MPI library ${LIB}")
-          endif()
-        endforeach()
-
-        # Sanity check MPI_LIBRARIES to make sure there are enough libraries
-        list(LENGTH MPI_LIBRARIES_WORK MPI_NUMLIBS)
-        list(LENGTH MPI_LIBNAMES MPI_NUMLIBS_EXPECTED)
-        if (NOT MPI_NUMLIBS EQUAL MPI_NUMLIBS_EXPECTED)
-          set(MPI_LIBRARIES_WORK "MPI_${lang}_LIBRARIES-NOTFOUND")
-        endif()
-      endif()
-
-    elseif(try_libs)
-      # If we didn't have an MPI compiler script to interrogate, attempt to find everything
-      # with plain old find functions.  This is nasty because MPI implementations have LOTS of
-      # different library names, so this section isn't going to be very generic.  We need to
-      # make sure it works for MS MPI, though, since there are no compiler wrappers for that.
-      find_path(MPI_HEADER_PATH mpi.h
-        HINTS ${_MPI_BASE_DIR} ${_MPI_PREFIX_PATH}
-        PATH_SUFFIXES include Inc)
-      set(MPI_INCLUDE_PATH_WORK ${MPI_HEADER_PATH})
-
-      # Decide between 32-bit and 64-bit libraries for Microsoft's MPI
-      if("${CMAKE_SIZEOF_VOID_P}" EQUAL 8)
-        set(MS_MPI_ARCH_DIR amd64)
-      else()
-        set(MS_MPI_ARCH_DIR i386)
-      endif()
-
-      set(MPI_LIB "MPI_LIB-NOTFOUND" CACHE FILEPATH "Cleared" FORCE)
-      find_library(MPI_LIB
-        NAMES         mpi mpich mpich2 msmpi
-        HINTS         ${_MPI_BASE_DIR} ${_MPI_PREFIX_PATH}
-        PATH_SUFFIXES lib lib/${MS_MPI_ARCH_DIR} Lib Lib/${MS_MPI_ARCH_DIR})
-      set(MPI_LIBRARIES_WORK ${MPI_LIB})
-
-      # Right now, we only know about the extra libs for C++.
-      # We could add Fortran here (as there is usually libfmpich, etc.), but
-      # this really only has to work with MS MPI on Windows.
-      # Assume that other MPI's are covered by the compiler wrappers.
-      if (${lang} STREQUAL CXX)
-        set(MPI_LIB "MPI_LIB-NOTFOUND" CACHE FILEPATH "Cleared" FORCE)
-        find_library(MPI_LIB
-          NAMES         mpi++ mpicxx cxx mpi_cxx
-          HINTS         ${_MPI_BASE_DIR} ${_MPI_PREFIX_PATH}
-          PATH_SUFFIXES lib)
-        if (MPI_LIBRARIES_WORK AND MPI_LIB)
-          set(MPI_LIBRARIES_WORK ${MPI_LIBRARIES_WORK} ${MPI_LIB})
-        endif()
-      endif()
-
-      if (${lang} STREQUAL Fortran)
-        set(MPI_LIB "MPI_LIB-NOTFOUND" CACHE FILEPATH "Cleared" FORCE)
-        find_library(MPI_LIB
-          NAMES         fmpi fmpich fmpich2 fmpich2g
-          HINTS         ${_MPI_BASE_DIR} ${_MPI_PREFIX_PATH}
-          PATH_SUFFIXES lib)
-        if (MPI_LIBRARIES_WORK AND MPI_LIB)
-          set(MPI_LIBRARIES_WORK ${MPI_LIBRARIES_WORK} ${MPI_LIB})
-        endif()
-      endif()
-
-      if (NOT MPI_LIBRARIES_WORK)
-        set(MPI_LIBRARIES_WORK "MPI_${lang}_LIBRARIES-NOTFOUND")
-      endif()
-    endif()
-
-    # If we found MPI, set up all of the appropriate cache entries
-    set(MPI_${lang}_COMPILE_FLAGS ${MPI_COMPILE_FLAGS_WORK} CACHE STRING "MPI ${lang} compilation flags"         FORCE)
-    set(MPI_${lang}_INCLUDE_PATH  ${MPI_INCLUDE_PATH_WORK}  CACHE STRING "MPI ${lang} include path"              FORCE)
-    set(MPI_${lang}_LINK_FLAGS    ${MPI_LINK_FLAGS_WORK}    CACHE STRING "MPI ${lang} linking flags"             FORCE)
-    set(MPI_${lang}_LIBRARIES     ${MPI_LIBRARIES_WORK}     CACHE STRING "MPI ${lang} libraries to link against" FORCE)
-    mark_as_advanced(MPI_${lang}_COMPILE_FLAGS MPI_${lang}_INCLUDE_PATH MPI_${lang}_LINK_FLAGS MPI_${lang}_LIBRARIES)
-
-    # clear out our temporary lib/header detectionv variable here.
-    set(MPI_LIB         "MPI_LIB-NOTFOUND"         CACHE INTERNAL "Scratch variable for MPI lib detection"    FORCE)
-    set(MPI_HEADER_PATH "MPI_HEADER_PATH-NOTFOUND" CACHE INTERNAL "Scratch variable for MPI header detection" FORCE)
-  endif()
-
-  # finally set a found variable for each MPI language
-  if (MPI_${lang}_INCLUDE_PATH AND MPI_${lang}_LIBRARIES)
-    set(MPI_${lang}_FOUND TRUE PARENT_SCOPE)
-  else()
-    set(MPI_${lang}_FOUND FALSE PARENT_SCOPE)
-  endif()
-endfunction()
-
-
-# This function attempts to compile with the regular compiler, to see if MPI programs
-# work with it.  This is a last ditch attempt after we've tried interrogating mpicc and
-# friends, and after we've tried to find generic libraries.  Works on machines like
-# Cray XE6, where the modules environment changes what MPI version cc, CC, and ftn use.
-function(try_regular_compiler lang success)
-  set(scratch_directory ${CMAKE_CURRENT_BINARY_DIR}${CMAKE_FILES_DIRECTORY})
-  if (${lang} STREQUAL Fortran)
-    set(test_file ${scratch_directory}/cmake_mpi_test.f90)
-    file(WRITE ${test_file}
-      "program hello\n"
-      "include 'mpif.h'\n"
-      "integer ierror\n"
-      "call MPI_INIT(ierror)\n"
-      "call MPI_FINALIZE(ierror)\n"
-      "end\n")
-  else()
-    if (${lang} STREQUAL CXX)
-      set(test_file ${scratch_directory}/cmake_mpi_test.cpp)
-    else()
-      set(test_file ${scratch_directory}/cmake_mpi_test.c)
-    endif()
-    file(WRITE ${test_file}
-      "#include <mpi.h>\n"
-      "int main(int argc, char **argv) {\n"
-      "  MPI_Init(&argc, &argv);\n"
-      "  MPI_Finalize();\n"
-      "}\n")
-  endif()
-  try_compile(compiler_has_mpi ${scratch_directory} ${test_file})
-  if (compiler_has_mpi)
-    set(MPI_${lang}_NO_INTERROGATE ${CMAKE_${lang}_COMPILER} CACHE STRING "Whether to interrogate MPI ${lang} compiler" FORCE)
-    set(MPI_${lang}_COMPILER       ${CMAKE_${lang}_COMPILER} CACHE STRING "MPI ${lang} compiler"                        FORCE)
-    set(MPI_${lang}_COMPILE_FLAGS  ""                        CACHE STRING "MPI ${lang} compilation flags"               FORCE)
-    set(MPI_${lang}_INCLUDE_PATH   ""                        CACHE STRING "MPI ${lang} include path"                    FORCE)
-    set(MPI_${lang}_LINK_FLAGS     ""                        CACHE STRING "MPI ${lang} linking flags"                   FORCE)
-    set(MPI_${lang}_LIBRARIES      ""                        CACHE STRING "MPI ${lang} libraries to link against"       FORCE)
-  endif()
-  set(${success} ${compiler_has_mpi} PARENT_SCOPE)
-  unset(compiler_has_mpi CACHE)
-endfunction()
-
-# End definitions, commence real work here.
-
-# Most mpi distros have some form of mpiexec which gives us something we can reliably look for.
-find_program(MPIEXEC
-  NAMES ${_MPI_EXEC_NAMES}
-  PATHS ${_MPI_PREFIX_PATH}
-  PATH_SUFFIXES bin
-  DOC "Executable for running MPI programs.")
-
-# call get_filename_component twice to remove mpiexec and the directory it exists in (typically bin).
-# This gives us a fairly reliable base directory to search for /bin /lib and /include from.
-get_filename_component(_MPI_BASE_DIR "${MPIEXEC}" PATH)
-get_filename_component(_MPI_BASE_DIR "${_MPI_BASE_DIR}" PATH)
-
-set(MPIEXEC_NUMPROC_FLAG "-np" CACHE STRING "Flag used by MPI to specify the number of processes for MPIEXEC; the next option will be the number of processes.")
-set(MPIEXEC_PREFLAGS     ""    CACHE STRING "These flags will be directly before the executable that is being run by MPIEXEC.")
-set(MPIEXEC_POSTFLAGS    ""    CACHE STRING "These flags will come after all flags given to MPIEXEC.")
-set(MPIEXEC_MAX_NUMPROCS "2"   CACHE STRING "Maximum number of processors available to run MPI applications.")
-mark_as_advanced(MPIEXEC MPIEXEC_NUMPROC_FLAG MPIEXEC_PREFLAGS MPIEXEC_POSTFLAGS MPIEXEC_MAX_NUMPROCS)
-
-
-#=============================================================================
-# Backward compatibility input hacks.  Propagate the FindMPI hints to C and
-# CXX if the respective new versions are not defined.  Translate the old
-# MPI_LIBRARY and MPI_EXTRA_LIBRARY to respective MPI_${lang}_LIBRARIES.
-#
-# Once we find the new variables, we translate them back into their old
-# equivalents below.
-foreach (lang C CXX)
-  # Old input variables.
-  set(_MPI_OLD_INPUT_VARS COMPILER COMPILE_FLAGS INCLUDE_PATH LINK_FLAGS)
-
-  # Set new vars based on their old equivalents, if the new versions are not already set.
-  foreach (var ${_MPI_OLD_INPUT_VARS})
-    if (NOT MPI_${lang}_${var} AND MPI_${var})
-      set(MPI_${lang}_${var} "${MPI_${var}}")
-    endif()
-  endforeach()
-
-  # Special handling for MPI_LIBRARY and MPI_EXTRA_LIBRARY, which we nixed in the
-  # new FindMPI.  These need to be merged into MPI_<lang>_LIBRARIES
-  if (NOT MPI_${lang}_LIBRARIES AND (MPI_LIBRARY OR MPI_EXTRA_LIBRARY))
-    set(MPI_${lang}_LIBRARIES ${MPI_LIBRARY} ${MPI_EXTRA_LIBRARY})
-  endif()
-endforeach()
-#=============================================================================
-
-
-# This loop finds the compilers and sends them off for interrogation.
-foreach (lang C CXX Fortran)
-  if (CMAKE_${lang}_COMPILER_WORKS)
-    # If the user supplies a compiler *name* instead of an absolute path, assume that we need to find THAT compiler.
-    if (MPI_${lang}_COMPILER)
-      is_file_executable(MPI_${lang}_COMPILER MPI_COMPILER_IS_EXECUTABLE)
-      if (NOT MPI_COMPILER_IS_EXECUTABLE)
-        # Get rid of our default list of names and just search for the name the user wants.
-        set(_MPI_${lang}_COMPILER_NAMES ${MPI_${lang}_COMPILER})
-        set(MPI_${lang}_COMPILER "MPI_${lang}_COMPILER-NOTFOUND" CACHE FILEPATH "Cleared" FORCE)
-        # If the user specifies a compiler, we don't want to try to search libraries either.
-        set(try_libs FALSE)
-      endif()
-    else()
-      set(try_libs TRUE)
-    endif()
-
-    find_program(MPI_${lang}_COMPILER
-      NAMES  ${_MPI_${lang}_COMPILER_NAMES}
-      PATHS  "${MPI_HOME}/bin" "$ENV{MPI_HOME}/bin" ${_MPI_PREFIX_PATH})
-    interrogate_mpi_compiler(${lang} ${try_libs})
-    mark_as_advanced(MPI_${lang}_COMPILER)
-
-    # last ditch try -- if nothing works so far, just try running the regular compiler and
-    # see if we can create an MPI executable.
-    set(regular_compiler_worked 0)
-    if (NOT MPI_${lang}_LIBRARIES OR NOT MPI_${lang}_INCLUDE_PATH)
-      try_regular_compiler(${lang} regular_compiler_worked)
-    endif()
-
-    if (regular_compiler_worked)
-      find_package_handle_standard_args(MPI_${lang} DEFAULT_MSG MPI_${lang}_COMPILER)
-    else()
-      find_package_handle_standard_args(MPI_${lang} DEFAULT_MSG MPI_${lang}_LIBRARIES MPI_${lang}_INCLUDE_PATH)
-    endif()
-  endif()
-endforeach()
-
-
-#=============================================================================
-# More backward compatibility stuff
-#
-# Bare MPI sans ${lang} vars are set to CXX then C, depending on what was found.
-# This mimics the behavior of the old language-oblivious FindMPI.
-set(_MPI_OLD_VARS FOUND COMPILER INCLUDE_PATH COMPILE_FLAGS LINK_FLAGS LIBRARIES)
-if (MPI_CXX_FOUND)
-  foreach (var ${_MPI_OLD_VARS})
-    set(MPI_${var} ${MPI_CXX_${var}})
-  endforeach()
-elseif (MPI_C_FOUND)
-  foreach (var ${_MPI_OLD_VARS})
-    set(MPI_${var} ${MPI_C_${var}})
-  endforeach()
-else()
-  # Note that we might still have found Fortran, but you'll need to use MPI_Fortran_FOUND
-  set(MPI_FOUND FALSE)
-endif()
-
-# Chop MPI_LIBRARIES into the old-style MPI_LIBRARY and MPI_EXTRA_LIBRARY, and set them in cache.
-if (MPI_LIBRARIES)
-  list(GET MPI_LIBRARIES 0 MPI_LIBRARY_WORK)
-  set(MPI_LIBRARY ${MPI_LIBRARY_WORK} CACHE FILEPATH "MPI library to link against" FORCE)
-else()
-  set(MPI_LIBRARY "MPI_LIBRARY-NOTFOUND" CACHE FILEPATH "MPI library to link against" FORCE)
-endif()
-
-list(LENGTH MPI_LIBRARIES MPI_NUMLIBS)
-if (MPI_NUMLIBS GREATER 1)
-  set(MPI_EXTRA_LIBRARY_WORK ${MPI_LIBRARIES})
-  list(REMOVE_AT MPI_EXTRA_LIBRARY_WORK 0)
-  set(MPI_EXTRA_LIBRARY ${MPI_EXTRA_LIBRARY_WORK} CACHE STRING "Extra MPI libraries to link against" FORCE)
-else()
-  set(MPI_EXTRA_LIBRARY "MPI_EXTRA_LIBRARY-NOTFOUND" CACHE STRING "Extra MPI libraries to link against" FORCE)
-endif()
-#=============================================================================
-
-# unset these vars to cleanup namespace
-unset(_MPI_OLD_VARS)
-unset(_MPI_PREFIX_PATH)
-unset(_MPI_BASE_DIR)
-foreach (lang C CXX Fortran)
-  unset(_MPI_${lang}_COMPILER_NAMES)
-endforeach()
diff --git a/config/cmake/FindSZIP.cmake b/config/cmake/FindSZIP.cmake
deleted file mode 100644
index b358862..0000000
--- a/config/cmake/FindSZIP.cmake
+++ /dev/null
@@ -1,179 +0,0 @@
-
-# - Find SZIP library
-# - Derived from the FindTiff.cmake that is included with cmake
-# Find the native SZIP includes and library
-# This module defines
-#  SZIP_INCLUDE_DIRS, where to find tiff.h, etc.
-#  SZIP_LIBRARIES, libraries to link against to use SZIP.
-#  SZIP_FOUND, If false, do not try to use SZIP.
-#    also defined, but not for general use are
-#  SZIP_LIBRARY, where to find the SZIP library.
-#  SZIP_LIBRARY_DEBUG - Debug version of SZIP library
-#  SZIP_LIBRARY_RELEASE - Release Version of SZIP library
-
-# MESSAGE (STATUS "Finding SZIP library and headers..." )
-
-############################################
-#
-# Check the existence of the libraries.
-#
-############################################
-# This macro was taken directly from the FindQt4.cmake file that is included
-# with the CMake distribution. This is NOT my work. All work was done by the
-# original authors of the FindQt4.cmake file. Only minor modifications were
-# made to remove references to Qt and make this file more generally applicable
-#########################################################################
-
-MACRO (SZIP_ADJUST_LIB_VARS basename)
-  IF (${basename}_INCLUDE_DIR)
-
-    # if only the release version was found, set the debug variable also to the release version
-    IF (${basename}_LIBRARY_RELEASE AND NOT ${basename}_LIBRARY_DEBUG)
-      SET (${basename}_LIBRARY_DEBUG ${${basename}_LIBRARY_RELEASE})
-      SET (${basename}_LIBRARY       ${${basename}_LIBRARY_RELEASE})
-      SET (${basename}_LIBRARIES     ${${basename}_LIBRARY_RELEASE})
-    ENDIF (${basename}_LIBRARY_RELEASE AND NOT ${basename}_LIBRARY_DEBUG)
-
-    # if only the debug version was found, set the release variable also to the debug version
-    IF (${basename}_LIBRARY_DEBUG AND NOT ${basename}_LIBRARY_RELEASE)
-      SET (${basename}_LIBRARY_RELEASE ${${basename}_LIBRARY_DEBUG})
-      SET (${basename}_LIBRARY         ${${basename}_LIBRARY_DEBUG})
-      SET (${basename}_LIBRARIES       ${${basename}_LIBRARY_DEBUG})
-    ENDIF (${basename}_LIBRARY_DEBUG AND NOT ${basename}_LIBRARY_RELEASE)
-    IF (${basename}_LIBRARY_DEBUG AND ${basename}_LIBRARY_RELEASE)
-      # if the generator supports configuration types then set
-      # optimized and debug libraries, or if the CMAKE_BUILD_TYPE has a value
-      IF (CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE)
-        SET (${basename}_LIBRARY       optimized ${${basename}_LIBRARY_RELEASE} debug ${${basename}_LIBRARY_DEBUG})
-      ELSE(CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE)
-        # if there are no configuration types and CMAKE_BUILD_TYPE has no value
-        # then just use the release libraries
-        SET (${basename}_LIBRARY       ${${basename}_LIBRARY_RELEASE} )
-      ENDIF (CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE)
-      SET (${basename}_LIBRARIES       optimized ${${basename}_LIBRARY_RELEASE} debug ${${basename}_LIBRARY_DEBUG})
-    ENDIF (${basename}_LIBRARY_DEBUG AND ${basename}_LIBRARY_RELEASE)
-
-    SET (${basename}_LIBRARY ${${basename}_LIBRARY} CACHE FILEPATH "The ${basename} library")
-
-    IF (${basename}_LIBRARY)
-      SET (${basename}_FOUND 1)
-    ENDIF (${basename}_LIBRARY)
-
-  ENDIF (${basename}_INCLUDE_DIR )
-
-  # Make variables changeble to the advanced user
-  MARK_AS_ADVANCED (${basename}_LIBRARY ${basename}_LIBRARY_RELEASE ${basename}_LIBRARY_DEBUG ${basename}_INCLUDE_DIR )
-ENDMACRO (SZIP_ADJUST_LIB_VARS)
-
-
-# Look for the header file.
-SET (SZIP_INCLUDE_SEARCH_DIRS
-    $ENV{SZIP_INSTALL}/include
-    $ENV{SZIP_INSTALL}/include/szip
-    /usr/include
-    /usr/include/szip
-)
-
-SET (SZIP_LIB_SEARCH_DIRS
-    $ENV{SZIP_INSTALL}/lib
-    /usr/lib
-)
-
-SET (SZIP_BIN_SEARCH_DIRS
-    $ENV{SZIP_INSTALL}/bin
-    /usr/bin
-)
-
-FIND_PATH (SZIP_INCLUDE_DIR
-    NAMES szlib.h
-    PATHS ${SZIP_INCLUDE_SEARCH_DIRS}
-    NO_DEFAULT_PATH
-)
-
-IF (WIN32)
-    SET (SZIP_SEARCH_DEBUG_NAMES "sz_d;libsz_d")
-    SET (SZIP_SEARCH_RELEASE_NAMES "sz;libsz;libszip")
-ELSE (WIN32)
-    SET (SZIP_SEARCH_DEBUG_NAMES "sz_d")
-    SET (SZIP_SEARCH_RELEASE_NAMES "sz;szip")
-ENDIF (WIN32)
-
-# Look for the library.
-FIND_LIBRARY (SZIP_LIBRARY_DEBUG
-    NAMES ${SZIP_SEARCH_DEBUG_NAMES}
-    PATHS ${SZIP_LIB_SEARCH_DIRS}
-    NO_DEFAULT_PATH
-)
-
-FIND_LIBRARY (SZIP_LIBRARY_RELEASE
-    NAMES ${SZIP_SEARCH_RELEASE_NAMES}
-    PATHS ${SZIP_LIB_SEARCH_DIRS}
-    NO_DEFAULT_PATH
-)
-
-SZIP_ADJUST_LIB_VARS (SZIP)
-
-IF (SZIP_INCLUDE_DIR AND SZIP_LIBRARY)
-  SET (SZIP_FOUND 1)
-  SET (SZIP_LIBRARIES ${SZIP_LIBRARY})
-  SET (SZIP_INCLUDE_DIRS ${SZIP_INCLUDE_DIR})
-  IF (SZIP_LIBRARY_DEBUG)
-    GET_FILENAME_COMPONENT (SZIP_LIBRARY_PATH ${SZIP_LIBRARY_DEBUG} PATH)
-    SET (SZIP_LIB_DIR  ${SZIP_LIBRARY_PATH})
-  ELSEIF (SZIP_LIBRARY_RELEASE)
-    GET_FILENAME_COMPONENT (SZIP_LIBRARY_PATH ${SZIP_LIBRARY_RELEASE} PATH)
-    SET (SZIP_LIB_DIR  ${SZIP_LIBRARY_PATH})
-  ENDIF (SZIP_LIBRARY_DEBUG)
-
-ELSE (SZIP_INCLUDE_DIR AND SZIP_LIBRARY)
-  SET (SZIP_FOUND 0)
-  SET (SZIP_LIBRARIES)
-  SET (SZIP_INCLUDE_DIRS)
-ENDIF (SZIP_INCLUDE_DIR AND SZIP_LIBRARY)
-
-# Report the results.
-IF (NOT SZIP_FOUND)
-  SET (SZIP_DIR_MESSAGE
-      "SZip was not found. Make sure SZIP_LIBRARY and SZIP_INCLUDE_DIR are set or set the SZIP_INSTALL environment variable."
-  )
-  IF (NOT SZIP_FIND_QUIETLY)
-    MESSAGE (STATUS "${SZIP_DIR_MESSAGE}")
-  ELSE (NOT SZIP_FIND_QUIETLY)
-    IF (SZIP_FIND_REQUIRED)
-      MESSAGE (FATAL_ERROR "SZip was NOT found and is Required by this project")
-    ENDIF (SZIP_FIND_REQUIRED)
-  ENDIF (NOT SZIP_FIND_QUIETLY)
-ENDIF (NOT SZIP_FOUND)
-
-IF (SZIP_FOUND)
-  INCLUDE (CheckSymbolExists)
-  #############################################
-  # Find out if SZIP was build using dll's
-  #############################################
-  # Save required variable
-  SET (CMAKE_REQUIRED_INCLUDES_SAVE ${CMAKE_REQUIRED_INCLUDES})
-  SET (CMAKE_REQUIRED_FLAGS_SAVE    ${CMAKE_REQUIRED_FLAGS})
-  # Add SZIP_INCLUDE_DIR to CMAKE_REQUIRED_INCLUDES
-  SET (CMAKE_REQUIRED_INCLUDES "${CMAKE_REQUIRED_INCLUDES};${SZIP_INCLUDE_DIRS}")
-
-  CHECK_SYMBOL_EXISTS (SZIP_BUILT_AS_DYNAMIC_LIB "SZconfig.h" HAVE_SZIP_DLL)
-
-  IF (HAVE_SZIP_DLL STREQUAL "TRUE")
-    SET (HAVE_SZIP_DLL "1")
-  ENDIF (HAVE_SZIP_DLL STREQUAL "TRUE")
-
-  # Restore CMAKE_REQUIRED_INCLUDES and CMAKE_REQUIRED_FLAGS variables
-  SET (CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES_SAVE})
-  SET (CMAKE_REQUIRED_FLAGS    ${CMAKE_REQUIRED_FLAGS_SAVE})
-  #
-  #############################################
-ENDIF (SZIP_FOUND)
-
-IF (FIND_SZIP_DEBUG)
-  MESSAGE (STATUS "SZIP_INCLUDE_DIR: ${SZIP_INCLUDE_DIR}")
-  MESSAGE (STATUS "SZIP_INCLUDE_DIRS: ${SZIP_INCLUDE_DIRS}")
-  MESSAGE (STATUS "SZIP_LIBRARY_DEBUG: ${SZIP_LIBRARY_DEBUG}")
-  MESSAGE (STATUS "SZIP_LIBRARY_RELEASE: ${SZIP_LIBRARY_RELEASE}")
-  MESSAGE (STATUS "HAVE_SZIP_DLL: ${HAVE_SZIP_DLL}")
-  MESSAGE (STATUS "CMAKE_BUILD_TYPE: ${CMAKE_BUILD_TYPE}")
-ENDIF (FIND_SZIP_DEBUG)
diff --git a/config/cmake/HDF4Macros.cmake b/config/cmake/HDF4Macros.cmake
index e9d25fd..5c863c8 100644
--- a/config/cmake/HDF4Macros.cmake
+++ b/config/cmake/HDF4Macros.cmake
@@ -1,32 +1,27 @@
 #-------------------------------------------------------------------------------
 MACRO (H4_SET_LIB_OPTIONS libtarget libname libtype)
-  SET (LIB_OUT_NAME "${libname}")
-  IF (${libtype} MATCHES "SHARED")
-    IF (WIN32)
-      SET (LIBHDF_VERSION ${HDF4_PACKAGE_VERSION_MAJOR})
-    ELSE (WIN32)
-      SET (LIBHDF_VERSION ${HDF4_PACKAGE_VERSION})
-    ENDIF (WIN32)
-    SET_TARGET_PROPERTIES (${libtarget} PROPERTIES VERSION ${LIBHDF_VERSION})
-#    IF (WIN32)
-#        SET (${LIB_OUT_NAME} "${LIB_OUT_NAME}-${HDF4_PACKAGE_SOVERSION}")
-#    ELSE (WIN32)
-#        SET_TARGET_PROPERTIES (${libtarget} PROPERTIES SOVERSION ${HDF4_PACKAGE_SOVERSION})
-#    ENDIF (WIN32)
-    SET_TARGET_PROPERTIES (${libtarget} PROPERTIES SOVERSION ${LIBHDF_VERSION})
-  ENDIF (${libtype} MATCHES "SHARED")
+  set (LIB_OUT_NAME "${libname}")
+  if (${libtype} MATCHES "SHARED")
+    if (WIN32)
+      set (LIBHDF_VERSION ${HDF4_PACKAGE_VERSION_MAJOR})
+    else (WIN32)
+      set (LIBHDF_VERSION ${HDF4_PACKAGE_VERSION})
+    endif (WIN32)
+    set_target_properties (${libtarget} PROPERTIES VERSION ${LIBHDF_VERSION})
+    set_target_properties (${libtarget} PROPERTIES SOVERSION ${LIBHDF_VERSION})
+  endif (${libtype} MATCHES "SHARED")
   HDF_SET_LIB_OPTIONS (${libtarget} ${LIB_OUT_NAME} ${libtype})
 
   #-- Apple Specific install_name for libraries
-  IF (APPLE)
-    OPTION (HDF4_BUILD_WITH_INSTALL_NAME "Build with library install_name set to the installation path" OFF)
-    IF (HDF4_BUILD_WITH_INSTALL_NAME)
-      SET_TARGET_PROPERTIES (${libtarget} PROPERTIES
+  if (APPLE)
+    option (HDF4_BUILD_WITH_INSTALL_NAME "Build with library install_name set to the installation path" OFF)
+    if (HDF4_BUILD_WITH_INSTALL_NAME)
+      set_target_properties (${libtarget} PROPERTIES
           LINK_FLAGS "-current_version ${HDF4_PACKAGE_VERSION} -compatibility_version ${HDF4_PACKAGE_VERSION}"
           INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib"
           BUILD_WITH_INSTALL_RPATH ${HDF4_BUILD_WITH_INSTALL_NAME}
       )
-    ENDIF (HDF4_BUILD_WITH_INSTALL_NAME)
-  ENDIF (APPLE)
+    endif (HDF4_BUILD_WITH_INSTALL_NAME)
+  endif (APPLE)
 
 ENDMACRO (H4_SET_LIB_OPTIONS)
diff --git a/config/cmake/HDF4UseFortran.cmake b/config/cmake/HDF4UseFortran.cmake
index 175447b..febbcbd 100644
--- a/config/cmake/HDF4UseFortran.cmake
+++ b/config/cmake/HDF4UseFortran.cmake
@@ -2,12 +2,12 @@
 # This file provides functions for Fortran support.
 #
 #-------------------------------------------------------------------------------
-ENABLE_LANGUAGE (Fortran)
+enable_language (Fortran)
   
 #-----------------------------------------------------------------------------
 # Detect name mangling convention used between Fortran and C
 #-----------------------------------------------------------------------------
-INCLUDE (FortranCInterface)
+include (FortranCInterface)
 FortranCInterface_HEADER (
     ${CMAKE_BINARY_DIR}/F77Mangle.h
     MACRO_NAMESPACE "H4_F77_"
@@ -15,57 +15,57 @@ FortranCInterface_HEADER (
     SYMBOLS mysub mymod:my_sub
 )
 
-FILE (STRINGS ${CMAKE_BINARY_DIR}/F77Mangle.h CONTENTS REGEX "H4_F77_GLOBAL\\(.*,.*\\) +(.*)")
-STRING (REGEX MATCH "H4_F77_GLOBAL\\(.*,.*\\) +(.*)" RESULT ${CONTENTS})
-SET (H4_F77_FUNC "H4_F77_FUNC(name,NAME) ${CMAKE_MATCH_1}")
+file (STRINGS ${CMAKE_BINARY_DIR}/F77Mangle.h CONTENTS REGEX "H4_F77_GLOBAL\\(.*,.*\\) +(.*)")
+string (REGEX MATCH "H4_F77_GLOBAL\\(.*,.*\\) +(.*)" RESULT ${CONTENTS})
+set (H4_F77_FUNC "H4_F77_FUNC(name,NAME) ${CMAKE_MATCH_1}")
 
-FILE (STRINGS ${CMAKE_BINARY_DIR}/F77Mangle.h CONTENTS REGEX "H4_F77_GLOBAL_\\(.*,.*\\) +(.*)")
-STRING (REGEX MATCH "H4_F77_GLOBAL_\\(.*,.*\\) +(.*)" RESULT ${CONTENTS})
-SET (H4_F77_FUNC_ "H4_F77_FUNC_(name,NAME) ${CMAKE_MATCH_1}")
+file (STRINGS ${CMAKE_BINARY_DIR}/F77Mangle.h CONTENTS REGEX "H4_F77_GLOBAL_\\(.*,.*\\) +(.*)")
+string (REGEX MATCH "H4_F77_GLOBAL_\\(.*,.*\\) +(.*)" RESULT ${CONTENTS})
+set (H4_F77_FUNC_ "H4_F77_FUNC_(name,NAME) ${CMAKE_MATCH_1}")
 
 #-----------------------------------------------------------------------------
 # The provided CMake Fortran macros don't provide a general check function
 # so this one is used for a sizeof test.
 #-----------------------------------------------------------------------------
 MACRO (CHECK_FORTRAN_FEATURE FUNCTION CODE VARIABLE)
-  IF (NOT DEFINED ${VARIABLE})
-    MESSAGE (STATUS "Testing Fortran ${FUNCTION}")
-    IF (CMAKE_REQUIRED_LIBRARIES)
-      SET (CHECK_FUNCTION_EXISTS_ADD_LIBRARIES
+  if (NOT DEFINED ${VARIABLE})
+    message (STATUS "Testing Fortran ${FUNCTION}")
+    if (CMAKE_REQUIRED_LIBRARIES)
+      set (CHECK_FUNCTION_EXISTS_ADD_LIBRARIES
           "-DLINK_LIBRARIES:STRING=${CMAKE_REQUIRED_LIBRARIES}")
-    ELSE (CMAKE_REQUIRED_LIBRARIES)
-      SET (CHECK_FUNCTION_EXISTS_ADD_LIBRARIES)
-    ENDIF (CMAKE_REQUIRED_LIBRARIES)
-    FILE (WRITE
+    else (CMAKE_REQUIRED_LIBRARIES)
+      set (CHECK_FUNCTION_EXISTS_ADD_LIBRARIES)
+    endif (CMAKE_REQUIRED_LIBRARIES)
+    file (WRITE
         ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testFortranCompiler.f
         "${CODE}"
     )
-    TRY_COMPILE (${VARIABLE}
+    try_compile (${VARIABLE}
         ${CMAKE_BINARY_DIR}
         ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testFortranCompiler.f
         CMAKE_FLAGS "${CHECK_FUNCTION_EXISTS_ADD_LIBRARIES}"
         OUTPUT_VARIABLE OUTPUT
     )
 
-#    MESSAGE ( "* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * ")
-#    MESSAGE ( "Test result ${OUTPUT}")
-#    MESSAGE ( "* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * ")
+#    message ( "* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * ")
+#    message ( "Test result ${OUTPUT}")
+#    message ( "* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * ")
 
-    IF (${VARIABLE})
-      SET (${VARIABLE} 1 CACHE INTERNAL "Have Fortran function ${FUNCTION}")
-      MESSAGE (STATUS "Testing Fortran ${FUNCTION} - OK")
-      FILE (APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
+    if (${VARIABLE})
+      set (${VARIABLE} 1 CACHE INTERNAL "Have Fortran function ${FUNCTION}")
+      message (STATUS "Testing Fortran ${FUNCTION} - OK")
+      file (APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
           "Determining if the Fortran ${FUNCTION} exists passed with the following output:\n"
           "${OUTPUT}\n\n"
       )
-    ELSE (${VARIABLE})
-      MESSAGE (STATUS "Testing Fortran ${FUNCTION} - Fail")
-      SET (${VARIABLE} "" CACHE INTERNAL "Have Fortran function ${FUNCTION}")
-      FILE (APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
+    else (${VARIABLE})
+      message (STATUS "Testing Fortran ${FUNCTION} - Fail")
+      set (${VARIABLE} "" CACHE INTERNAL "Have Fortran function ${FUNCTION}")
+      file (APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
           "Determining if the Fortran ${FUNCTION} exists failed with the following output:\n"
           "${OUTPUT}\n\n")
-    ENDIF (${VARIABLE})
-  ENDIF (NOT DEFINED ${VARIABLE})
+    endif (${VARIABLE})
+  endif (NOT DEFINED ${VARIABLE})
 ENDMACRO (CHECK_FORTRAN_FEATURE)
 
 #-----------------------------------------------------------------------------
@@ -113,9 +113,9 @@ CHECK_FORTRAN_FEATURE(RealIsNotDouble
 #-----------------------------------------------------------------------------
 # Add debug information (intel Fortran : JB)
 #-----------------------------------------------------------------------------
-IF (CMAKE_Fortran_COMPILER MATCHES ifort)
-    IF (WIN32)
-        SET (CMAKE_Fortran_FLAGS_DEBUG "/debug:full /dbglibs " CACHE "flags" STRING FORCE)
-        SET (CMAKE_EXE_LINKER_FLAGS_DEBUG "/DEBUG" CACHE "flags" STRING FORCE)
-    ENDIF (WIN32)
-ENDIF (CMAKE_Fortran_COMPILER MATCHES ifort)
+if (CMAKE_Fortran_COMPILER MATCHES ifort)
+    if (WIN32)
+        set (CMAKE_Fortran_FLAGS_DEBUG "/debug:full /dbglibs " CACHE "flags" STRING FORCE)
+        set (CMAKE_EXE_LINKER_FLAGS_DEBUG "/DEBUG" CACHE "flags" STRING FORCE)
+    endif (WIN32)
+endif (CMAKE_Fortran_COMPILER MATCHES ifort)
diff --git a/config/cmake/HDF4_Examples.cmake.in b/config/cmake/HDF4_Examples.cmake.in
index 1c5d469..373081a 100644
--- a/config/cmake/HDF4_Examples.cmake.in
+++ b/config/cmake/HDF4_Examples.cmake.in
@@ -2,17 +2,18 @@ cmake_minimum_required(VERSION 2.8.10 FATAL_ERROR)
 ###############################################################################################################
 # This script will build and run the examples from a compressed file
 # Execute from a command line:
-#     ctest -S HDF4_Examples.cmake,HDF4Examples-0.1.1-Source -C Release -O test.log
+#     ctest -S HDF4_Examples.cmake,HDF4Examples-0.1.1-Source -C Release -V -O test.log
 ###############################################################################################################
 
-set(INSTALLDIR "@CMAKE_INSTALL_PREFIX@/HDF_Group/@HDF4_PACKAGE_NAME@/@HDF4_PACKAGE_VERSION@")
+set(INSTALLDIR "@CMAKE_INSTALL_PREFIX@")
 set(CTEST_CMAKE_GENERATOR "@CMAKE_GENERATOR@")
 set(STATICLIBRARIES "@H4_ENABLE_STATIC_LIB@")
 set(CTEST_SOURCE_NAME ${CTEST_SCRIPT_ARG})
 set(CTEST_DASHBOARD_ROOT ${CTEST_SCRIPT_DIRECTORY})
 set(CTEST_BUILD_CONFIGURATION "Release")
 #set(NO_MAC_FORTRAN "true")
-set(BUILD_OPTIONS "${BUILD_OPTIONS} -DHDF_BUILD_FORTRAN:BOOL=OFF")
+#set(BUILD_OPTIONS "${BUILD_OPTIONS} -DHDF_BUILD_FORTRAN:BOOL=ON")
+set(CTEST_USE_TAR_SOURCE "${CTEST_SCRIPT_ARG}")
 
 ###############################################################################################################
 #     Adjust the following SET Commands as needed
@@ -54,36 +55,41 @@ if(APPLE)
     # Shared fortran is not supported, build static 
     set(BUILD_OPTIONS "${BUILD_OPTIONS} -DBUILD_SHARED_LIBS:BOOL=OFF -DCMAKE_ANSI_CFLAGS:STRING=-fPIC")
   else(NOT NO_MAC_FORTRAN)
-    set(BUILD_OPTIONS "${BUILD_OPTIONS} -DHDF4_BUILD_FORTRAN:BOOL=OFF")
+    set(BUILD_OPTIONS "${BUILD_OPTIONS} -DHDF_BUILD_FORTRAN:BOOL=OFF")
   endif(NOT NO_MAC_FORTRAN)
   set(BUILD_OPTIONS "${BUILD_OPTIONS} -DCTEST_USE_LAUNCHERS:BOOL=ON -DCMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=OFF")
 endif(APPLE)
  
 #-----------------------------------------------------------------------------
 set(CTEST_CMAKE_COMMAND "\"${CMAKE_COMMAND}\"")
-## Uncompress source in tar file provided
 ## --------------------------
-if(WIN32)
-  set(CTEST_7Z_COMMAND "C:/Program Files/7-Zip/7z.exe")
-  message("extracting... [${CTEST_7Z_COMMAND} x ${CTEST_SOURCE_NAME}.zip]")
-  execute_process(COMMAND ${CTEST_7Z_COMMAND} x ${CTEST_SOURCE_NAME}.zip RESULT_VARIABLE rv)
-else(WIN32)
-  message("extracting... [${CTEST_CMAKE_COMMAND} -E tar -xvf ${CTEST_SOURCE_NAME}.tar.gz]")
-  execute_process(COMMAND tar -xvf ${CTEST_SOURCE_NAME}.tar.gz RESULT_VARIABLE rv)
-endif(WIN32)
+if(CTEST_USE_TAR_SOURCE)
+  ## Uncompress source if tar or zip file provided
+  ## --------------------------
+  if(WIN32)
+    message(STATUS "extracting... [${CMAKE_EXECUTABLE_NAME} -E tar -xvf ${CTEST_USE_TAR_SOURCE}.zip]")
+    execute_process(COMMAND ${CMAKE_EXECUTABLE_NAME} -E tar -xvf ${CTEST_USE_TAR_SOURCE}.zip RESULT_VARIABLE rv)
+  else(WIN32)
+    message(STATUS "extracting... [${CMAKE_EXECUTABLE_NAME} -E tar -xvf ${CTEST_USE_TAR_SOURCE}.tar]")
+    execute_process(COMMAND ${CMAKE_EXECUTABLE_NAME} -E tar -xvf ${CTEST_USE_TAR_SOURCE}.tar RESULT_VARIABLE rv)
+  endif(WIN32)
  
-if(NOT rv EQUAL 0)
-  message("extracting... [error-(${rv}) clean up]")
-  file(REMOVE_RECURSE "${CTEST_SOURCE_DIRECTORY}")
-  message(FATAL_ERROR "error: extract of ${CTEST_SOURCE_NAME} failed")
-endif(NOT rv EQUAL 0)
+  if(NOT rv EQUAL 0)
+    message(STATUS "extracting... [error-(${rv}) clean up]")
+    file(REMOVE_RECURSE "${CTEST_SOURCE_DIRECTORY}")
+    message(FATAL_ERROR "error: extract of ${CTEST_SOURCE_NAME} failed")
+  endif(NOT rv EQUAL 0)
+endif(CTEST_USE_TAR_SOURCE)
  
 #-----------------------------------------------------------------------------
 ## Clear the build directory
 ## --------------------------
 set(CTEST_START_WITH_EMPTY_BINARY_DIRECTORY TRUE)
-file(MAKE_DIRECTORY "${CTEST_BINARY_DIRECTORY}")
-ctest_empty_binary_directory(${CTEST_BINARY_DIRECTORY})
+if (EXISTS "${CTEST_BINARY_DIRECTORY}" AND IS_DIRECTORY "${CTEST_BINARY_DIRECTORY}")
+  ctest_empty_binary_directory(${CTEST_BINARY_DIRECTORY})
+else (EXISTS "${CTEST_BINARY_DIRECTORY}" AND IS_DIRECTORY "${CTEST_BINARY_DIRECTORY}")
+  file(MAKE_DIRECTORY "${CTEST_BINARY_DIRECTORY}")
+endif (EXISTS "${CTEST_BINARY_DIRECTORY}" AND IS_DIRECTORY "${CTEST_BINARY_DIRECTORY}")
 
 # Use multiple CPU cores to build
 include(ProcessorCount)
@@ -115,4 +121,4 @@ set($ENV{LC_MESSAGES}  "en_EN")
   endif(res GREATER 0)
 #-----------------------------------------------------------------------------
 ############################################################################################################## 
-message("DONE")
\ No newline at end of file
+message(STATUS "DONE")
\ No newline at end of file
diff --git a/config/cmake/HDFLibMacros.cmake b/config/cmake/HDFLibMacros.cmake
deleted file mode 100644
index 57e6be7..0000000
--- a/config/cmake/HDFLibMacros.cmake
+++ /dev/null
@@ -1,350 +0,0 @@
-#-------------------------------------------------------------------------------
-MACRO (EXTERNAL_JPEG_LIBRARY compress_type libtype jpeg_pic)
-  # May need to build JPEG with PIC on x64 machines with gcc
-  # Need to use CMAKE_ANSI_CFLAGS define so that compiler test works
-
-  IF (${compress_type} MATCHES "SVN")
-    EXTERNALPROJECT_ADD (JPEG
-        SVN_REPOSITORY ${JPEG_URL}
-        # [SVN_REVISION rev] 
-        INSTALL_COMMAND ""
-        CMAKE_ARGS
-            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
-            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
-            -DJPEG_EXTERNALLY_CONFIGURED:BOOL=OFF
-            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
-            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
-            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
-            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
-            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
-            -DCMAKE_ANSI_CFLAGS:STRING=${jpeg_pic}
-    ) 
-  ELSEIF (${compress_type} MATCHES "TGZ")
-    EXTERNALPROJECT_ADD (JPEG
-        URL ${JPEG_URL}
-        URL_MD5 ""
-        INSTALL_COMMAND ""
-        CMAKE_ARGS
-            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
-            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
-            -DJPEG_EXTERNALLY_CONFIGURED:BOOL=OFF
-            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
-            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
-            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
-            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
-            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
-            -DCMAKE_ANSI_CFLAGS:STRING=${jpeg_pic}
-    ) 
-  ENDIF (${compress_type} MATCHES "SVN")
-  EXTERNALPROJECT_GET_PROPERTY (JPEG BINARY_DIR SOURCE_DIR) 
-
-  IF (${CMAKE_BUILD_TYPE} MATCHES "Debug")
-    IF (WIN32)
-      SET (JPEG_LIB_NAME "jpeg_D")
-    ELSE (WIN32)
-      SET (JPEG_LIB_NAME "jpeg_debug")
-    ENDIF (WIN32)
-  ELSE (${CMAKE_BUILD_TYPE} MATCHES "Debug")
-    SET (JPEG_LIB_NAME "jpeg")
-  ENDIF (${CMAKE_BUILD_TYPE} MATCHES "Debug")
-
-  # Create imported target szip
-  ADD_LIBRARY(jpeg ${libtype} IMPORTED)
-  ADD_DEPENDENCIES (jpeg JPEG)
-
-  IF (${libtype} MATCHES "SHARED")
-    IF (WIN32)
-      IF (MINGW)
-        SET_TARGET_PROPERTIES(jpeg PROPERTIES
-            IMPORTED_IMPLIB "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${JPEG_LIB_NAME}.lib"
-            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${JPEG_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
-        )
-      ELSE (MINGW)
-        SET_TARGET_PROPERTIES(jpeg PROPERTIES
-            IMPORTED_IMPLIB "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${CMAKE_IMPORT_LIBRARY_PREFIX}${JPEG_LIB_NAME}${CMAKE_IMPORT_LIBRARY_SUFFIX}"
-            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${CMAKE_IMPORT_LIBRARY_PREFIX}${JPEG_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
-        )
-      ENDIF (MINGW)
-    ELSE (WIN32)
-      IF (CYGWIN)
-        SET_TARGET_PROPERTIES(jpeg PROPERTIES
-            IMPORTED_IMPLIB "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_IMPORT_LIBRARY_PREFIX}${JPEG_LIB_NAME}${CMAKE_IMPORT_LIBRARY_SUFFIX}"
-            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_IMPORT_LIBRARY_PREFIX}${JPEG_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
-        )
-      ELSE (CYGWIN)
-        SET_TARGET_PROPERTIES(jpeg PROPERTIES
-            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_SHARED_LIBRARY_PREFIX}${JPEG_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
-            IMPORTED_SONAME "${CMAKE_SHARED_LIBRARY_PREFIX}${JPEG_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}.${JPEG_VERSION_STRING}"
-            SOVERSION "${JPEG_VERSION_STRING}"
-        )
-      ENDIF (CYGWIN)
-    ENDIF (WIN32)
-  ELSE (${libtype} MATCHES "SHARED")
-    IF (WIN32 AND NOT MINGW)
-      SET_TARGET_PROPERTIES(jpeg PROPERTIES
-          IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/lib${JPEG_LIB_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX}"
-          IMPORTED_LINK_INTERFACE_LANGUAGES "C"
-      )
-    ELSE (WIN32 AND NOT MINGW)
-      SET_TARGET_PROPERTIES(jpeg PROPERTIES
-          IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/lib${JPEG_LIB_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX}"
-          IMPORTED_LINK_INTERFACE_LANGUAGES "C"
-      )
-    ENDIF (WIN32 AND NOT MINGW)
-  ENDIF (${libtype} MATCHES "SHARED")
-
-#  INCLUDE (${BINARY_DIR}/JPEG-targets.cmake)  
-  SET (JPEG_LIBRARY "jpeg")
-  
-  SET (JPEG_INCLUDE_DIR_GEN "${BINARY_DIR}")
-  SET (JPEG_INCLUDE_DIR "${SOURCE_DIR}/src")
-  SET (JPEG_FOUND 1)
-  SET (JPEG_LIBRARIES ${JPEG_LIBRARY})
-  SET (JPEG_INCLUDE_DIRS ${JPEG_INCLUDE_DIR_GEN} ${JPEG_INCLUDE_DIR})
-ENDMACRO (EXTERNAL_JPEG_LIBRARY)
-
-#-------------------------------------------------------------------------------
-MACRO (PACKAGE_JPEG_LIBRARY compress_type)
-  ADD_CUSTOM_TARGET (JPEG-GenHeader-Copy ALL
-      COMMAND ${CMAKE_COMMAND} -E copy_if_different ${JPEG_INCLUDE_DIR_GEN}/jconfig.h ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/
-      COMMENT "Copying ${JPEG_INCLUDE_DIR_GEN}/jconfig.h to ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/"
-  )
-  SET (EXTERNAL_HEADER_LIST ${EXTERNAL_HEADER_LIST} ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/jconfig.h)
-  IF (${compress_type} MATCHES "SVN" OR ${compress_type} MATCHES "TGZ")
-    ADD_DEPENDENCIES (JPEG-GenHeader-Copy JPEG)
-  ENDIF (${compress_type} MATCHES "SVN" OR ${compress_type} MATCHES "TGZ")
-ENDMACRO (PACKAGE_JPEG_LIBRARY)
-
-#-------------------------------------------------------------------------------
-MACRO (EXTERNAL_SZIP_LIBRARY compress_type libtype encoding)
-  IF (${compress_type} MATCHES "SVN")
-    EXTERNALPROJECT_ADD (SZIP
-        SVN_REPOSITORY ${SZIP_URL}
-        # [SVN_REVISION rev] 
-        INSTALL_COMMAND ""
-        CMAKE_ARGS
-            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
-            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
-            -DSZIP_EXTERNALLY_CONFIGURED:BOOL=OFF
-            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
-            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
-            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
-            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
-            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
-            -DCMAKE_ANSI_CFLAGS:STRING=${CMAKE_ANSI_CFLAGS}
-            -DSZIP_ENABLE_ENCODING:BOOL=${encoding}
-    ) 
-  ELSEIF (${compress_type} MATCHES "TGZ")
-    EXTERNALPROJECT_ADD (SZIP
-        URL ${SZIP_URL}
-        URL_MD5 ""
-        INSTALL_COMMAND ""
-        CMAKE_ARGS
-            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
-            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
-            -DSZIP_EXTERNALLY_CONFIGURED:BOOL=OFF
-            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
-            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
-            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
-            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
-            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
-            -DCMAKE_ANSI_CFLAGS:STRING=${CMAKE_ANSI_CFLAGS}
-            -DSZIP_ENABLE_ENCODING:BOOL=${encoding}
-    ) 
-  ENDIF (${compress_type} MATCHES "SVN")
-  EXTERNALPROJECT_GET_PROPERTY (SZIP BINARY_DIR SOURCE_DIR) 
-
-  IF (${CMAKE_BUILD_TYPE} MATCHES "Debug")
-    IF (WIN32)
-      SET (SZIP_LIB_NAME "szip_D")
-    ELSE (WIN32)
-      SET (SZIP_LIB_NAME "szip_debug")
-    ENDIF (WIN32)
-  ELSE (${CMAKE_BUILD_TYPE} MATCHES "Debug")
-    SET (SZIP_LIB_NAME "szip")
-  ENDIF (${CMAKE_BUILD_TYPE} MATCHES "Debug")
-
-  # Create imported target szip
-  ADD_LIBRARY(szip ${libtype} IMPORTED)
-  ADD_DEPENDENCIES (szip SZIP)
-
-  IF (${libtype} MATCHES "SHARED")
-    IF (WIN32)
-      IF (MINGW)
-        SET_TARGET_PROPERTIES(szip PROPERTIES
-            IMPORTED_IMPLIB "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${SZIP_LIB_NAME}.lib"
-            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${SZIP_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
-        )
-      ELSE (MINGW)
-        SET_TARGET_PROPERTIES(szip PROPERTIES
-            IMPORTED_IMPLIB "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${CMAKE_IMPORT_LIBRARY_PREFIX}${SZIP_LIB_NAME}${CMAKE_IMPORT_LIBRARY_SUFFIX}"
-            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${CMAKE_IMPORT_LIBRARY_PREFIX}${SZIP_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
-        )
-      ENDIF (MINGW)
-    ELSE (WIN32)
-      IF (CYGWIN)
-        SET_TARGET_PROPERTIES(szip PROPERTIES
-            IMPORTED_IMPLIB "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_IMPORT_LIBRARY_PREFIX}${SZIP_LIB_NAME}${CMAKE_IMPORT_LIBRARY_SUFFIX}"
-            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_IMPORT_LIBRARY_PREFIX}${SZIP_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
-        )
-      ELSE (CYGWIN)
-        SET_TARGET_PROPERTIES(szip PROPERTIES
-            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_SHARED_LIBRARY_PREFIX}${SZIP_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
-            IMPORTED_SONAME "${CMAKE_SHARED_LIBRARY_PREFIX}${SZIP_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}.${SZIP_VERSION_STRING}"
-            SOVERSION "${SZIP_VERSION_STRING}"
-        )
-      ENDIF (CYGWIN)
-    ENDIF (WIN32)
-  ELSE (${libtype} MATCHES "SHARED")
-    IF (WIN32 AND NOT MINGW)
-      SET_TARGET_PROPERTIES(szip PROPERTIES
-          IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/lib${SZIP_LIB_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX}"
-          IMPORTED_LINK_INTERFACE_LANGUAGES "C"
-      )
-    ELSE (WIN32 AND NOT MINGW)
-      SET_TARGET_PROPERTIES(szip PROPERTIES
-          IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/lib${SZIP_LIB_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX}"
-          IMPORTED_LINK_INTERFACE_LANGUAGES "C"
-      )
-    ENDIF (WIN32 AND NOT MINGW)
-  ENDIF (${libtype} MATCHES "SHARED")
-
-#  INCLUDE (${BINARY_DIR}/SZIP-targets.cmake)  
-  SET (SZIP_LIBRARY "szip")
-
-  SET (SZIP_INCLUDE_DIR_GEN "${BINARY_DIR}")
-  SET (SZIP_INCLUDE_DIR "${SOURCE_DIR}/src")
-  SET (SZIP_FOUND 1)
-  SET (SZIP_LIBRARIES ${SZIP_LIBRARY})
-  SET (SZIP_INCLUDE_DIRS ${SZIP_INCLUDE_DIR_GEN} ${SZIP_INCLUDE_DIR})
-ENDMACRO (EXTERNAL_SZIP_LIBRARY)
-
-#-------------------------------------------------------------------------------
-MACRO (PACKAGE_SZIP_LIBRARY compress_type)
-  ADD_CUSTOM_TARGET (SZIP-GenHeader-Copy ALL
-      COMMAND ${CMAKE_COMMAND} -E copy_if_different ${SZIP_INCLUDE_DIR_GEN}/SZconfig.h ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/
-      COMMENT "Copying ${SZIP_INCLUDE_DIR_GEN}/SZconfig.h to ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/"
-  )
-  SET (EXTERNAL_HEADER_LIST ${EXTERNAL_HEADER_LIST} ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/SZconfig.h)
-  IF (${compress_type} MATCHES "SVN" OR ${compress_type} MATCHES "TGZ")
-    ADD_DEPENDENCIES (SZIP-GenHeader-Copy SZIP)
-  ENDIF (${compress_type} MATCHES "SVN" OR ${compress_type} MATCHES "TGZ")
-ENDMACRO (PACKAGE_SZIP_LIBRARY)
-
-#-------------------------------------------------------------------------------
-MACRO (EXTERNAL_ZLIB_LIBRARY compress_type libtype)
-  IF (${compress_type} MATCHES "SVN")
-    EXTERNALPROJECT_ADD (ZLIB
-        SVN_REPOSITORY ${ZLIB_URL}
-        # [SVN_REVISION rev] 
-        INSTALL_COMMAND ""
-        CMAKE_ARGS
-            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
-            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
-            -DZLIB_EXTERNALLY_CONFIGURED:BOOL=OFF
-            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
-            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
-            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
-            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
-            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
-            -DCMAKE_ANSI_CFLAGS:STRING=${CMAKE_ANSI_CFLAGS}
-    ) 
-  ELSEIF (${compress_type} MATCHES "TGZ")
-    EXTERNALPROJECT_ADD (ZLIB
-        URL ${ZLIB_URL}
-        URL_MD5 ""
-        INSTALL_COMMAND ""
-        CMAKE_ARGS
-            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
-            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
-            -DZLIB_EXTERNALLY_CONFIGURED:BOOL=OFF
-            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
-            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
-            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
-            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
-            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
-            -DCMAKE_ANSI_CFLAGS:STRING=${CMAKE_ANSI_CFLAGS}
-    ) 
-  ENDIF (${compress_type} MATCHES "SVN")
-  EXTERNALPROJECT_GET_PROPERTY (ZLIB BINARY_DIR SOURCE_DIR) 
-
-  IF (${CMAKE_BUILD_TYPE} MATCHES "Debug")
-    IF (WIN32)
-      SET (ZLIB_LIB_NAME "zlib_D")
-    ELSE (WIN32)
-      SET (ZLIB_LIB_NAME "z_debug")
-    ENDIF (WIN32)
-  ELSE (${CMAKE_BUILD_TYPE} MATCHES "Debug")
-    IF (WIN32)
-      SET (ZLIB_LIB_NAME "zlib")
-    ELSE (WIN32)
-      SET (ZLIB_LIB_NAME "z")
-    ENDIF (WIN32)
-  ENDIF (${CMAKE_BUILD_TYPE} MATCHES "Debug")
-
-  # Create imported target szip
-  ADD_LIBRARY(zlib ${libtype} IMPORTED)
-  ADD_DEPENDENCIES (zlib ZLIB)
-  
-  IF (${libtype} MATCHES "SHARED")
-    IF (WIN32)
-      IF (MINGW)
-        SET_TARGET_PROPERTIES(zlib PROPERTIES
-            IMPORTED_IMPLIB "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${ZLIB_LIB_NAME}.lib"
-            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${ZLIB_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
-        )
-      ELSE (MINGW)
-        SET_TARGET_PROPERTIES(zlib PROPERTIES
-            IMPORTED_IMPLIB "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${CMAKE_IMPORT_LIBRARY_PREFIX}${ZLIB_LIB_NAME}${CMAKE_IMPORT_LIBRARY_SUFFIX}"
-            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${CMAKE_IMPORT_LIBRARY_PREFIX}${ZLIB_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
-        )
-      ENDIF (MINGW)
-    ELSE (WIN32)
-      IF (CYGWIN)
-        SET_TARGET_PROPERTIES(zlib PROPERTIES
-            IMPORTED_IMPLIB "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_IMPORT_LIBRARY_PREFIX}${ZLIB_LIB_NAME}${CMAKE_IMPORT_LIBRARY_SUFFIX}"
-            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_IMPORT_LIBRARY_PREFIX}${ZLIB_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
-        )
-      ELSE (CYGWIN)
-        SET_TARGET_PROPERTIES(zlib PROPERTIES
-            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_SHARED_LIBRARY_PREFIX}${ZLIB_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
-            IMPORTED_SONAME "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_SHARED_LIBRARY_PREFIX}${ZLIB_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}.${ZLIB_VERSION_STRING}"
-            SOVERSION "${ZLIB_VERSION_STRING}"
-        )
-      ENDIF (CYGWIN)
-    ENDIF (WIN32)
-  ELSE (${libtype} MATCHES "SHARED")
-    IF (WIN32 AND NOT MINGW)
-      SET_TARGET_PROPERTIES(zlib PROPERTIES
-          IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/lib${ZLIB_LIB_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX}"
-          IMPORTED_LINK_INTERFACE_LANGUAGES "C"
-      )
-    ELSE (WIN32 AND NOT MINGW)
-      SET_TARGET_PROPERTIES(zlib PROPERTIES
-          IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/lib${ZLIB_LIB_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX}"
-          IMPORTED_LINK_INTERFACE_LANGUAGES "C"
-      )
-    ENDIF (WIN32 AND NOT MINGW)
-  ENDIF (${libtype} MATCHES "SHARED")
-
-#  INCLUDE (${BINARY_DIR}/ZLIB-targets.cmake)  
-  SET (ZLIB_LIBRARY "zlib")
-  
-  SET (ZLIB_INCLUDE_DIR_GEN "${BINARY_DIR}")
-  SET (ZLIB_INCLUDE_DIR "${SOURCE_DIR}")
-  SET (ZLIB_FOUND 1)
-  SET (ZLIB_LIBRARIES ${ZLIB_LIBRARY})
-  SET (ZLIB_INCLUDE_DIRS ${ZLIB_INCLUDE_DIR_GEN} ${ZLIB_INCLUDE_DIR})
-ENDMACRO (EXTERNAL_ZLIB_LIBRARY)
-
-#-------------------------------------------------------------------------------
-MACRO (PACKAGE_ZLIB_LIBRARY compress_type)
-  ADD_CUSTOM_TARGET (ZLIB-GenHeader-Copy ALL
-      COMMAND ${CMAKE_COMMAND} -E copy_if_different ${ZLIB_INCLUDE_DIR_GEN}/zconf.h ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/
-      COMMENT "Copying ${ZLIB_INCLUDE_DIR_GEN}/zconf.h to ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/"
-  )
-  SET (EXTERNAL_HEADER_LIST ${EXTERNAL_HEADER_LIST} ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/zconf.h)
-  IF (${compress_type} MATCHES "SVN" OR ${compress_type} MATCHES "TGZ")
-    ADD_DEPENDENCIES (ZLIB-GenHeader-Copy ZLIB)
-  ENDIF (${compress_type} MATCHES "SVN" OR ${compress_type} MATCHES "TGZ")
-ENDMACRO (PACKAGE_ZLIB_LIBRARY)
diff --git a/config/cmake/HDFMacros.cmake b/config/cmake/HDFMacros.cmake
deleted file mode 100644
index b0788f2..0000000
--- a/config/cmake/HDFMacros.cmake
+++ /dev/null
@@ -1,187 +0,0 @@
-#-------------------------------------------------------------------------------
-MACRO (SET_GLOBAL_VARIABLE name value)
-  SET (${name} ${value} CACHE INTERNAL "Used to pass variables between directories" FORCE)
-ENDMACRO (SET_GLOBAL_VARIABLE)
-
-#-------------------------------------------------------------------------------
-MACRO (IDE_GENERATED_PROPERTIES SOURCE_PATH HEADERS SOURCES)
-  #set(source_group_path "Source/AIM/${NAME}")
-  STRING (REPLACE "/" "\\\\" source_group_path ${SOURCE_PATH})
-  source_group (${source_group_path} FILES ${HEADERS} ${SOURCES})
-
-  #-- The following is needed if we ever start to use OS X Frameworks but only
-  #--  works on CMake 2.6 and greater
-  #SET_PROPERTY (SOURCE ${HEADERS}
-  #       PROPERTY MACOSX_PACKAGE_LOCATION Headers/${NAME}
-  #)
-ENDMACRO (IDE_GENERATED_PROPERTIES)
-
-#-------------------------------------------------------------------------------
-MACRO (IDE_SOURCE_PROPERTIES SOURCE_PATH HEADERS SOURCES)
-  #  INSTALL (FILES ${HEADERS}
-  #       DESTINATION include/R3D/${NAME}
-  #       COMPONENT Headers       
-  #  )
-
-  STRING (REPLACE "/" "\\\\" source_group_path ${SOURCE_PATH}  )
-  source_group (${source_group_path} FILES ${HEADERS} ${SOURCES})
-
-  #-- The following is needed if we ever start to use OS X Frameworks but only
-  #--  works on CMake 2.6 and greater
-  #SET_PROPERTY (SOURCE ${HEADERS}
-  #       PROPERTY MACOSX_PACKAGE_LOCATION Headers/${NAME}
-  #)
-ENDMACRO (IDE_SOURCE_PROPERTIES)
-
-#-------------------------------------------------------------------------------
-MACRO (TARGET_NAMING libtarget libtype)
-  IF (WIN32)
-    IF (${libtype} MATCHES "SHARED")
-      SET_TARGET_PROPERTIES (${libtarget} PROPERTIES OUTPUT_NAME "${libtarget}dll")
-    ENDIF (${libtype} MATCHES "SHARED")
-  ENDIF (WIN32)
-ENDMACRO (TARGET_NAMING)
-
-#-------------------------------------------------------------------------------
-MACRO (INSTALL_TARGET_PDB libtarget targetdestination targetcomponent)
-  IF (WIN32 AND MSVC)
-    GET_TARGET_PROPERTY (target_name ${libtarget} RELWITHDEBINFO_OUTPUT_NAME)
-    INSTALL (
-      FILES
-          ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${CMAKE_IMPORT_LIBRARY_PREFIX}${target_name}.pdb
-      DESTINATION
-          ${targetdestination}
-      CONFIGURATIONS RelWithDebInfo
-      COMPONENT ${targetcomponent}
-  )
-  ENDIF (WIN32 AND MSVC)
-ENDMACRO (INSTALL_TARGET_PDB)
-
-#-------------------------------------------------------------------------------
-MACRO (INSTALL_PROGRAM_PDB progtarget targetdestination targetcomponent)
-  IF (WIN32 AND MSVC)
-    GET_TARGET_PROPERTY (target_name ${progtarget} RELWITHDEBINFO_OUTPUT_NAME)
-    GET_TARGET_PROPERTY (target_prefix ${progtarget} PREFIX)
-    INSTALL (
-      FILES
-          ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${target_prefix}${target_name}.pdb
-      DESTINATION
-          ${targetdestination}
-      CONFIGURATIONS RelWithDebInfo
-      COMPONENT ${targetcomponent}
-  )
-  ENDIF (WIN32 AND MSVC)
-ENDMACRO (INSTALL_PROGRAM_PDB)
-
-#-------------------------------------------------------------------------------
-MACRO (HDF_SET_LIB_OPTIONS libtarget libname libtype)
-  # message (STATUS "${libname} libtype: ${libtype}")
-  IF (${libtype} MATCHES "SHARED")
-    IF (WIN32)
-      SET (LIB_RELEASE_NAME "${libname}")
-      SET (LIB_DEBUG_NAME "${libname}_D")
-    ELSE (WIN32)
-      SET (LIB_RELEASE_NAME "${libname}")
-      SET (LIB_DEBUG_NAME "${libname}_debug")
-    ENDIF (WIN32)
-  ELSE (${libtype} MATCHES "SHARED")
-    IF (WIN32)
-      SET (LIB_RELEASE_NAME "lib${libname}")
-      SET (LIB_DEBUG_NAME "lib${libname}_D")
-    ELSE (WIN32)
-      # if the generator supports configuration types or if the CMAKE_BUILD_TYPE has a value
-      IF (CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE)
-        SET (LIB_RELEASE_NAME "${libname}")
-        SET (LIB_DEBUG_NAME "${libname}_debug")
-      ELSE (CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE)
-        SET (LIB_RELEASE_NAME "lib${libname}")
-        SET (LIB_DEBUG_NAME "lib${libname}_debug")
-      ENDIF (CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE)
-    ENDIF (WIN32)
-  ENDIF (${libtype} MATCHES "SHARED")
-  
-  SET_TARGET_PROPERTIES (${libtarget}
-      PROPERTIES
-      DEBUG_OUTPUT_NAME          ${LIB_DEBUG_NAME}
-      RELEASE_OUTPUT_NAME        ${LIB_RELEASE_NAME}
-      MINSIZEREL_OUTPUT_NAME     ${LIB_RELEASE_NAME}
-      RELWITHDEBINFO_OUTPUT_NAME ${LIB_RELEASE_NAME}
-  )
-  
-  #----- Use MSVC Naming conventions for Shared Libraries
-  IF (MINGW AND ${libtype} MATCHES "SHARED")
-    SET_TARGET_PROPERTIES (${libtarget}
-        PROPERTIES
-        IMPORT_SUFFIX ".lib"
-        IMPORT_PREFIX ""
-        PREFIX ""
-    )
-  ENDIF (MINGW AND ${libtype} MATCHES "SHARED")
-
-ENDMACRO (HDF_SET_LIB_OPTIONS)
-
-#-------------------------------------------------------------------------------
-MACRO (TARGET_C_PROPERTIES wintarget addcompileflags addlinkflags)
-  IF (MSVC)
-    TARGET_MSVC_PROPERTIES (${wintarget} "${addcompileflags} ${WIN_COMPILE_FLAGS}" "${addlinkflags} ${WIN_LINK_FLAGS}")
-  ELSE (MSVC)
-    IF (BUILD_SHARED_LIBS)
-      SET_TARGET_PROPERTIES (${wintarget}
-          PROPERTIES
-              COMPILE_FLAGS "${addcompileflags}"
-              LINK_FLAGS "${addlinkflags}"
-      ) 
-    ELSE (BUILD_SHARED_LIBS)
-      SET_TARGET_PROPERTIES (${wintarget}
-          PROPERTIES
-              COMPILE_FLAGS "${addcompileflags}"
-              LINK_FLAGS "${addlinkflags}"
-      ) 
-    ENDIF (BUILD_SHARED_LIBS)
-  ENDIF (MSVC)
-ENDMACRO (TARGET_C_PROPERTIES)
-
-#-------------------------------------------------------------------------------
-MACRO (TARGET_MSVC_PROPERTIES wintarget addcompileflags addlinkflags)
-  IF (MSVC)
-    IF (BUILD_SHARED_LIBS)
-      SET_TARGET_PROPERTIES (${wintarget}
-          PROPERTIES
-              COMPILE_FLAGS "${addcompileflags}"
-              LINK_FLAGS "${addlinkflags}"
-      ) 
-    ELSE (BUILD_SHARED_LIBS)
-      SET_TARGET_PROPERTIES (${wintarget}
-          PROPERTIES
-              COMPILE_FLAGS "${addcompileflags}"
-              LINK_FLAGS "${addlinkflags}"
-      ) 
-    ENDIF (BUILD_SHARED_LIBS)
-  ENDIF (MSVC)
-ENDMACRO (TARGET_MSVC_PROPERTIES)
-
-#-------------------------------------------------------------------------------
-MACRO (TARGET_FORTRAN_PROPERTIES forttarget addcompileflags addlinkflags)
-  IF (WIN32)
-    TARGET_FORTRAN_WIN_PROPERTIES (${forttarget} "${addcompileflags} ${WIN_COMPILE_FLAGS}" "${addlinkflags} ${WIN_LINK_FLAGS}")
-  ENDIF (WIN32)
-ENDMACRO (TARGET_FORTRAN_PROPERTIES)
-
-#-------------------------------------------------------------------------------
-MACRO (TARGET_FORTRAN_WIN_PROPERTIES forttarget addcompileflags addlinkflags)
-  IF (MSVC)
-    IF (BUILD_SHARED_LIBS)
-      SET_TARGET_PROPERTIES (${forttarget}
-          PROPERTIES
-              COMPILE_FLAGS "/dll ${addcompileflags}"
-              LINK_FLAGS "/SUBSYSTEM:CONSOLE ${addlinkflags}"
-      ) 
-    ELSE (BUILD_SHARED_LIBS)
-      SET_TARGET_PROPERTIES (${forttarget}
-          PROPERTIES
-              COMPILE_FLAGS "${addcompileflags}"
-              LINK_FLAGS "/SUBSYSTEM:CONSOLE ${addlinkflags}"
-      ) 
-    ENDIF (BUILD_SHARED_LIBS)
-  ENDIF (MSVC)
-ENDMACRO (TARGET_FORTRAN_WIN_PROPERTIES)
diff --git a/config/cmake/NSIS.InstallOptions.ini.in b/config/cmake/NSIS.InstallOptions.ini.in
index 83ca053..56a66fe 100644
--- a/config/cmake/NSIS.InstallOptions.ini.in
+++ b/config/cmake/NSIS.InstallOptions.ini.in
@@ -1,9 +1,9 @@
 [Settings]
-NumFields=5
+NumFields=4
 
 [Field 1]
 Type=label
-Text=By default @CPACK_PACKAGE_INSTALL_DIRECTORY@ does add its directory to the system PATH.
+Text=By default @CPACK_PACKAGE_NAME@ does add its directory to the system PATH.
 Left=0
 Right=-1
 Top=0
diff --git a/config/cmake/PkgInfo.in b/config/cmake/PkgInfo.in
new file mode 100644
index 0000000..e530f88
--- /dev/null
+++ b/config/cmake/PkgInfo.in
@@ -0,0 +1 @@
+FMWK????
\ No newline at end of file
diff --git a/config/cmake/README.txt.cmake.in b/config/cmake/README.txt.cmake.in
new file mode 100644
index 0000000..5af0de5
--- /dev/null
+++ b/config/cmake/README.txt.cmake.in
@@ -0,0 +1,60 @@
+ at HDF4_PACKAGE_NAME@ version @HDF4_PACKAGE_VERSION_STRING@
+------------------------------------------------------------------------------
+
+This directory contains the binary (release) distribution of 
+ at HDF4_PACKAGE_NAME@- at HDF4_PACKAGE_VERSION_MAJOR@. at HDF4_PACKAGE_VERSION_MINOR@ that was compiled on; 
+    @BINARY_PLATFORM at . 
+ 
+It was built with the following options: 
+	-- @LIB_TYPE@ C/Fortran libraries
+	-- SZIP (encoder enabled), ZLIB, and JPEG
+	-- @LIB_TYPE@ HDF4 tools
+
+The contents of this directory are:
+
+    COPYING                 - Copyright notice
+    README.txt              - This file
+    @HDF4_PACKAGE_NAME at -@HDF4_PACKAGE_VERSION at -@BINARY_SYSTEM_NAME at .@BINARY_INSTALL_ENDING@    - HDF4 Install Utility
+
+We provide the JPEG, ZLIB, SZIP libraries within the installation package for convenience.  
+  
+Installation
+===========================================================================
+1. Execute @HDF4_PACKAGE_NAME at -@HDF4_PACKAGE_VERSION at -@BINARY_SYSTEM_NAME at .@BINARY_INSTALL_ENDING@
+2. Follow prompts
+===========================================================================
+
+After Installation
+===========================================================================
+The compressed examples file HDF4Examples-0.1.1-Source. at BINARY_EXAMPLE_ENDING@, located in the 
+HDF4 install folder, can be built and tested with CMake and the supplied
+HDF4_Examples.cmake file. The HDF4_Examples.cmake expects HDF4 to have
+been installed in the default location with above compilers. Also, CMake 
+and unzip utilities should be installed.
+
+To test the installation with the examples;
+    Create a directory to run the examples.
+    Copy HDF4Examples-0.1.1-Source. at BINARY_EXAMPLE_ENDING@ to this directory, do NOT unzip.
+    Copy HDF4_Examples.cmake to this directory.
+    Edit HDF4_Examples.cmake line 8 to set INSTALLDIR to where HDF4 is installed.
+    NOTE for Windows: comment line 16 with a '#' character if you do not have a command line 
+              unzip program. Use Windows Explorer to unzip the HDF4Examples-0.1.1-Source. at BINARY_EXAMPLE_ENDING@ file.
+              Edit line 9 for CMake 2.x by removing the 4 digit VS version from the Generator value.
+    Execute from this directory: 
+        ctest -S HDF4_Examples.cmake,HDF4Examples-0.1.1-Source -C Release -O test.log -VV
+
+When executed, the ctest script will save the results to the log file, test.log, as
+indicated by the ctest command. If you wish the to see more build and test information, 
+add "-VV" to the ctest command. The output should show near the end;
+      100% tests passed, 0 tests failed out of 49.
+
+For more information see USING_CMake_Examples.txt in the install folder. 
+===========================================================================
+
+Documentation for this release can be found at the following URL:
+    http://www.hdfgroup.org/doc.html
+
+See the HDF4 home page for further details:
+    http://hdfgroup.org/products/hdf4/
+
+Bugs should be reported to help at hdfgroup.org.
diff --git a/config/cmake/UserMacros/Windows_MT.cmake b/config/cmake/UserMacros/Windows_MT.cmake
index 175c420..a54f22c 100644
--- a/config/cmake/UserMacros/Windows_MT.cmake
+++ b/config/cmake/UserMacros/Windows_MT.cmake
@@ -11,31 +11,31 @@
 # Option to Build with Static CRT libraries on Windows
 #-------------------------------------------------------------------------------
 MACRO (TARGET_STATIC_CRT_FLAGS)
-  IF (MSVC AND NOT BUILD_SHARED_LIBS)
-    FOREACH (flag_var
+  if (MSVC AND NOT BUILD_SHARED_LIBS)
+    foreach (flag_var
         CMAKE_C_FLAGS CMAKE_C_FLAGS_DEBUG CMAKE_C_FLAGS_RELEASE
         CMAKE_C_FLAGS_MINSIZEREL CMAKE_C_FLAGS_RELWITHDEBINFO
         CMAKE_CXX_FLAGS CMAKE_CXX_FLAGS_DEBUG CMAKE_CXX_FLAGS_RELEASE
         CMAKE_CXX_FLAGS_MINSIZEREL CMAKE_CXX_FLAGS_RELWITHDEBINFO)
-      IF (${flag_var} MATCHES "/MD")
-        STRING (REGEX REPLACE "/MD" "/MT" ${flag_var} "${${flag_var}}")
-      ENDIF (${flag_var} MATCHES "/MD")
-    ENDFOREACH (flag_var)
-    FOREACH (flag_var
+      if (${flag_var} MATCHES "/MD")
+        string (REGEX REPLACE "/MD" "/MT" ${flag_var} "${${flag_var}}")
+      endif (${flag_var} MATCHES "/MD")
+    endforeach (flag_var)
+    foreach (flag_var
         CMAKE_Fortran_FLAGS CMAKE_Fortran_FLAGS_DEBUG CMAKE_Fortran_FLAGS_RELEASE
         CMAKE_Fortran_FLAGS_MINSIZEREL CMAKE_Fortran_FLAGS_RELWITHDEBINFO)
-      IF (${flag_var} MATCHES "/libs:dll")
-        STRING (REGEX REPLACE "/libs:dll" "/libs:static" ${flag_var} "${${flag_var}}")
-      ENDIF (${flag_var} MATCHES "/libs:dll")
-    ENDFOREACH (flag_var)
-    SET (WIN_COMPILE_FLAGS "")
-    SET (WIN_LINK_FLAGS "/NODEFAULTLIB:MSVCRT")
-  ENDIF (MSVC AND NOT BUILD_SHARED_LIBS)
+      if (${flag_var} MATCHES "/libs:dll")
+        string (REGEX REPLACE "/libs:dll" "/libs:static" ${flag_var} "${${flag_var}}")
+      endif (${flag_var} MATCHES "/libs:dll")
+    endforeach (flag_var)
+    set (WIN_COMPILE_FLAGS "")
+    set (WIN_LINK_FLAGS "/NODEFAULTLIB:MSVCRT")
+  endif (MSVC AND NOT BUILD_SHARED_LIBS)
 ENDMACRO (TARGET_STATIC_CRT_FLAGS)
 
 #-----------------------------------------------------------------------------
-OPTION (BUILD_STATIC_CRT_LIBS "Build With Static CRT Libraries" OFF)
-IF (BUILD_STATIC_CRT_LIBS)
+option (BUILD_STATIC_CRT_LIBS "Build With Static CRT Libraries" OFF)
+if (BUILD_STATIC_CRT_LIBS)
   TARGET_STATIC_CRT_FLAGS ()
-ENDIF (BUILD_STATIC_CRT_LIBS)
+endif (BUILD_STATIC_CRT_LIBS)
  
\ No newline at end of file
diff --git a/config/cmake/cacheinit.cmake b/config/cmake/cacheinit.cmake
index 5a64121..7ca1bd4 100644
--- a/config/cmake/cacheinit.cmake
+++ b/config/cmake/cacheinit.cmake
@@ -4,65 +4,65 @@
 # EXTERNAL cache entries
 ########################
 
-SET (BUILD_SHARED_LIBS ON CACHE BOOL "Build Shared Libraries" FORCE)
+set (BUILD_SHARED_LIBS ON CACHE BOOL "Build Shared Libraries" FORCE)
 
-SET (BUILD_TESTING ON CACHE BOOL "Build HDF4 Unit Testing" FORCE)
+set (BUILD_TESTING ON CACHE BOOL "Build HDF4 Unit Testing" FORCE)
 
-SET (HDF_PACKAGE_EXT "" CACHE STRING "Name of HDF package extension" FORCE)
+set (HDF_PACKAGE_EXT "" CACHE STRING "Name of HDF package extension" FORCE)
 
-SET (HDF4_BUILD_EXAMPLES ON CACHE BOOL "Build HDF4 Library Examples" FORCE)
+set (HDF4_BUILD_EXAMPLES ON CACHE BOOL "Build HDF4 Library Examples" FORCE)
 
-SET (HDF4_BUILD_FORTRAN ON CACHE BOOL "Build FORTRAN support" FORCE)
+set (HDF4_BUILD_FORTRAN ON CACHE BOOL "Build FORTRAN support" FORCE)
 
-SET (HDF4_BUILD_TOOLS ON CACHE BOOL "Build HDF4 Tools" FORCE)
+set (HDF4_BUILD_TOOLS ON CACHE BOOL "Build HDF4 Tools" FORCE)
 
-SET (HDF4_BUILD_UTILS ON CACHE BOOL "Build HDF4 Library Utilities" FORCE)
+set (HDF4_BUILD_UTILS ON CACHE BOOL "Build HDF4 Library Utilities" FORCE)
 
-SET (HDF4_BUILD_GENERATORS OFF CACHE BOOL "Build Test Generators" FORCE)
+set (HDF4_BUILD_GENERATORS OFF CACHE BOOL "Build Test Generators" FORCE)
 
-SET (HDF4_ENABLE_NETCDF ON CACHE BOOL "Build HDF4 versions of NetCDF-3 APIS" FORCE)
+set (HDF4_ENABLE_NETCDF ON CACHE BOOL "Build HDF4 versions of NetCDF-3 APIS" FORCE)
 
-SET (HDF4_BUILD_XDR_LIB OFF CACHE BOOL "Build HDF4 XDR Library" FORCE)
+set (HDF4_BUILD_XDR_LIB OFF CACHE BOOL "Build HDF4 XDR Library" FORCE)
 
-SET (HDF4_ENABLE_PARALLEL OFF CACHE BOOL "Enable parallel build (requires MPI)" FORCE)
+set (HDF4_ENABLE_PARALLEL OFF CACHE BOOL "Enable parallel build (requires MPI)" FORCE)
 
-SET (MPIEXEC_MAX_NUMPROCS "3" CACHE STRING "Minimum number of processes for HDF parallel tests" FORCE)
+set (MPIEXEC_MAX_NUMPROCS "3" CACHE STRING "Minimum number of processes for HDF parallel tests" FORCE)
 
-SET (HDF4_ENABLE_JPEG_LIB_SUPPORT ON CACHE BOOL "Enable Jpeg library" FORCE)
+set (HDF4_ENABLE_JPEG_LIB_SUPPORT ON CACHE BOOL "Enable Jpeg library" FORCE)
 
-SET (HDF4_ENABLE_Z_LIB_SUPPORT ON CACHE BOOL "Enable Zlib Filters" FORCE)
+set (HDF4_ENABLE_Z_LIB_SUPPORT ON CACHE BOOL "Enable Zlib Filters" FORCE)
 
-SET (HDF4_ENABLE_SZIP_SUPPORT ON CACHE BOOL "Use SZip Filter" FORCE)
+set (HDF4_ENABLE_SZIP_SUPPORT ON CACHE BOOL "Use SZip Filter" FORCE)
 
-SET (HDF4_ENABLE_SZIP_ENCODING ON CACHE BOOL "Use SZip Encoding" FORCE)
+set (HDF4_ENABLE_SZIP_ENCODING ON CACHE BOOL "Use SZip Encoding" FORCE)
 
-SET (HDF4_ENABLE_COVERAGE OFF CACHE BOOL "Enable code coverage for Libraries and Programs" FORCE)
+set (HDF4_ENABLE_COVERAGE OFF CACHE BOOL "Enable code coverage for Libraries and Programs" FORCE)
 
-SET (HDF4_DISABLE_COMPILER_WARNINGS OFF CACHE BOOL "Disable compiler warnings" FORCE)
+set (HDF4_DISABLE_COMPILER_WARNINGS OFF CACHE BOOL "Disable compiler warnings" FORCE)
 
-SET (HDF4_ENABLE_DEPRECATED_SYMBOLS ON CACHE BOOL "Enable deprecated public API symbols" FORCE)
+set (HDF4_ENABLE_DEPRECATED_SYMBOLS ON CACHE BOOL "Enable deprecated public API symbols" FORCE)
 
-SET (HDF4_PACKAGE_EXTLIBS OFF CACHE BOOL "(WINDOWS)CPACK - include external libraries" FORCE)
+set (HDF4_PACKAGE_EXTLIBS OFF CACHE BOOL "(WINDOWS)CPACK - include external libraries" FORCE)
 
-SET (HDF4_NO_PACKAGES OFF CACHE BOOL "CPACK - Disable packaging" FORCE)
+set (HDF4_NO_PACKAGES OFF CACHE BOOL "CPACK - Disable packaging" FORCE)
 
-SET (HDF4_ALLOW_EXTERNAL_SUPPORT "NO" CACHE STRING "Allow External Library Building" FORCE)
-SET_PROPERTY(CACHE HDF4_ALLOW_EXTERNAL_SUPPORT PROPERTY STRINGS NO SVN TGZ)
+set (HDF4_ALLOW_EXTERNAL_SUPPORT "NO" CACHE STRING "Allow External Library Building (NO SVN TGZ)" FORCE)
+set_property (CACHE HDF4_ALLOW_EXTERNAL_SUPPORT PROPERTY STRINGS NO SVN TGZ)
 
-SET (ZLIB_SVN_URL "http://svn.hdfgroup.uiuc.edu/zlib/trunk" CACHE STRING "Use ZLib from HDF repository" FORCE)
+set (ZLIB_SVN_URL "http://svn.hdfgroup.uiuc.edu/zlib/trunk" CACHE STRING "Use ZLib from HDF repository" FORCE)
 
-SET (SZIP_SVN_URL "http://svn.hdfgroup.uiuc.edu/szip/trunk" CACHE STRING "Use SZip from HDF repository" FORCE)
+set (SZIP_SVN_URL "http://svn.hdfgroup.uiuc.edu/szip/trunk" CACHE STRING "Use SZip from HDF repository" FORCE)
 
-SET (JPEG_SVN_URL "http://svn.hdfgroup.uiuc.edu/jpeg/branches/jpeg8b" CACHE STRING "Use JPEG from HDF repository" FORCE)
+set (JPEG_SVN_URL "http://svn.hdfgroup.uiuc.edu/jpeg/branches/jpeg8b" CACHE STRING "Use JPEG from HDF repository" FORCE)
 
-SET (ZLIB_TGZ_NAME "ZLib.tar.gz" CACHE STRING "Use ZLib from compressed file" FORCE)
+set (ZLIB_TGZ_NAME "ZLib.tar.gz" CACHE STRING "Use ZLib from compressed file" FORCE)
 
-SET (SZIP_TGZ_NAME "SZip.tar.gz" CACHE STRING "Use SZip from compressed file" FORCE)
+set (SZIP_TGZ_NAME "SZip.tar.gz" CACHE STRING "Use SZip from compressed file" FORCE)
 
-SET (JPEG_TGZ_NAME "JPEG8b.tar.gz" CACHE STRING "Use JPEG from compressed file" FORCE)
+set (JPEG_TGZ_NAME "JPEG8b.tar.gz" CACHE STRING "Use JPEG from compressed file" FORCE)
 
-SET (ZLIB_PACKAGE_NAME "zlib" CACHE STRING "Name of ZLIB package" FORCE)
+set (ZLIB_PACKAGE_NAME "zlib" CACHE STRING "Name of ZLIB package" FORCE)
 
-SET (SZIP_PACKAGE_NAME "szip" CACHE STRING "Name of SZIP package" FORCE)
+set (SZIP_PACKAGE_NAME "szip" CACHE STRING "Name of SZIP package" FORCE)
 
-SET (JPEG_PACKAGE_NAME "jpeg" CACHE STRING "Name of JPEG package" FORCE)
+set (JPEG_PACKAGE_NAME "jpeg" CACHE STRING "Name of JPEG package" FORCE)
diff --git a/config/cmake/h4config.h.in b/config/cmake/h4config.h.in
index 6a7681f..cb2caee 100644
--- a/config/cmake/h4config.h.in
+++ b/config/cmake/h4config.h.in
@@ -118,7 +118,7 @@
 #define H4_PACKAGE_URL "@HDF4_PACKAGE_URL@"
 
 /* Define to the version of this package. */
-#define H4_PACKAGE_VERSION "@HDF4_PACKAGE_VERSION@"
+#define H4_PACKAGE_VERSION "@HDF4_PACKAGE_VERSION_STRING@"
 
 /* The size of `int*', as computed by sizeof. */
 #cmakedefine H4_SIZEOF_INTP @H4_SIZEOF_INTP@
@@ -127,7 +127,7 @@
 #cmakedefine H4_STDC_HEADERS @H4_STDC_HEADERS@
 
 /* Version number of package */
-#define H4_VERSION "@HDF4_PACKAGE_VERSION@"
+#define H4_VERSION "@HDF4_PACKAGE_VERSION_STRING@"
 
 /* Define to 1 if your processor stores words with the most significant byte
    first (like Motorola and SPARC, unlike Intel and VAX). */
diff --git a/config/cmake/hdf.gif b/config/cmake/hdf.gif
deleted file mode 100644
index 656617b..0000000
Binary files a/config/cmake/hdf.gif and /dev/null differ
diff --git a/config/cmake/hdf4-config-version.cmake.in b/config/cmake/hdf4-config-version.cmake.in
index a13d728..3dc2aa9 100644
--- a/config/cmake/hdf4-config-version.cmake.in
+++ b/config/cmake/hdf4-config-version.cmake.in
@@ -2,26 +2,26 @@
 # HDF4 Version file for install directory
 #-----------------------------------------------------------------------------
 
-SET (PACKAGE_VERSION @HDF4_VERSION_STRING@)
+set (PACKAGE_VERSION @HDF4_VERSION_STRING@)
 
-IF ("${PACKAGE_FIND_VERSION_MAJOR}" EQUAL @H4_VERS_MAJOR@)
+if ("${PACKAGE_FIND_VERSION_MAJOR}" EQUAL @H4_VERS_MAJOR@)
 
   # exact match for version @H5_VERS_MAJOR at .@H4_VERS_MINOR@
-  IF ("${PACKAGE_FIND_VERSION_MINOR}" EQUAL @H4_VERS_MINOR@)
+  if ("${PACKAGE_FIND_VERSION_MINOR}" EQUAL @H4_VERS_MINOR@)
 
     # compatible with any version @H4_VERS_MAJOR at .@H4_VERS_MINOR at .x
-    SET (PACKAGE_VERSION_COMPATIBLE 1) 
+    set (PACKAGE_VERSION_COMPATIBLE 1) 
     
-    IF ("${PACKAGE_FIND_VERSION_PATCH}" EQUAL @H4_VERS_RELEASE@)
-      SET (PACKAGE_VERSION_EXACT 1)    
+    if ("${PACKAGE_FIND_VERSION_PATCH}" EQUAL @H4_VERS_RELEASE@)
+      set (PACKAGE_VERSION_EXACT 1)    
 
-      IF ("${PACKAGE_FIND_VERSION_TWEAK}" EQUAL @H4_VERS_SUBRELEASE@)
+      if ("${PACKAGE_FIND_VERSION_TWEAK}" EQUAL @H4_VERS_SUBRELEASE@)
         # not using this yet
-      ENDIF ("${PACKAGE_FIND_VERSION_TWEAK}" EQUAL @H4_VERS_SUBRELEASE@)
+      endif ("${PACKAGE_FIND_VERSION_TWEAK}" EQUAL @H4_VERS_SUBRELEASE@)
       
-    ENDIF ("${PACKAGE_FIND_VERSION_PATCH}" EQUAL @H4_VERS_RELEASE@)
+    endif ("${PACKAGE_FIND_VERSION_PATCH}" EQUAL @H4_VERS_RELEASE@)
     
-  ENDIF ("${PACKAGE_FIND_VERSION_MINOR}" EQUAL @H4_VERS_MINOR@)
-ENDIF ("${PACKAGE_FIND_VERSION_MAJOR}" EQUAL @H4_VERS_MAJOR@)
+  endif ("${PACKAGE_FIND_VERSION_MINOR}" EQUAL @H4_VERS_MINOR@)
+endif ("${PACKAGE_FIND_VERSION_MAJOR}" EQUAL @H4_VERS_MAJOR@)
 
 
diff --git a/config/cmake/hdf4-config.cmake.build.in b/config/cmake/hdf4-config.cmake.build.in
index 65df934..a039784 100644
--- a/config/cmake/hdf4-config.cmake.build.in
+++ b/config/cmake/hdf4-config.cmake.build.in
@@ -6,56 +6,56 @@ GET_FILENAME_COMPONENT (SELF_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
 #-----------------------------------------------------------------------------
 # User Options
 #-----------------------------------------------------------------------------
-SET (HDF4_ENABLE_PARALLEL @HDF4_ENABLE_PARALLEL@)
-SET (HDF4_BUILD_FORTRAN   @HDF4_BUILD_FORTRAN@)
-SET (HDF4_BUILD_XDR_LIB   @HDF4_BUILD_XDR_LIB@)
-SET (HDF4_BUILD_TOOLS     @HDF4_BUILD_TOOLS@)
-SET (HDF4_BUILD_UTILS     @HDF4_BUILD_UTILS@)
-SET (HDF4_ENABLE_JPEG_LIB_SUPPORT @HDF4_ENABLE_JPEG_LIB_SUPPORT@)
-SET (HDF4_ENABLE_Z_LIB_SUPPORT @HDF4_ENABLE_Z_LIB_SUPPORT@)
-SET (HDF4_ENABLE_SZIP_SUPPORT  @HDF4_ENABLE_SZIP_SUPPORT@)
-SET (HDF4_ENABLE_SZIP_ENCODING @HDF4_ENABLE_SZIP_ENCODING@)
-SET (HDF4_BUILD_SHARED_LIBS    @BUILD_SHARED_LIBS@)
+set (HDF4_ENABLE_PARALLEL @HDF4_ENABLE_PARALLEL@)
+set (HDF4_BUILD_FORTRAN   @HDF4_BUILD_FORTRAN@)
+set (HDF4_BUILD_XDR_LIB   @HDF4_BUILD_XDR_LIB@)
+set (HDF4_BUILD_TOOLS     @HDF4_BUILD_TOOLS@)
+set (HDF4_BUILD_UTILS     @HDF4_BUILD_UTILS@)
+set (HDF4_ENABLE_JPEG_LIB_SUPPORT @HDF4_ENABLE_JPEG_LIB_SUPPORT@)
+set (HDF4_ENABLE_Z_LIB_SUPPORT @HDF4_ENABLE_Z_LIB_SUPPORT@)
+set (HDF4_ENABLE_SZIP_SUPPORT  @HDF4_ENABLE_SZIP_SUPPORT@)
+set (HDF4_ENABLE_SZIP_ENCODING @HDF4_ENABLE_SZIP_ENCODING@)
+set (HDF4_BUILD_SHARED_LIBS    @BUILD_SHARED_LIBS@)
 
 #-----------------------------------------------------------------------------
 # Directories
 #-----------------------------------------------------------------------------
-SET (HDF4_INCLUDE_DIR "@HDF4_INCLUDES_BUILD_TIME@")
+set (HDF4_INCLUDE_DIR "@HDF4_INCLUDES_BUILD_TIME@")
 
-IF (HDF4_BUILD_FORTRAN)
-  SET (HDF4_INCLUDE_DIR_FORTRAN "@CMAKE_Fortran_MODULE_DIRECTORY@" )
-ENDIF (HDF4_BUILD_FORTRAN)
+if (HDF4_BUILD_FORTRAN)
+  set (HDF4_INCLUDE_DIR_FORTRAN "@CMAKE_Fortran_MODULE_DIRECTORY@" )
+endif (HDF4_BUILD_FORTRAN)
   
-IF (HDF4_BUILD_XDR_LIB)
-  SET (HDF4_INCLUDE_DIR_XDR ${HDF4_INCLUDE_DIR} )
-ENDIF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
+  set (HDF4_INCLUDE_DIR_XDR ${HDF4_INCLUDE_DIR} )
+endif (HDF4_BUILD_XDR_LIB)
 
-IF (HDF4_BUILD_TOOLS)
-  SET (HDF4_INCLUDE_DIR_TOOLS ${HDF4_INCLUDE_DIR} )
-ENDIF (HDF4_BUILD_TOOLS)
+if (HDF4_BUILD_TOOLS)
+  set (HDF4_INCLUDE_DIR_TOOLS ${HDF4_INCLUDE_DIR} )
+endif (HDF4_BUILD_TOOLS)
 
-IF (HDF4_BUILD_UTILS)
-  SET (HDF4_INCLUDE_DIR_UTILS ${HDF4_INCLUDE_DIR} )
-ENDIF (HDF4_BUILD_UTILS)
+if (HDF4_BUILD_UTILS)
+  set (HDF4_INCLUDE_DIR_UTILS ${HDF4_INCLUDE_DIR} )
+endif (HDF4_BUILD_UTILS)
 
-IF (HDF4_BUILD_SHARED_LIBS)
-  SET (H4_BUILT_AS_DYNAMIC_LIB 1 )
-ELSE (HDF4_BUILD_SHARED_LIBS)
-  SET (H4_BUILT_AS_STATIC_LIB 1 )
-ENDIF (HDF4_BUILD_SHARED_LIBS)
+if (HDF4_BUILD_SHARED_LIBS)
+  set (H4_BUILT_AS_DYNAMIC_LIB 1 )
+else (HDF4_BUILD_SHARED_LIBS)
+  set (H4_BUILT_AS_STATIC_LIB 1 )
+endif (HDF4_BUILD_SHARED_LIBS)
 
 #-----------------------------------------------------------------------------
 # Version Strings
 #-----------------------------------------------------------------------------
-SET (HDF4_VERSION_STRING @HDF4_VERSION_STRING@)
-SET (HDF4_VERSION_MAJOR  @HDF4_VERSION_MAJOR@)
-SET (HDF4_VERSION_MINOR  @HDF4_VERSION_MINOR@)
+set (HDF4_VERSION_STRING @HDF4_VERSION_STRING@)
+set (HDF4_VERSION_MAJOR  @HDF4_VERSION_MAJOR@)
+set (HDF4_VERSION_MINOR  @HDF4_VERSION_MINOR@)
 
 #-----------------------------------------------------------------------------
 # Don't include targets if this file is being picked up by another
 # project which has already build hdf4 as a subproject
 #-----------------------------------------------------------------------------
-IF (NOT TARGET "@HDF4_PACKAGE@")
-  INCLUDE (${SELF_DIR}/@HDF4_PACKAGE@@HDF_PACKAGE_EXT at -targets.cmake)
-  SET (HDF4_LIBRARIES "@HDF4_LIBRARIES_TO_EXPORT@")
-ENDIF (NOT TARGET "@HDF4_PACKAGE@")
+if (NOT TARGET "@HDF4_PACKAGE@")
+  include (${SELF_DIR}/@HDF4_PACKAGE@@HDF_PACKAGE_EXT at -targets.cmake)
+  set (HDF4_LIBRARIES "@HDF4_LIBRARIES_TO_EXPORT@")
+endif (NOT TARGET "@HDF4_PACKAGE@")
diff --git a/config/cmake/hdf4-config.cmake.install.in b/config/cmake/hdf4-config.cmake.install.in
index edc6926..15ce3ec 100644
--- a/config/cmake/hdf4-config.cmake.install.in
+++ b/config/cmake/hdf4-config.cmake.install.in
@@ -4,68 +4,68 @@
 GET_FILENAME_COMPONENT (SELF_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
 GET_FILENAME_COMPONENT(_IMPORT_PREFIX "${SELF_DIR}" PATH)
 GET_FILENAME_COMPONENT(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
-IF (NOT WIN32)
+if (NOT WIN32)
   GET_FILENAME_COMPONENT(_IMPORT_PREFIX "${_IMPORT_PREFIX}" PATH)
-ENDIF (NOT WIN32)
+endif (NOT WIN32)
 
 #-----------------------------------------------------------------------------
 # User Options
 #-----------------------------------------------------------------------------
-SET (HDF4_ENABLE_PARALLEL @HDF4_ENABLE_PARALLEL@)
-SET (HDF4_BUILD_FORTRAN   @HDF4_BUILD_FORTRAN@)
-SET (HDF4_BUILD_XDR_LIB   @HDF4_BUILD_XDR_LIB@)
-SET (HDF4_BUILD_TOOLS     @HDF4_BUILD_TOOLS@)
-SET (HDF4_BUILD_UTILS     @HDF4_BUILD_UTILS@)
-SET (HDF4_ENABLE_JPEG_LIB_SUPPORT @HDF4_ENABLE_JPEG_LIB_SUPPORT@)
-SET (HDF4_ENABLE_Z_LIB_SUPPORT @HDF4_ENABLE_Z_LIB_SUPPORT@)
-SET (HDF4_ENABLE_SZIP_SUPPORT  @HDF4_ENABLE_SZIP_SUPPORT@)
-SET (HDF4_ENABLE_SZIP_ENCODING @HDF4_ENABLE_SZIP_ENCODING@)
-SET (HDF4_BUILD_SHARED_LIBS    @BUILD_SHARED_LIBS@)
-SET (HDF4_PACKAGE_EXTLIBS @HDF4_PACKAGE_EXTLIBS@)
+set (HDF4_ENABLE_PARALLEL @HDF4_ENABLE_PARALLEL@)
+set (HDF4_BUILD_FORTRAN   @HDF4_BUILD_FORTRAN@)
+set (HDF4_BUILD_XDR_LIB   @HDF4_BUILD_XDR_LIB@)
+set (HDF4_BUILD_TOOLS     @HDF4_BUILD_TOOLS@)
+set (HDF4_BUILD_UTILS     @HDF4_BUILD_UTILS@)
+set (HDF4_ENABLE_JPEG_LIB_SUPPORT @HDF4_ENABLE_JPEG_LIB_SUPPORT@)
+set (HDF4_ENABLE_Z_LIB_SUPPORT @HDF4_ENABLE_Z_LIB_SUPPORT@)
+set (HDF4_ENABLE_SZIP_SUPPORT  @HDF4_ENABLE_SZIP_SUPPORT@)
+set (HDF4_ENABLE_SZIP_ENCODING @HDF4_ENABLE_SZIP_ENCODING@)
+set (HDF4_BUILD_SHARED_LIBS    @BUILD_SHARED_LIBS@)
+set (HDF4_PACKAGE_EXTLIBS @HDF4_PACKAGE_EXTLIBS@)
 
 #-----------------------------------------------------------------------------
 # Directories
 #-----------------------------------------------------------------------------
-SET (HDF4_INCLUDE_DIR "${_IMPORT_PREFIX}/include")
+set (HDF4_INCLUDE_DIR "${_IMPORT_PREFIX}/include")
 
-IF (HDF4_BUILD_FORTRAN)
-  SET (HDF4_INCLUDE_DIR_FORTRAN "${_IMPORT_PREFIX}/include")
-ENDIF (HDF4_BUILD_FORTRAN)
+if (HDF4_BUILD_FORTRAN)
+  set (HDF4_INCLUDE_DIR_FORTRAN "${_IMPORT_PREFIX}/include")
+endif (HDF4_BUILD_FORTRAN)
   
-IF (HDF4_BUILD_XDR_LIB)
-  SET (HDF4_INCLUDE_DIR_XDR "${_IMPORT_PREFIX}/include")
-ENDIF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
+  set (HDF4_INCLUDE_DIR_XDR "${_IMPORT_PREFIX}/include")
+endif (HDF4_BUILD_XDR_LIB)
 
-IF (HDF4_BUILD_TOOLS)
-  SET (HDF4_INCLUDE_DIR_TOOLS "${_IMPORT_PREFIX}/include")
-ENDIF (HDF4_BUILD_TOOLS)
+if (HDF4_BUILD_TOOLS)
+  set (HDF4_INCLUDE_DIR_TOOLS "${_IMPORT_PREFIX}/include")
+endif (HDF4_BUILD_TOOLS)
 
-IF (HDF4_BUILD_UTILS)
-  SET (HDF4_INCLUDE_DIR_UTILS "${_IMPORT_PREFIX}/include")
-  SET (HDF4_TOOLS_DIR "${_IMPORT_PREFIX}/bin" )
-ENDIF (HDF4_BUILD_UTILS)
+if (HDF4_BUILD_UTILS)
+  set (HDF4_INCLUDE_DIR_UTILS "${_IMPORT_PREFIX}/include")
+  set (HDF4_TOOLS_DIR "${_IMPORT_PREFIX}/bin" )
+endif (HDF4_BUILD_UTILS)
 
 #-----------------------------------------------------------------------------
 # Version Strings
 #-----------------------------------------------------------------------------
-SET (HDF4_VERSION_STRING @HDF4_VERSION_STRING@)
-SET (HDF4_VERSION_MAJOR  @HDF4_VERSION_MAJOR@)
-SET (HDF4_VERSION_MINOR  @HDF4_VERSION_MINOR@)
+set (HDF4_VERSION_STRING @HDF4_VERSION_STRING@)
+set (HDF4_VERSION_MAJOR  @HDF4_VERSION_MAJOR@)
+set (HDF4_VERSION_MINOR  @HDF4_VERSION_MINOR@)
 
 #-----------------------------------------------------------------------------
 # Don't include targets if this file is being picked up by another
 # project which has already built hdf4 as a subproject
 #-----------------------------------------------------------------------------
-IF (NOT TARGET "@HDF4_PACKAGE@")
-  IF (HDF4_ENABLE_JPEG_LIB_SUPPORT AND HDF4_PACKAGE_EXTLIBS AND NOT TARGET "jpeg")
-    INCLUDE (${SELF_DIR}/../JPEG/@JPEG_PACKAGE_NAME@@HDF_PACKAGE_EXT at -targets.cmake)
-  ENDIF (HDF4_ENABLE_JPEG_LIB_SUPPORT AND HDF4_PACKAGE_EXTLIBS AND NOT TARGET "jpeg")
-  IF (HDF4_ENABLE_Z_LIB_SUPPORT AND HDF4_PACKAGE_EXTLIBS AND NOT TARGET "zlib")
-    INCLUDE (${SELF_DIR}/../ZLIB/@ZLIB_PACKAGE_NAME@@HDF_PACKAGE_EXT at -targets.cmake)
-  ENDIF (HDF4_ENABLE_Z_LIB_SUPPORT AND HDF4_PACKAGE_EXTLIBS AND NOT TARGET "zlib")
-  IF (HDF4_ENABLE_SZIP_SUPPORT AND HDF4_PACKAGE_EXTLIBS AND NOT TARGET "szip")
-    INCLUDE (${SELF_DIR}/../SZIP/@SZIP_PACKAGE_NAME@@HDF_PACKAGE_EXT at -targets.cmake)
-  ENDIF (HDF4_ENABLE_SZIP_SUPPORT AND HDF4_PACKAGE_EXTLIBS AND NOT TARGET "szip")
-  INCLUDE (${SELF_DIR}/@HDF4_PACKAGE@@HDF_PACKAGE_EXT at -targets.cmake)
-  SET (HDF4_LIBRARIES "@HDF4_LIBRARIES_TO_EXPORT@")
-ENDIF (NOT TARGET "@HDF4_PACKAGE@")
+if (NOT TARGET "@HDF4_PACKAGE@")
+  if (HDF4_ENABLE_JPEG_LIB_SUPPORT AND HDF4_PACKAGE_EXTLIBS AND NOT TARGET "jpeg")
+    include (${SELF_DIR}/../JPEG/@JPEG_PACKAGE_NAME@@HDF_PACKAGE_EXT at -targets.cmake)
+  endif (HDF4_ENABLE_JPEG_LIB_SUPPORT AND HDF4_PACKAGE_EXTLIBS AND NOT TARGET "jpeg")
+  if (HDF4_ENABLE_Z_LIB_SUPPORT AND HDF4_PACKAGE_EXTLIBS AND NOT TARGET "zlib")
+    include (${SELF_DIR}/../ZLIB/@ZLIB_PACKAGE_NAME@@HDF_PACKAGE_EXT at -targets.cmake)
+  endif (HDF4_ENABLE_Z_LIB_SUPPORT AND HDF4_PACKAGE_EXTLIBS AND NOT TARGET "zlib")
+  if (HDF4_ENABLE_SZIP_SUPPORT AND HDF4_PACKAGE_EXTLIBS AND NOT TARGET "szip")
+    include (${SELF_DIR}/../SZIP/@SZIP_PACKAGE_NAME@@HDF_PACKAGE_EXT at -targets.cmake)
+  endif (HDF4_ENABLE_SZIP_SUPPORT AND HDF4_PACKAGE_EXTLIBS AND NOT TARGET "szip")
+  include (${SELF_DIR}/@HDF4_PACKAGE@@HDF_PACKAGE_EXT at -targets.cmake)
+  set (HDF4_LIBRARIES "@HDF4_LIBRARIES_TO_EXPORT@")
+endif (NOT TARGET "@HDF4_PACKAGE@")
diff --git a/config/cmake/libhdf4.settings.cmake.in b/config/cmake/libhdf4.settings.cmake.in
index d38751b..733a2e7 100644
--- a/config/cmake/libhdf4.settings.cmake.in
+++ b/config/cmake/libhdf4.settings.cmake.in
@@ -3,7 +3,7 @@
 
 General Information:
 -------------------
-                   HDF4 Version: @HDF4_PACKAGE_VERSION@
+                   HDF4 Version: @HDF4_PACKAGE_VERSION_STRING@
                   Configured on: @CONFIG_DATE@
                   Configured by: @CMAKE_GENERATOR@
                  Configure mode: CMAKE @CMAKE_VERSION@
diff --git a/config/cmake/mccacheinit.cmake b/config/cmake/mccacheinit.cmake
index 03ff484..04b2c4c 100644
--- a/config/cmake/mccacheinit.cmake
+++ b/config/cmake/mccacheinit.cmake
@@ -4,68 +4,69 @@
 # EXTERNAL cache entries
 ########################
 
-SET (BUILD_SHARED_LIBS OFF CACHE BOOL "Build Shared Libraries" FORCE)
+set (BUILD_SHARED_LIBS OFF CACHE BOOL "Build Shared Libraries" FORCE)
 
-SET (BUILD_TESTING ON CACHE BOOL "Build HDF4 Unit Testing" FORCE)
+set (BUILD_TESTING ON CACHE BOOL "Build HDF4 Unit Testing" FORCE)
 
-SET (HDF_PACKAGE_EXT "" CACHE STRING "Name of HDF package extension" FORCE)
+set (HDF_PACKAGE_EXT "" CACHE STRING "Name of HDF package extension" FORCE)
 
-SET (HDF4_BUILD_EXAMPLES ON CACHE BOOL "Build HDF4 Library Examples" FORCE)
+set (HDF4_BUILD_EXAMPLES ON CACHE BOOL "Build HDF4 Library Examples" FORCE)
 
-SET (HDF4_BUILD_FORTRAN ON CACHE BOOL "Build FORTRAN support" FORCE)
+set (HDF4_BUILD_FORTRAN ON CACHE BOOL "Build FORTRAN support" FORCE)
 
-SET (HDF4_BUILD_TOOLS ON CACHE BOOL "Build HDF4 Tools" FORCE)
+set (HDF4_BUILD_TOOLS ON CACHE BOOL "Build HDF4 Tools" FORCE)
 
-SET (HDF4_BUILD_UTILS ON CACHE BOOL "Build HDF4 Library Utilities" FORCE)
+set (HDF4_BUILD_UTILS ON CACHE BOOL "Build HDF4 Library Utilities" FORCE)
 
-SET (HDF4_BUILD_GENERATORS OFF CACHE BOOL "Build Test Generators" FORCE)
+set (HDF4_BUILD_GENERATORS OFF CACHE BOOL "Build Test Generators" FORCE)
 
-SET (HDF4_ENABLE_NETCDF ON CACHE BOOL "Build HDF4 versions of NetCDF-3 APIS" FORCE)
+set (HDF4_ENABLE_NETCDF ON CACHE BOOL "Build HDF4 versions of NetCDF-3 APIS" FORCE)
 
-SET (HDF4_BUILD_XDR_LIB OFF CACHE BOOL "Build HDF4 XDR Library" FORCE)
+set (HDF4_BUILD_XDR_LIB OFF CACHE BOOL "Build HDF4 XDR Library" FORCE)
 
-SET (HDF4_ENABLE_PARALLEL OFF CACHE BOOL "Enable parallel build (requires MPI)" FORCE)
+set (HDF4_ENABLE_PARALLEL OFF CACHE BOOL "Enable parallel build (requires MPI)" FORCE)
 
-SET (MPIEXEC_MAX_NUMPROCS "3" CACHE STRING "Minimum number of processes for HDF parallel tests" FORCE)
+set (MPIEXEC_MAX_NUMPROCS "3" CACHE STRING "Minimum number of processes for HDF parallel tests" FORCE)
 
-SET (HDF4_ENABLE_JPEG_LIB_SUPPORT ON CACHE BOOL "Enable Jpeg library" FORCE)
+set (HDF4_ENABLE_JPEG_LIB_SUPPORT ON CACHE BOOL "Enable Jpeg library" FORCE)
 
-SET (HDF4_ENABLE_Z_LIB_SUPPORT ON CACHE BOOL "Enable Zlib Filters" FORCE)
+set (HDF4_ENABLE_Z_LIB_SUPPORT ON CACHE BOOL "Enable Zlib Filters" FORCE)
 
-SET (HDF4_ENABLE_SZIP_SUPPORT ON CACHE BOOL "Use SZip Filter" FORCE)
+set (HDF4_ENABLE_SZIP_SUPPORT ON CACHE BOOL "Use SZip Filter" FORCE)
 
-SET (HDF4_ENABLE_SZIP_ENCODING ON CACHE BOOL "Use SZip Encoding" FORCE)
+set (HDF4_ENABLE_SZIP_ENCODING ON CACHE BOOL "Use SZip Encoding" FORCE)
 
-SET (HDF4_ENABLE_COVERAGE OFF CACHE BOOL "Enable code coverage for Libraries and Programs" FORCE)
+set (HDF4_ENABLE_COVERAGE OFF CACHE BOOL "Enable code coverage for Libraries and Programs" FORCE)
 
-SET (HDF4_ENABLE_USING_MEMCHECKER ON CACHE BOOL "Indicate that a memory checker is used" FORCE)
+set (HDF4_ENABLE_USING_MEMCHECKER ON CACHE BOOL "Indicate that a memory checker is used" FORCE)
 
-SET (HDF4_DISABLE_COMPILER_WARNINGS OFF CACHE BOOL "Disable compiler warnings" FORCE)
+set (HDF4_DISABLE_COMPILER_WARNINGS OFF CACHE BOOL "Disable compiler warnings" FORCE)
 
-SET (HDF4_ENABLE_DEPRECATED_SYMBOLS ON CACHE BOOL "Enable deprecated public API symbols" FORCE)
+set (HDF4_ENABLE_DEPRECATED_SYMBOLS ON CACHE BOOL "Enable deprecated public API symbols" FORCE)
 
-SET (HDF4_PACKAGE_EXTLIBS OFF CACHE BOOL "(WINDOWS)CPACK - include external libraries" FORCE)
+set (HDF4_PACKAGE_EXTLIBS OFF CACHE BOOL "(WINDOWS)CPACK - include external libraries" FORCE)
 
-SET (HDF4_NO_PACKAGES ON CACHE BOOL "CPACK - Disable packaging" FORCE)
+set (HDF4_NO_PACKAGES ON CACHE BOOL "CPACK - Disable packaging" FORCE)
 
-SET (HDF4_ALLOW_EXTERNAL_SUPPORT "NO" CACHE STRING "Allow External Library Building" FORCE)
+set (HDF4_ALLOW_EXTERNAL_SUPPORT "NO" CACHE STRING "Allow External Library Building (NO SVN TGZ)" FORCE)
+set_property (CACHE HDF4_ALLOW_EXTERNAL_SUPPORT PROPERTY STRINGS NO SVN TGZ)
 
-SET (ZLIB_SVN_URL "http://svn.hdfgroup.uiuc.edu/zlib/trunk" CACHE STRING "Use ZLib from HDF repository" FORCE)
+set (ZLIB_SVN_URL "http://svn.hdfgroup.uiuc.edu/zlib/trunk" CACHE STRING "Use ZLib from HDF repository" FORCE)
 
-SET (SZIP_SVN_URL "http://svn.hdfgroup.uiuc.edu/szip/trunk" CACHE STRING "Use SZip from HDF repository" FORCE)
+set (SZIP_SVN_URL "http://svn.hdfgroup.uiuc.edu/szip/trunk" CACHE STRING "Use SZip from HDF repository" FORCE)
 
-SET (JPEG_SVN_URL "http://svn.hdfgroup.uiuc.edu/jpeg/branches/jpeg8b" CACHE STRING "Use JPEG from HDF repository" FORCE)
+set (JPEG_SVN_URL "http://svn.hdfgroup.uiuc.edu/jpeg/branches/jpeg8b" CACHE STRING "Use JPEG from HDF repository" FORCE)
 
-SET (ZLIB_TGZ_NAME "ZLib.tar.gz" CACHE STRING "Use ZLib from compressed file" FORCE)
+set (ZLIB_TGZ_NAME "ZLib.tar.gz" CACHE STRING "Use ZLib from compressed file" FORCE)
 
-SET (SZIP_TGZ_NAME "SZip.tar.gz" CACHE STRING "Use SZip from compressed file" FORCE)
+set (SZIP_TGZ_NAME "SZip.tar.gz" CACHE STRING "Use SZip from compressed file" FORCE)
 
-SET (JPEG_TGZ_NAME "JPEG8b.tar.gz" CACHE STRING "Use JPEG from compressed file" FORCE)
+set (JPEG_TGZ_NAME "JPEG8b.tar.gz" CACHE STRING "Use JPEG from compressed file" FORCE)
 
-SET (CMAKE_BUILD_TYPE "Debug" CACHE STRING "Build Debug" FORCE)
+set (CMAKE_BUILD_TYPE "Debug" CACHE STRING "Build Debug" FORCE)
 
-SET (ZLIB_PACKAGE_NAME "zlib" CACHE STRING "Name of ZLIB package" FORCE)
+set (ZLIB_PACKAGE_NAME "zlib" CACHE STRING "Name of ZLIB package" FORCE)
 
-SET (SZIP_PACKAGE_NAME "szip" CACHE STRING "Name of SZIP package" FORCE)
+set (SZIP_PACKAGE_NAME "szip" CACHE STRING "Name of SZIP package" FORCE)
 
-SET (JPEG_PACKAGE_NAME "jpeg" CACHE STRING "Name of JPEG package" FORCE)
+set (JPEG_PACKAGE_NAME "jpeg" CACHE STRING "Name of JPEG package" FORCE)
diff --git a/config/cmake/runTest.cmake b/config/cmake/runTest.cmake
deleted file mode 100644
index 53b3ee7..0000000
--- a/config/cmake/runTest.cmake
+++ /dev/null
@@ -1,182 +0,0 @@
-# runTest.cmake executes a command and captures the output in a file. File is then compared
-# against a reference file. Exit status of command can also be compared.
-cmake_policy(SET CMP0007 NEW)
-
-# arguments checking
-IF (NOT TEST_PROGRAM)
-  MESSAGE (FATAL_ERROR "Require TEST_PROGRAM to be defined")
-ENDIF (NOT TEST_PROGRAM)
-#IF (NOT TEST_ARGS)
-#  MESSAGE (STATUS "Require TEST_ARGS to be defined")
-#ENDIF (NOT TEST_ARGS)
-IF (NOT TEST_FOLDER)
-  MESSAGE ( FATAL_ERROR "Require TEST_FOLDER to be defined")
-ENDIF (NOT TEST_FOLDER)
-IF (NOT TEST_OUTPUT)
-  MESSAGE (FATAL_ERROR "Require TEST_OUTPUT to be defined")
-ENDIF (NOT TEST_OUTPUT)
-#IF (NOT TEST_EXPECT)
-#  MESSAGE (STATUS "Require TEST_EXPECT to be defined")
-#ENDIF (NOT TEST_EXPECT)
-#IF (NOT TEST_FILTER)
-#  MESSAGE (STATUS "Require TEST_FILTER to be defined")
-#ENDIF (NOT TEST_FILTER)
-IF (NOT TEST_SKIP_COMPARE AND NOT TEST_REFERENCE)
-  MESSAGE (FATAL_ERROR "Require TEST_REFERENCE to be defined")
-ENDIF (NOT TEST_SKIP_COMPARE AND NOT TEST_REFERENCE)
-
-IF (NOT TEST_ERRREF)
-  SET (ERROR_APPEND 1)
-ENDIF (NOT TEST_ERRREF)
-
-MESSAGE (STATUS "COMMAND: ${TEST_PROGRAM} ${TEST_ARGS}")
-
-IF (TEST_ENV_VAR)
-  SET (ENV{${TEST_ENV_VAR}} "${TEST_ENV_VALUE}") 
-ENDIF (TEST_ENV_VAR)
-
-IF (NOT TEST_INPUT)
-  # run the test program, capture the stdout/stderr and the result var
-  EXECUTE_PROCESS (
-      COMMAND ${TEST_PROGRAM} ${TEST_ARGS}
-      WORKING_DIRECTORY ${TEST_FOLDER}
-      RESULT_VARIABLE TEST_RESULT
-      OUTPUT_FILE ${TEST_OUTPUT}
-      ERROR_FILE ${TEST_OUTPUT}.err
-      OUTPUT_VARIABLE TEST_ERROR
-      ERROR_VARIABLE TEST_ERROR
-  )
-ELSE (NOT TEST_INPUT)
-  # run the test program with stdin, capture the stdout/stderr and the result var
-  EXECUTE_PROCESS (
-      COMMAND ${TEST_PROGRAM} ${TEST_ARGS}
-      WORKING_DIRECTORY ${TEST_FOLDER}
-      RESULT_VARIABLE TEST_RESULT
-      INPUT_FILE ${TEST_INPUT}
-      OUTPUT_FILE ${TEST_OUTPUT}
-      ERROR_FILE ${TEST_OUTPUT}.err
-      OUTPUT_VARIABLE TEST_ERROR
-      ERROR_VARIABLE TEST_ERROR
-  )
-ENDIF (NOT TEST_INPUT)
-
-MESSAGE (STATUS "COMMAND Result: ${TEST_RESULT}")
-
-IF (ERROR_APPEND)
-  FILE (READ ${TEST_FOLDER}/${TEST_OUTPUT}.err TEST_STREAM)
-  FILE (APPEND ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}") 
-ENDIF (ERROR_APPEND)
-
-IF (TEST_APPEND)
-  FILE (APPEND ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_APPEND} ${TEST_RESULT}\n") 
-ENDIF (TEST_APPEND)
-
-# if the return value is !=${TEST_EXPECT} bail out
-IF (NOT ${TEST_RESULT} STREQUAL ${TEST_EXPECT})
-  MESSAGE ( FATAL_ERROR "Failed: Test program ${TEST_PROGRAM} exited != ${TEST_EXPECT}.\n${TEST_ERROR}")
-ENDIF (NOT ${TEST_RESULT} STREQUAL ${TEST_EXPECT})
-
-MESSAGE (STATUS "COMMAND Error: ${TEST_ERROR}")
-
-IF (TEST_MASK)
-  FILE (READ ${TEST_FOLDER}/${TEST_OUTPUT} TEST_STREAM)
-  #STRING(REGEX REPLACE "Modified:[^\n]+\n" "Modified:  XXXX-XX-XX XX:XX:XX XXX\n" TEST_STREAM "${TEST_STREAM}") 
-  STRING(REGEX REPLACE "Storage:[^\n]+\n" "Storage:   <details removed for portability>\n" TEST_STREAM "${TEST_STREAM}") 
-  FILE (WRITE ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}")
-ENDIF (TEST_MASK)
-
-IF (TEST_FILTER)
-  FILE (READ ${TEST_FOLDER}/${TEST_OUTPUT} TEST_STREAM)
-  STRING(REGEX REPLACE "${TEST_FILTER}" "" TEST_STREAM "${TEST_STREAM}") 
-  FILE (WRITE ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}")
-ENDIF (TEST_FILTER)
-
-IF (NOT TEST_SKIP_COMPARE)
-  IF (WIN32 AND NOT MINGW)
-    FILE (READ ${TEST_FOLDER}/${TEST_REFERENCE} TEST_STREAM)
-    FILE (WRITE ${TEST_FOLDER}/${TEST_REFERENCE} "${TEST_STREAM}")
-  ENDIF (WIN32 AND NOT MINGW)
-
-  # now compare the output with the reference
-  EXECUTE_PROCESS (
-      COMMAND ${CMAKE_COMMAND} -E compare_files ${TEST_FOLDER}/${TEST_OUTPUT} ${TEST_FOLDER}/${TEST_REFERENCE}
-      RESULT_VARIABLE TEST_RESULT
-  )
-  IF (NOT ${TEST_RESULT} STREQUAL 0)
-  SET (TEST_RESULT 0)
-  FILE (STRINGS ${TEST_FOLDER}/${TEST_OUTPUT} test_act)
-  LIST (LENGTH test_act len_act)
-  FILE (STRINGS ${TEST_FOLDER}/${TEST_REFERENCE} test_ref)
-  LIST (LENGTH test_ref len_ref)
-  IF (NOT ${len_act} STREQUAL "0")
-    MATH (EXPR _FP_LEN "${len_ref} - 1")
-    FOREACH (line RANGE 0 ${_FP_LEN})
-      LIST (GET test_act ${line} str_act)
-      LIST (GET test_ref ${line} str_ref)
-      IF (NOT "${str_act}" STREQUAL "${str_ref}")
-        IF (NOT "${str_act}" STREQUAL "")
-          SET (TEST_RESULT 1)
-          MESSAGE ("line = ${line}\n***ACTUAL: ${str_act}\n****REFER: ${str_ref}\n")
-         ENDIF (NOT "${str_act}" STREQUAL "")
-      ENDIF (NOT "${str_act}" STREQUAL "${str_ref}")
-    ENDFOREACH (line RANGE 0 ${_FP_LEN})
-  ENDIF (NOT ${len_act} STREQUAL "0")
-  IF (NOT ${len_act} STREQUAL ${len_ref})
-    SET (TEST_RESULT 1)
-  ENDIF (NOT ${len_act} STREQUAL ${len_ref})
-  ENDIF (NOT ${TEST_RESULT} STREQUAL 0)
-
-  MESSAGE (STATUS "COMPARE Result: ${TEST_RESULT}")
-
-  # again, if return value is !=0 scream and shout
-  IF (NOT ${TEST_RESULT} STREQUAL 0)
-    MESSAGE (FATAL_ERROR "Failed: The output of ${TEST_OUTPUT} did not match ${TEST_REFERENCE}")
-  ENDIF (NOT ${TEST_RESULT} STREQUAL 0)
-  
-  IF (TEST_ERRREF)
-    IF (WIN32 AND NOT MINGW)
-      FILE (READ ${TEST_FOLDER}/${TEST_ERRREF} TEST_STREAM)
-      FILE (WRITE ${TEST_FOLDER}/${TEST_ERRREF} "${TEST_STREAM}")
-    ENDIF (WIN32 AND NOT MINGW)
-
-    # now compare the error output with the error reference
-    EXECUTE_PROCESS (
-        COMMAND ${CMAKE_COMMAND} -E compare_files ${TEST_FOLDER}/${TEST_OUTPUT}.err ${TEST_FOLDER}/${TEST_ERRREF}
-        RESULT_VARIABLE TEST_RESULT
-    )
-    IF (NOT ${TEST_RESULT} STREQUAL 0)
-    SET (TEST_RESULT 0)
-    FILE (STRINGS ${TEST_FOLDER}/${TEST_OUTPUT}.err test_act)
-    LIST (LENGTH test_act len_act)
-    FILE (STRINGS ${TEST_FOLDER}/${TEST_ERRREF} test_ref)
-    LIST (LENGTH test_ref len_ref)
-    MATH (EXPR _FP_LEN "${len_ref} - 1")
-    IF (NOT ${len_act} STREQUAL "0")
-      MATH (EXPR _FP_LEN "${len_ref} - 1")
-      FOREACH (line RANGE 0 ${_FP_LEN})
-        LIST (GET test_act ${line} str_act)
-        LIST (GET test_ref ${line} str_ref)
-        IF (NOT "${str_act}" STREQUAL "${str_ref}")
-          IF (NOT "${str_act}" STREQUAL "")
-            SET (TEST_RESULT 1)
-            MESSAGE ("line = ${line}\n***ACTUAL: ${str_act}\n****REFER: ${str_ref}\n")
-           ENDIF (NOT "${str_act}" STREQUAL "")
-        ENDIF (NOT "${str_act}" STREQUAL "${str_ref}")
-      ENDFOREACH (line RANGE 0 ${_FP_LEN})
-    ENDIF (NOT ${len_act} STREQUAL "0")
-    IF (NOT ${len_act} STREQUAL ${len_ref})
-      SET (TEST_RESULT 1)
-    ENDIF (NOT ${len_act} STREQUAL ${len_ref})
-    ENDIF (NOT ${TEST_RESULT} STREQUAL 0)
-
-    MESSAGE (STATUS "COMPARE Result: ${TEST_RESULT}")
-
-    # again, if return value is !=0 scream and shout
-    IF (NOT ${TEST_RESULT} STREQUAL 0)
-      MESSAGE (FATAL_ERROR "Failed: The error output of ${TEST_OUTPUT}.err did not match ${TEST_ERRREF}")
-    ENDIF (NOT ${TEST_RESULT} STREQUAL 0)
-  ENDIF (TEST_ERRREF)
-ENDIF (NOT TEST_SKIP_COMPARE)
-
-# everything went fine...
-MESSAGE ("Passed: The output of ${TEST_PROGRAM} matches ${TEST_REFERENCE}")
diff --git a/config/cmake/CPack.Info.plist.in b/config/cmake_ext_mod/CPack.Info.plist.in
similarity index 100%
rename from config/cmake/CPack.Info.plist.in
rename to config/cmake_ext_mod/CPack.Info.plist.in
diff --git a/config/cmake_ext_mod/CTestCustom.cmake b/config/cmake_ext_mod/CTestCustom.cmake
new file mode 100644
index 0000000..025bce4
--- /dev/null
+++ b/config/cmake_ext_mod/CTestCustom.cmake
@@ -0,0 +1,16 @@
+set (CTEST_CUSTOM_MAXIMUM_NUMBER_OF_WARNINGS 3000)
+ 
+set (CTEST_CUSTOM_WARNING_EXCEPTION
+    ${CTEST_CUSTOM_WARNING_EXCEPTION}
+    "note.*expected.*void.*but argument is of type.*volatile"
+    "SZIP.src.*:[ \t]*warning"
+    "jpeg.src.*:[ \t]*warning"
+    "POSIX name for this item is deprecated"
+    "disabling jobserver mode"
+    "warning.*implicit declaration of function"
+    "note: expanded from macro"
+)
+ 
+set (CTEST_CUSTOM_MEMCHECK_IGNORE
+    ${CTEST_CUSTOM_MEMCHECK_IGNORE}
+)
diff --git a/config/cmake_ext_mod/CheckTypeSize.cmake b/config/cmake_ext_mod/CheckTypeSize.cmake
new file mode 100644
index 0000000..5095a27
--- /dev/null
+++ b/config/cmake_ext_mod/CheckTypeSize.cmake
@@ -0,0 +1,50 @@
+#
+# Check if the type exists and determine size of type.  if the type
+# exists, the size will be stored to the variable.
+#
+# CHECK_TYPE_SIZE - macro which checks the size of type
+# VARIABLE - variable to store size if the type exists.
+# HAVE_${VARIABLE} - does the variable exists or not
+#
+
+MACRO (HDF_CHECK_TYPE_SIZE TYPE VARIABLE)
+  set (CMAKE_ALLOW_UNKNOWN_VARIABLE_READ_ACCESS 1)
+  if ("HAVE_${VARIABLE}" MATCHES "^HAVE_${VARIABLE}$")
+    set (MACRO_CHECK_TYPE_SIZE_FLAGS 
+        "-DCHECK_TYPE_SIZE_TYPE=\"${TYPE}\" ${CMAKE_REQUIRED_FLAGS}"
+    )
+    foreach (def HAVE_SYS_TYPES_H HAVE_STDINT_H HAVE_STDDEF_H HAVE_INTTYPES_H)
+      if ("${def}")
+        set (MACRO_CHECK_TYPE_SIZE_FLAGS "${MACRO_CHECK_TYPE_SIZE_FLAGS} -D${def}")
+      endif ("${def}")
+    endforeach (def)
+
+    message (STATUS "Check size of ${TYPE}")
+    if (CMAKE_REQUIRED_LIBRARIES)
+      set (CHECK_TYPE_SIZE_ADD_LIBRARIES 
+          "-DLINK_LIBRARIES:STRING=${CMAKE_REQUIRED_LIBRARIES}"
+      )
+    endif (CMAKE_REQUIRED_LIBRARIES)
+    try_run (${VARIABLE} HAVE_${VARIABLE}
+        ${CMAKE_BINARY_DIR}
+        ${HDF_RESOURCES_EXT_DIR}/CheckTypeSize.c
+        CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${MACRO_CHECK_TYPE_SIZE_FLAGS}
+        "${CHECK_TYPE_SIZE_ADD_LIBRARIES}"
+        OUTPUT_VARIABLE OUTPUT
+    )
+    if (HAVE_${VARIABLE})
+      message (STATUS "Check size of ${TYPE} - done")
+      file (APPEND
+          ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeOutput.log 
+          "Determining size of ${TYPE} passed with the following output:\n${OUTPUT}\n\n"
+      )
+    else (HAVE_${VARIABLE})
+      message (STATUS "Check size of ${TYPE} - failed")
+      file (APPEND
+          ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log 
+          "Determining size of ${TYPE} failed with the following output:\n${OUTPUT}\n\n"
+      )
+    endif (HAVE_${VARIABLE})
+  endif ("HAVE_${VARIABLE}" MATCHES "^HAVE_${VARIABLE}$")
+  set (CMAKE_ALLOW_UNKNOWN_VARIABLE_READ_ACCESS)
+ENDMACRO (HDF_CHECK_TYPE_SIZE)
diff --git a/config/cmake_ext_mod/ConfigureChecks.cmake b/config/cmake_ext_mod/ConfigureChecks.cmake
new file mode 100644
index 0000000..d715383
--- /dev/null
+++ b/config/cmake_ext_mod/ConfigureChecks.cmake
@@ -0,0 +1,751 @@
+#-----------------------------------------------------------------------------
+# Include all the necessary files for macros
+#-----------------------------------------------------------------------------
+include (${CMAKE_ROOT}/Modules/CheckFunctionExists.cmake)
+include (${CMAKE_ROOT}/Modules/CheckIncludeFile.cmake)
+include (${CMAKE_ROOT}/Modules/CheckIncludeFileCXX.cmake)
+include (${CMAKE_ROOT}/Modules/CheckIncludeFiles.cmake)
+include (${CMAKE_ROOT}/Modules/CheckLibraryExists.cmake)
+include (${CMAKE_ROOT}/Modules/CheckSymbolExists.cmake)
+include (${CMAKE_ROOT}/Modules/CheckTypeSize.cmake)
+include (${CMAKE_ROOT}/Modules/CheckVariableExists.cmake)
+include (${CMAKE_ROOT}/Modules/CheckFortranFunctionExists.cmake)
+include (${CMAKE_ROOT}/Modules/TestBigEndian.cmake)
+include (${CMAKE_ROOT}/Modules/TestForSTDNamespace.cmake)
+
+#-----------------------------------------------------------------------------
+# APPLE/Darwin setup
+#-----------------------------------------------------------------------------
+if (APPLE)
+  list (LENGTH CMAKE_OSX_ARCHITECTURES ARCH_LENGTH)
+  if (ARCH_LENGTH GREATER 1)
+    set (CMAKE_OSX_ARCHITECTURES "" CACHE STRING "" FORCE)
+    message(FATAL_ERROR "Building Universal Binaries on OS X is NOT supported by the HDF5 project. This is"
+    "due to technical reasons. The best approach would be build each architecture in separate directories"
+    "and use the 'lipo' tool to combine them into a single executable or library. The 'CMAKE_OSX_ARCHITECTURES'"
+    "variable has been set to a blank value which will build the default architecture for this system.")
+  endif ()
+  set (${HDF_PREFIX}_AC_APPLE_UNIVERSAL_BUILD 0)
+endif (APPLE)
+
+# Check for Darwin (not just Apple - we also want to catch OpenDarwin)
+if (${CMAKE_SYSTEM_NAME} MATCHES "Darwin") 
+    set (${HDF_PREFIX}_HAVE_DARWIN 1) 
+endif (${CMAKE_SYSTEM_NAME} MATCHES "Darwin")
+
+# Check for Solaris
+if (${CMAKE_SYSTEM_NAME} MATCHES "SunOS") 
+    set (${HDF_PREFIX}_HAVE_SOLARIS 1) 
+endif (${CMAKE_SYSTEM_NAME} MATCHES "SunOS")
+
+#-----------------------------------------------------------------------------
+# This MACRO checks IF the symbol exists in the library and IF it
+# does, it appends library to the list.
+#-----------------------------------------------------------------------------
+set (LINK_LIBS "")
+MACRO (CHECK_LIBRARY_EXISTS_CONCAT LIBRARY SYMBOL VARIABLE)
+  CHECK_LIBRARY_EXISTS ("${LIBRARY};${LINK_LIBS}" ${SYMBOL} "" ${VARIABLE})
+  if (${VARIABLE})
+    set (LINK_LIBS ${LINK_LIBS} ${LIBRARY})
+  endif (${VARIABLE})
+ENDMACRO (CHECK_LIBRARY_EXISTS_CONCAT)
+
+# ----------------------------------------------------------------------
+# WINDOWS Hard code Values
+# ----------------------------------------------------------------------
+
+set (WINDOWS)
+if (WIN32)
+  if (MINGW)
+    set (${HDF_PREFIX}_HAVE_MINGW 1)
+    set (WINDOWS 1) # MinGW tries to imitate Windows
+    set (CMAKE_REQUIRED_FLAGS "-DWIN32_LEAN_AND_MEAN=1 -DNOGDI=1")
+  endif (MINGW)
+  set (${HDF_PREFIX}_HAVE_WIN32_API 1)
+  set (CMAKE_REQUIRED_LIBRARIES "ws2_32.lib;wsock32.lib")
+  if (NOT UNIX AND NOT MINGW)
+    set (WINDOWS 1)
+    set (CMAKE_REQUIRED_FLAGS "/DWIN32_LEAN_AND_MEAN=1 /DNOGDI=1")
+    if (MSVC)
+      set (${HDF_PREFIX}_HAVE_VISUAL_STUDIO 1)
+    endif (MSVC)
+  endif (NOT UNIX AND NOT MINGW)
+endif (WIN32)
+
+if (WINDOWS)
+  set (${HDF_PREFIX}_HAVE_STDDEF_H 1)
+  set (${HDF_PREFIX}_HAVE_SYS_STAT_H 1)
+  set (${HDF_PREFIX}_HAVE_SYS_TYPES_H 1)
+  set (${HDF_PREFIX}_HAVE_LIBM 1)
+  set (${HDF_PREFIX}_HAVE_STRDUP 1)
+  set (${HDF_PREFIX}_HAVE_SYSTEM 1)
+  set (${HDF_PREFIX}_HAVE_LONGJMP 1)
+  if (NOT MINGW)
+    set (${HDF_PREFIX}_HAVE_GETHOSTNAME 1)
+  endif (NOT MINGW)
+  if (NOT UNIX AND NOT CYGWIN AND NOT MINGW)
+    set (${HDF_PREFIX}_HAVE_GETCONSOLESCREENBUFFERINFO 1)
+  endif (NOT UNIX AND NOT CYGWIN AND NOT MINGW)
+  set (${HDF_PREFIX}_HAVE_FUNCTION 1)
+  set (${HDF_PREFIX}_GETTIMEOFDAY_GIVES_TZ 1)
+  set (${HDF_PREFIX}_HAVE_TIMEZONE 1)
+  set (${HDF_PREFIX}_HAVE_GETTIMEOFDAY 1)
+  set (${HDF_PREFIX}_LONE_COLON 0)
+  if (MINGW)
+    set (${HDF_PREFIX}_HAVE_WINSOCK2_H 1)
+  endif (MINGW)
+  set (${HDF_PREFIX}_HAVE_LIBWS2_32 1)
+  set (${HDF_PREFIX}_HAVE_LIBWSOCK32 1)
+endif (WINDOWS)
+
+# ----------------------------------------------------------------------
+# END of WINDOWS Hard code Values
+# ----------------------------------------------------------------------
+
+if (CYGWIN)
+  set (${HDF_PREFIX}_HAVE_LSEEK64 0)
+endif (CYGWIN)
+
+#-----------------------------------------------------------------------------
+#  Check for the math library "m"
+#-----------------------------------------------------------------------------
+if (NOT WINDOWS)
+  CHECK_LIBRARY_EXISTS_CONCAT ("m" ceil     ${HDF_PREFIX}_HAVE_LIBM)
+  CHECK_LIBRARY_EXISTS_CONCAT ("dl" dlopen     ${HDF_PREFIX}_HAVE_LIBDL)
+  CHECK_LIBRARY_EXISTS_CONCAT ("ws2_32" WSAStartup  ${HDF_PREFIX}_HAVE_LIBWS2_32)
+  CHECK_LIBRARY_EXISTS_CONCAT ("wsock32" gethostbyname ${HDF_PREFIX}_HAVE_LIBWSOCK32)
+endif (NOT WINDOWS)
+
+CHECK_LIBRARY_EXISTS_CONCAT ("ucb"    gethostname  ${HDF_PREFIX}_HAVE_LIBUCB)
+CHECK_LIBRARY_EXISTS_CONCAT ("socket" connect      ${HDF_PREFIX}_HAVE_LIBSOCKET)
+CHECK_LIBRARY_EXISTS ("c" gethostbyname "" NOT_NEED_LIBNSL)
+
+if (NOT NOT_NEED_LIBNSL)
+  CHECK_LIBRARY_EXISTS_CONCAT ("nsl"    gethostbyname  ${HDF_PREFIX}_HAVE_LIBNSL)
+endif (NOT NOT_NEED_LIBNSL)
+
+# For other tests to use the same libraries
+set (CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} ${LINK_LIBS})
+
+set (USE_INCLUDES "")
+if (WINDOWS)
+  set (USE_INCLUDES ${USE_INCLUDES} "windows.h")
+endif (WINDOWS)
+
+if (NOT WINDOWS)
+  TEST_BIG_ENDIAN (${HDF_PREFIX}_WORDS_BIGENDIAN)
+endif (NOT WINDOWS)
+
+# For other specific tests, use this MACRO.
+MACRO (HDF_FUNCTION_TEST OTHER_TEST)
+  if ("${HDF_PREFIX}_${OTHER_TEST}" MATCHES "^${HDF_PREFIX}_${OTHER_TEST}$")
+    set (MACRO_CHECK_FUNCTION_DEFINITIONS "-D${OTHER_TEST} ${CMAKE_REQUIRED_FLAGS}")
+    set (OTHER_TEST_ADD_LIBRARIES)
+    if (CMAKE_REQUIRED_LIBRARIES)
+      set (OTHER_TEST_ADD_LIBRARIES "-DLINK_LIBRARIES:STRING=${CMAKE_REQUIRED_LIBRARIES}")
+    endif (CMAKE_REQUIRED_LIBRARIES)
+
+    foreach (def ${HDF_EXTRA_TEST_DEFINITIONS})
+      set (MACRO_CHECK_FUNCTION_DEFINITIONS "${MACRO_CHECK_FUNCTION_DEFINITIONS} -D${def}=${${def}}")
+    endforeach (def)
+
+    foreach (def
+        HAVE_SYS_TIME_H
+        HAVE_UNISTD_H
+        HAVE_SYS_TYPES_H
+        HAVE_SYS_SOCKET_H
+    )
+      if ("${${HDF_PREFIX}_${def}}")
+        set (MACRO_CHECK_FUNCTION_DEFINITIONS "${MACRO_CHECK_FUNCTION_DEFINITIONS} -D${def}")
+      endif ("${${HDF_PREFIX}_${def}}")
+    endforeach (def)
+
+    if (LARGEFILE)
+      set (MACRO_CHECK_FUNCTION_DEFINITIONS
+          "${MACRO_CHECK_FUNCTION_DEFINITIONS} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE"
+      )
+    endif (LARGEFILE)
+
+    #message (STATUS "Performing ${OTHER_TEST}")
+    TRY_COMPILE (${OTHER_TEST}
+        ${CMAKE_BINARY_DIR}
+        ${HDF_RESOURCES_EXT_DIR}/HDFTests.c
+        CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${MACRO_CHECK_FUNCTION_DEFINITIONS}
+        "${OTHER_TEST_ADD_LIBRARIES}"
+        OUTPUT_VARIABLE OUTPUT
+    )
+    if (${OTHER_TEST})
+      set (${HDF_PREFIX}_${OTHER_TEST} 1 CACHE INTERNAL "Other test ${FUNCTION}")
+      message (STATUS "Performing Other Test ${OTHER_TEST} - Success")
+    else (${OTHER_TEST})
+      message (STATUS "Performing Other Test ${OTHER_TEST} - Failed")
+      set (${HDF_PREFIX}_${OTHER_TEST} "" CACHE INTERNAL "Other test ${FUNCTION}")
+      file (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log
+          "Performing Other Test ${OTHER_TEST} failed with the following output:\n"
+          "${OUTPUT}\n"
+      )
+    endif (${OTHER_TEST})
+  endif ("${HDF_PREFIX}_${OTHER_TEST}" MATCHES "^${HDF_PREFIX}_${OTHER_TEST}$")
+ENDMACRO (HDF_FUNCTION_TEST)
+
+#-----------------------------------------------------------------------------
+# Check for these functions before the time headers are checked
+#-----------------------------------------------------------------------------
+HDF_FUNCTION_TEST (STDC_HEADERS)
+
+#-----------------------------------------------------------------------------
+# Check IF header file exists and add it to the list.
+#-----------------------------------------------------------------------------
+MACRO (CHECK_INCLUDE_FILE_CONCAT FILE VARIABLE)
+  CHECK_INCLUDE_FILES ("${USE_INCLUDES};${FILE}" ${VARIABLE})
+  if (${VARIABLE})
+    set (USE_INCLUDES ${USE_INCLUDES} ${FILE})
+  endif (${VARIABLE})
+ENDMACRO (CHECK_INCLUDE_FILE_CONCAT)
+
+#-----------------------------------------------------------------------------
+#  Check for the existence of certain header files
+#-----------------------------------------------------------------------------
+CHECK_INCLUDE_FILE_CONCAT ("sys/resource.h"  ${HDF_PREFIX}_HAVE_SYS_RESOURCE_H)
+CHECK_INCLUDE_FILE_CONCAT ("sys/time.h"      ${HDF_PREFIX}_HAVE_SYS_TIME_H)
+CHECK_INCLUDE_FILE_CONCAT ("unistd.h"        ${HDF_PREFIX}_HAVE_UNISTD_H)
+CHECK_INCLUDE_FILE_CONCAT ("sys/ioctl.h"     ${HDF_PREFIX}_HAVE_SYS_IOCTL_H)
+CHECK_INCLUDE_FILE_CONCAT ("sys/stat.h"      ${HDF_PREFIX}_HAVE_SYS_STAT_H)
+CHECK_INCLUDE_FILE_CONCAT ("sys/socket.h"    ${HDF_PREFIX}_HAVE_SYS_SOCKET_H)
+CHECK_INCLUDE_FILE_CONCAT ("sys/types.h"     ${HDF_PREFIX}_HAVE_SYS_TYPES_H)
+CHECK_INCLUDE_FILE_CONCAT ("stddef.h"        ${HDF_PREFIX}_HAVE_STDDEF_H)
+CHECK_INCLUDE_FILE_CONCAT ("setjmp.h"        ${HDF_PREFIX}_HAVE_SETJMP_H)
+CHECK_INCLUDE_FILE_CONCAT ("features.h"      ${HDF_PREFIX}_HAVE_FEATURES_H)
+CHECK_INCLUDE_FILE_CONCAT ("dirent.h"        ${HDF_PREFIX}_HAVE_DIRENT_H)
+CHECK_INCLUDE_FILE_CONCAT ("stdint.h"        ${HDF_PREFIX}_HAVE_STDINT_H)
+
+# IF the c compiler found stdint, check the C++ as well. On some systems this
+# file will be found by C but not C++, only do this test IF the C++ compiler
+# has been initialized (e.g. the project also includes some c++)
+if (${HDF_PREFIX}_HAVE_STDINT_H AND CMAKE_CXX_COMPILER_LOADED)
+  CHECK_INCLUDE_FILE_CXX ("stdint.h" ${HDF_PREFIX}_HAVE_STDINT_H_CXX)
+  if (NOT ${HDF_PREFIX}_HAVE_STDINT_H_CXX)
+    set (${HDF_PREFIX}_HAVE_STDINT_H "" CACHE INTERNAL "Have includes HAVE_STDINT_H")
+    set (USE_INCLUDES ${USE_INCLUDES} "stdint.h")
+  endif (NOT ${HDF_PREFIX}_HAVE_STDINT_H_CXX)
+endif (${HDF_PREFIX}_HAVE_STDINT_H AND CMAKE_CXX_COMPILER_LOADED)
+
+# Darwin
+CHECK_INCLUDE_FILE_CONCAT ("mach/mach_time.h" ${HDF_PREFIX}_HAVE_MACH_MACH_TIME_H)
+
+# Windows
+CHECK_INCLUDE_FILE_CONCAT ("io.h"            ${HDF_PREFIX}_HAVE_IO_H)
+if (NOT CYGWIN)
+  CHECK_INCLUDE_FILE_CONCAT ("winsock2.h"      ${HDF_PREFIX}_HAVE_WINSOCK2_H)
+endif (NOT CYGWIN)
+CHECK_INCLUDE_FILE_CONCAT ("sys/timeb.h"     ${HDF_PREFIX}_HAVE_SYS_TIMEB_H)
+
+if (CMAKE_SYSTEM_NAME MATCHES "OSF")
+  CHECK_INCLUDE_FILE_CONCAT ("sys/sysinfo.h" ${HDF_PREFIX}_HAVE_SYS_SYSINFO_H)
+  CHECK_INCLUDE_FILE_CONCAT ("sys/proc.h"    ${HDF_PREFIX}_HAVE_SYS_PROC_H)
+else (CMAKE_SYSTEM_NAME MATCHES "OSF")
+  set (${HDF_PREFIX}_HAVE_SYS_SYSINFO_H "" CACHE INTERNAL "" FORCE)
+  set (${HDF_PREFIX}_HAVE_SYS_PROC_H    "" CACHE INTERNAL "" FORCE)
+endif (CMAKE_SYSTEM_NAME MATCHES "OSF")
+
+CHECK_INCLUDE_FILE_CONCAT ("globus/common.h" ${HDF_PREFIX}_HAVE_GLOBUS_COMMON_H)
+CHECK_INCLUDE_FILE_CONCAT ("pdb.h"           ${HDF_PREFIX}_HAVE_PDB_H)
+CHECK_INCLUDE_FILE_CONCAT ("pthread.h"       ${HDF_PREFIX}_HAVE_PTHREAD_H)
+CHECK_INCLUDE_FILE_CONCAT ("srbclient.h"     ${HDF_PREFIX}_HAVE_SRBCLIENT_H)
+CHECK_INCLUDE_FILE_CONCAT ("string.h"        ${HDF_PREFIX}_HAVE_STRING_H)
+CHECK_INCLUDE_FILE_CONCAT ("strings.h"       ${HDF_PREFIX}_HAVE_STRINGS_H)
+CHECK_INCLUDE_FILE_CONCAT ("time.h"          ${HDF_PREFIX}_HAVE_TIME_H)
+CHECK_INCLUDE_FILE_CONCAT ("stdlib.h"        ${HDF_PREFIX}_HAVE_STDLIB_H)
+CHECK_INCLUDE_FILE_CONCAT ("memory.h"        ${HDF_PREFIX}_HAVE_MEMORY_H)
+CHECK_INCLUDE_FILE_CONCAT ("dlfcn.h"         ${HDF_PREFIX}_HAVE_DLFCN_H)
+CHECK_INCLUDE_FILE_CONCAT ("inttypes.h"      ${HDF_PREFIX}_HAVE_INTTYPES_H)
+CHECK_INCLUDE_FILE_CONCAT ("netinet/in.h"    ${HDF_PREFIX}_HAVE_NETINET_IN_H)
+
+#-----------------------------------------------------------------------------
+#  Check for large file support
+#-----------------------------------------------------------------------------
+
+# The linux-lfs option is deprecated.
+set (LINUX_LFS 0)
+
+set (HDF_EXTRA_C_FLAGS)
+set (HDF_EXTRA_FLAGS)
+if (NOT WINDOWS)
+  if (NOT ${HDF_PREFIX}_HAVE_SOLARIS)
+  # Linux Specific flags
+  # This was originally defined as _POSIX_SOURCE which was updated to
+  # _POSIX_C_SOURCE=199506L to expose a greater amount of POSIX
+  # functionality so clock_gettime and CLOCK_MONOTONIC are defined
+  # correctly.
+  # POSIX feature information can be found in the gcc manual at:
+  # http://www.gnu.org/s/libc/manual/html_node/Feature-Test-Macros.html
+  set (HDF_EXTRA_C_FLAGS -D_POSIX_C_SOURCE=199506L)
+  set (HDF_EXTRA_FLAGS -D_BSD_SOURCE)
+  
+  option (HDF_ENABLE_LARGE_FILE "Enable support for large (64-bit) files on Linux." ON)
+  if (HDF_ENABLE_LARGE_FILE)
+    set (msg "Performing TEST_LFS_WORKS")
+    TRY_RUN (TEST_LFS_WORKS_RUN   TEST_LFS_WORKS_COMPILE
+        ${CMAKE_BINARY_DIR}
+        ${HDF_RESOURCES_EXT_DIR}/HDFTests.c
+        CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=-DTEST_LFS_WORKS
+        OUTPUT_VARIABLE OUTPUT
+    )
+    if (TEST_LFS_WORKS_COMPILE)
+      if (TEST_LFS_WORKS_RUN  MATCHES 0)
+        set (TEST_LFS_WORKS 1 CACHE INTERNAL ${msg})
+        set (LARGEFILE 1)
+        set (HDF_EXTRA_FLAGS ${HDF_EXTRA_FLAGS} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE)
+        message (STATUS "${msg}... yes")
+      else (TEST_LFS_WORKS_RUN  MATCHES 0)
+        set (TEST_LFS_WORKS "" CACHE INTERNAL ${msg})
+        message (STATUS "${msg}... no")
+        file (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log
+              "Test TEST_LFS_WORKS Run failed with the following output and exit code:\n ${OUTPUT}\n"
+        )
+      endif (TEST_LFS_WORKS_RUN  MATCHES 0)
+    else (TEST_LFS_WORKS_COMPILE )
+      set (TEST_LFS_WORKS "" CACHE INTERNAL ${msg})
+      message (STATUS "${msg}... no")
+      file (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log
+          "Test TEST_LFS_WORKS Compile failed with the following output:\n ${OUTPUT}\n"
+      )
+    endif (TEST_LFS_WORKS_COMPILE)
+  endif (HDF_ENABLE_LARGE_FILE)
+  set (CMAKE_REQUIRED_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS} ${HDF_EXTRA_FLAGS})
+  endif (NOT ${HDF_PREFIX}_HAVE_SOLARIS)
+endif (NOT WINDOWS)
+
+add_definitions (${HDF_EXTRA_FLAGS})
+
+#-----------------------------------------------------------------------------
+# Check for HAVE_OFF64_T functionality
+#-----------------------------------------------------------------------------
+if (NOT WINDOWS OR MINGW)
+  HDF_FUNCTION_TEST (HAVE_OFF64_T)
+  if (${HDF_PREFIX}_HAVE_OFF64_T)
+    CHECK_FUNCTION_EXISTS (lseek64            ${HDF_PREFIX}_HAVE_LSEEK64)
+    CHECK_FUNCTION_EXISTS (fseeko64           ${HDF_PREFIX}_HAVE_FSEEKO64)
+    CHECK_FUNCTION_EXISTS (ftello64           ${HDF_PREFIX}_HAVE_FTELLO64)
+    CHECK_FUNCTION_EXISTS (ftruncate64        ${HDF_PREFIX}_HAVE_FTRUNCATE64)
+  endif (${HDF_PREFIX}_HAVE_OFF64_T)
+
+  CHECK_FUNCTION_EXISTS (fseeko               ${HDF_PREFIX}_HAVE_FSEEKO)
+  CHECK_FUNCTION_EXISTS (ftello               ${HDF_PREFIX}_HAVE_FTELLO)
+
+  HDF_FUNCTION_TEST (HAVE_STAT64_STRUCT)
+  if (HAVE_STAT64_STRUCT)
+    CHECK_FUNCTION_EXISTS (fstat64            ${HDF_PREFIX}_HAVE_FSTAT64)
+    CHECK_FUNCTION_EXISTS (stat64             ${HDF_PREFIX}_HAVE_STAT64)
+  endif (HAVE_STAT64_STRUCT)
+endif (NOT WINDOWS OR MINGW)
+
+#-----------------------------------------------------------------------------
+#  Check the size in bytes of all the int and float types
+#-----------------------------------------------------------------------------
+MACRO (HDF_CHECK_TYPE_SIZE type var)
+  set (aType ${type})
+  set (aVar  ${var})
+#  message (STATUS "Checking size of ${aType} and storing into ${aVar}")
+  CHECK_TYPE_SIZE (${aType}   ${aVar})
+  if (NOT ${aVar})
+    set (${aVar} 0 CACHE INTERNAL "SizeOf for ${aType}")
+#    message (STATUS "Size of ${aType} was NOT Found")
+  endif (NOT ${aVar})
+ENDMACRO (HDF_CHECK_TYPE_SIZE)
+
+HDF_CHECK_TYPE_SIZE (char           ${HDF_PREFIX}_SIZEOF_CHAR)
+HDF_CHECK_TYPE_SIZE (short          ${HDF_PREFIX}_SIZEOF_SHORT)
+HDF_CHECK_TYPE_SIZE (int            ${HDF_PREFIX}_SIZEOF_INT)
+HDF_CHECK_TYPE_SIZE (unsigned       ${HDF_PREFIX}_SIZEOF_UNSIGNED)
+if (NOT APPLE)
+  HDF_CHECK_TYPE_SIZE (long         ${HDF_PREFIX}_SIZEOF_LONG)
+endif (NOT APPLE)
+HDF_CHECK_TYPE_SIZE ("long long"    ${HDF_PREFIX}_SIZEOF_LONG_LONG)
+HDF_CHECK_TYPE_SIZE (__int64        ${HDF_PREFIX}_SIZEOF___INT64)
+if (NOT ${HDF_PREFIX}_SIZEOF___INT64)
+  set (${HDF_PREFIX}_SIZEOF___INT64 0)
+endif (NOT ${HDF_PREFIX}_SIZEOF___INT64)
+
+HDF_CHECK_TYPE_SIZE (float          ${HDF_PREFIX}_SIZEOF_FLOAT)
+HDF_CHECK_TYPE_SIZE (double         ${HDF_PREFIX}_SIZEOF_DOUBLE)
+HDF_CHECK_TYPE_SIZE ("long double"  ${HDF_PREFIX}_SIZEOF_LONG_DOUBLE)
+
+HDF_CHECK_TYPE_SIZE (int8_t         ${HDF_PREFIX}_SIZEOF_INT8_T)
+HDF_CHECK_TYPE_SIZE (uint8_t        ${HDF_PREFIX}_SIZEOF_UINT8_T)
+HDF_CHECK_TYPE_SIZE (int_least8_t   ${HDF_PREFIX}_SIZEOF_INT_LEAST8_T)
+HDF_CHECK_TYPE_SIZE (uint_least8_t  ${HDF_PREFIX}_SIZEOF_UINT_LEAST8_T)
+HDF_CHECK_TYPE_SIZE (int_fast8_t    ${HDF_PREFIX}_SIZEOF_INT_FAST8_T)
+HDF_CHECK_TYPE_SIZE (uint_fast8_t   ${HDF_PREFIX}_SIZEOF_UINT_FAST8_T)
+
+HDF_CHECK_TYPE_SIZE (int16_t        ${HDF_PREFIX}_SIZEOF_INT16_T)
+HDF_CHECK_TYPE_SIZE (uint16_t       ${HDF_PREFIX}_SIZEOF_UINT16_T)
+HDF_CHECK_TYPE_SIZE (int_least16_t  ${HDF_PREFIX}_SIZEOF_INT_LEAST16_T)
+HDF_CHECK_TYPE_SIZE (uint_least16_t ${HDF_PREFIX}_SIZEOF_UINT_LEAST16_T)
+HDF_CHECK_TYPE_SIZE (int_fast16_t   ${HDF_PREFIX}_SIZEOF_INT_FAST16_T)
+HDF_CHECK_TYPE_SIZE (uint_fast16_t  ${HDF_PREFIX}_SIZEOF_UINT_FAST16_T)
+
+HDF_CHECK_TYPE_SIZE (int32_t        ${HDF_PREFIX}_SIZEOF_INT32_T)
+HDF_CHECK_TYPE_SIZE (uint32_t       ${HDF_PREFIX}_SIZEOF_UINT32_T)
+HDF_CHECK_TYPE_SIZE (int_least32_t  ${HDF_PREFIX}_SIZEOF_INT_LEAST32_T)
+HDF_CHECK_TYPE_SIZE (uint_least32_t ${HDF_PREFIX}_SIZEOF_UINT_LEAST32_T)
+HDF_CHECK_TYPE_SIZE (int_fast32_t   ${HDF_PREFIX}_SIZEOF_INT_FAST32_T)
+HDF_CHECK_TYPE_SIZE (uint_fast32_t  ${HDF_PREFIX}_SIZEOF_UINT_FAST32_T)
+
+HDF_CHECK_TYPE_SIZE (int64_t        ${HDF_PREFIX}_SIZEOF_INT64_T)
+HDF_CHECK_TYPE_SIZE (uint64_t       ${HDF_PREFIX}_SIZEOF_UINT64_T)
+HDF_CHECK_TYPE_SIZE (int_least64_t  ${HDF_PREFIX}_SIZEOF_INT_LEAST64_T)
+HDF_CHECK_TYPE_SIZE (uint_least64_t ${HDF_PREFIX}_SIZEOF_UINT_LEAST64_T)
+HDF_CHECK_TYPE_SIZE (int_fast64_t   ${HDF_PREFIX}_SIZEOF_INT_FAST64_T)
+HDF_CHECK_TYPE_SIZE (uint_fast64_t  ${HDF_PREFIX}_SIZEOF_UINT_FAST64_T)
+
+if (NOT APPLE)
+  HDF_CHECK_TYPE_SIZE (size_t       ${HDF_PREFIX}_SIZEOF_SIZE_T)
+  HDF_CHECK_TYPE_SIZE (ssize_t      ${HDF_PREFIX}_SIZEOF_SSIZE_T)
+  if (NOT ${HDF_PREFIX}_SIZEOF_SSIZE_T)
+    set (${HDF_PREFIX}_SIZEOF_SSIZE_T 0)
+  endif (NOT ${HDF_PREFIX}_SIZEOF_SSIZE_T)
+  if (NOT WINDOWS)
+    HDF_CHECK_TYPE_SIZE (ptrdiff_t    ${HDF_PREFIX}_SIZEOF_PTRDIFF_T)
+  endif (NOT WINDOWS)
+endif (NOT APPLE)
+
+HDF_CHECK_TYPE_SIZE (off_t          ${HDF_PREFIX}_SIZEOF_OFF_T)
+HDF_CHECK_TYPE_SIZE (off64_t        ${HDF_PREFIX}_SIZEOF_OFF64_T)
+if (NOT ${HDF_PREFIX}_SIZEOF_OFF64_T)
+  set (${HDF_PREFIX}_SIZEOF_OFF64_T 0)
+endif (NOT ${HDF_PREFIX}_SIZEOF_OFF64_T)
+
+if (NOT WINDOWS)
+  #-----------------------------------------------------------------------------
+  # Check if the dev_t type is a scalar type
+  #-----------------------------------------------------------------------------
+  HDF_FUNCTION_TEST (DEV_T_IS_SCALAR)
+
+  # ----------------------------------------------------------------------
+  # Check for MONOTONIC_TIMER support (used in clock_gettime).  This has
+  # to be done after any POSIX/BSD defines to ensure that the test gets
+  # the correct POSIX level on linux.
+  CHECK_VARIABLE_EXISTS (CLOCK_MONOTONIC HAVE_CLOCK_MONOTONIC)
+
+  #-----------------------------------------------------------------------------
+  # Check a bunch of time functions
+  #-----------------------------------------------------------------------------
+  foreach (test
+      HAVE_TM_GMTOFF
+      HAVE___TM_GMTOFF
+#      HAVE_TIMEZONE
+      HAVE_STRUCT_TIMEZONE
+      GETTIMEOFDAY_GIVES_TZ
+      TIME_WITH_SYS_TIME
+      HAVE_TM_ZONE
+      HAVE_STRUCT_TM_TM_ZONE
+  )
+    HDF_FUNCTION_TEST (${test})
+  endforeach (test)
+  if (NOT CYGWIN AND NOT MINGW)
+      HDF_FUNCTION_TEST (HAVE_TIMEZONE)
+#      HDF_FUNCTION_TEST (HAVE_STAT_ST_BLOCKS)
+  endif (NOT CYGWIN AND NOT MINGW)
+
+  # ----------------------------------------------------------------------
+  # Does the struct stat have the st_blocks field?  This field is not Posix.
+  #
+  HDF_FUNCTION_TEST (HAVE_STAT_ST_BLOCKS)
+
+  # ----------------------------------------------------------------------
+  # How do we figure out the width of a tty in characters?
+  #
+  CHECK_FUNCTION_EXISTS (ioctl             ${HDF_PREFIX}_HAVE_IOCTL)
+  HDF_FUNCTION_TEST (HAVE_STRUCT_VIDEOCONFIG)
+  HDF_FUNCTION_TEST (HAVE_STRUCT_TEXT_INFO)
+  CHECK_FUNCTION_EXISTS (_getvideoconfig   ${HDF_PREFIX}_HAVE__GETVIDEOCONFIG)
+  CHECK_FUNCTION_EXISTS (gettextinfo       ${HDF_PREFIX}_HAVE_GETTEXTINFO)
+  CHECK_FUNCTION_EXISTS (_scrsize          ${HDF_PREFIX}_HAVE__SCRSIZE)
+  if (NOT CYGWIN AND NOT MINGW)
+    CHECK_FUNCTION_EXISTS (GetConsoleScreenBufferInfo    ${HDF_PREFIX}_HAVE_GETCONSOLESCREENBUFFERINFO)
+  endif (NOT CYGWIN AND NOT MINGW)
+  CHECK_SYMBOL_EXISTS (TIOCGWINSZ "sys/ioctl.h" ${HDF_PREFIX}_HAVE_TIOCGWINSZ)
+  CHECK_SYMBOL_EXISTS (TIOCGETD   "sys/ioctl.h" ${HDF_PREFIX}_HAVE_TIOCGETD)
+endif (NOT WINDOWS)
+
+#-----------------------------------------------------------------------------
+# Check for some functions that are used
+#
+CHECK_FUNCTION_EXISTS (alarm             ${HDF_PREFIX}_HAVE_ALARM)
+CHECK_FUNCTION_EXISTS (fork              ${HDF_PREFIX}_HAVE_FORK)
+CHECK_FUNCTION_EXISTS (frexpf            ${HDF_PREFIX}_HAVE_FREXPF)
+CHECK_FUNCTION_EXISTS (frexpl            ${HDF_PREFIX}_HAVE_FREXPL)
+
+CHECK_FUNCTION_EXISTS (gethostname       ${HDF_PREFIX}_HAVE_GETHOSTNAME)
+CHECK_FUNCTION_EXISTS (getpwuid          ${HDF_PREFIX}_HAVE_GETPWUID)
+CHECK_FUNCTION_EXISTS (getrusage         ${HDF_PREFIX}_HAVE_GETRUSAGE)
+CHECK_FUNCTION_EXISTS (lstat             ${HDF_PREFIX}_HAVE_LSTAT)
+
+CHECK_FUNCTION_EXISTS (rand_r            ${HDF_PREFIX}_HAVE_RAND_R)
+CHECK_FUNCTION_EXISTS (random            ${HDF_PREFIX}_HAVE_RANDOM)
+CHECK_FUNCTION_EXISTS (setsysinfo        ${HDF_PREFIX}_HAVE_SETSYSINFO)
+
+CHECK_FUNCTION_EXISTS (signal            ${HDF_PREFIX}_HAVE_SIGNAL)
+CHECK_FUNCTION_EXISTS (longjmp           ${HDF_PREFIX}_HAVE_LONGJMP)
+CHECK_FUNCTION_EXISTS (setjmp            ${HDF_PREFIX}_HAVE_SETJMP)
+CHECK_FUNCTION_EXISTS (siglongjmp        ${HDF_PREFIX}_HAVE_SIGLONGJMP)
+CHECK_FUNCTION_EXISTS (sigsetjmp         ${HDF_PREFIX}_HAVE_SIGSETJMP)
+CHECK_FUNCTION_EXISTS (sigaction         ${HDF_PREFIX}_HAVE_SIGACTION)
+CHECK_FUNCTION_EXISTS (sigprocmask       ${HDF_PREFIX}_HAVE_SIGPROCMASK)
+
+CHECK_FUNCTION_EXISTS (snprintf          ${HDF_PREFIX}_HAVE_SNPRINTF)
+CHECK_FUNCTION_EXISTS (srandom           ${HDF_PREFIX}_HAVE_SRANDOM)
+CHECK_FUNCTION_EXISTS (strdup            ${HDF_PREFIX}_HAVE_STRDUP)
+CHECK_FUNCTION_EXISTS (symlink           ${HDF_PREFIX}_HAVE_SYMLINK)
+CHECK_FUNCTION_EXISTS (system            ${HDF_PREFIX}_HAVE_SYSTEM)
+
+CHECK_FUNCTION_EXISTS (tmpfile           ${HDF_PREFIX}_HAVE_TMPFILE)
+CHECK_FUNCTION_EXISTS (asprintf          ${HDF_PREFIX}_HAVE_ASPRINTF)
+CHECK_FUNCTION_EXISTS (vasprintf         ${HDF_PREFIX}_HAVE_VASPRINTF)
+CHECK_FUNCTION_EXISTS (waitpid           ${HDF_PREFIX}_HAVE_WAITPID)
+
+CHECK_FUNCTION_EXISTS (vsnprintf         ${HDF_PREFIX}_HAVE_VSNPRINTF)
+if (NOT WINDOWS)
+  if (${HDF_PREFIX}_HAVE_VSNPRINTF)
+    HDF_FUNCTION_TEST (VSNPRINTF_WORKS)
+  endif (${HDF_PREFIX}_HAVE_VSNPRINTF)
+endif (NOT WINDOWS)
+
+#-----------------------------------------------------------------------------
+# sigsetjmp is special; may actually be a macro
+#-----------------------------------------------------------------------------
+if (NOT ${HDF_PREFIX}_HAVE_SIGSETJMP)
+  if (${HDF_PREFIX}_HAVE_SETJMP_H)
+    CHECK_SYMBOL_EXISTS (sigsetjmp "setjmp.h" ${HDF_PREFIX}_HAVE_MACRO_SIGSETJMP)
+    if (${HDF_PREFIX}_HAVE_MACRO_SIGSETJMP)
+      set (${HDF_PREFIX}_HAVE_SIGSETJMP 1)
+    endif (${HDF_PREFIX}_HAVE_MACRO_SIGSETJMP)
+  endif (${HDF_PREFIX}_HAVE_SETJMP_H)
+endif (NOT ${HDF_PREFIX}_HAVE_SIGSETJMP)
+
+#-----------------------------------------------------------------------------
+# Check for Symbols
+CHECK_SYMBOL_EXISTS (tzname "time.h" ${HDF_PREFIX}_HAVE_DECL_TZNAME)
+
+#-----------------------------------------------------------------------------
+# Check a bunch of other functions
+#-----------------------------------------------------------------------------
+if (NOT WINDOWS)
+  foreach (test
+      LONE_COLON
+      HAVE_ATTRIBUTE
+      HAVE_C99_FUNC
+#      STDC_HEADERS
+      HAVE_FUNCTION
+      HAVE_C99_DESIGNATED_INITIALIZER
+      SYSTEM_SCOPE_THREADS
+      HAVE_SOCKLEN_T
+      CXX_HAVE_OFFSETOF
+  )
+    HDF_FUNCTION_TEST (${test})
+  endforeach (test)
+endif (NOT WINDOWS)
+
+# For other CXX specific tests, use this MACRO.
+MACRO (HDF_CXX_FUNCTION_TEST OTHER_TEST)
+  if ("${OTHER_TEST}" MATCHES "^${OTHER_TEST}$")
+    set (MACRO_CHECK_FUNCTION_DEFINITIONS "-D${OTHER_TEST} ${CMAKE_REQUIRED_FLAGS}")
+    set (OTHER_TEST_ADD_LIBRARIES)
+    if (CMAKE_REQUIRED_LIBRARIES)
+      set (OTHER_TEST_ADD_LIBRARIES "-DLINK_LIBRARIES:STRING=${CMAKE_REQUIRED_LIBRARIES}")
+    endif (CMAKE_REQUIRED_LIBRARIES)
+
+    foreach (def ${HDF_EXTRA_TEST_DEFINITIONS})
+      set (MACRO_CHECK_FUNCTION_DEFINITIONS "${MACRO_CHECK_FUNCTION_DEFINITIONS} -D${def}=${${def}}")
+    endforeach (def)
+
+    foreach (def
+        HAVE_SYS_TIME_H
+        HAVE_UNISTD_H
+        HAVE_SYS_TYPES_H
+        HAVE_SYS_SOCKET_H
+    )
+      if ("${${HDF_PREFIX}_${def}}")
+        set (MACRO_CHECK_FUNCTION_DEFINITIONS "${MACRO_CHECK_FUNCTION_DEFINITIONS} -D${def}")
+      endif ("${${HDF_PREFIX}_${def}}")
+    endforeach (def)
+
+    if (LARGEFILE)
+      set (MACRO_CHECK_FUNCTION_DEFINITIONS
+          "${MACRO_CHECK_FUNCTION_DEFINITIONS} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE"
+      )
+    endif (LARGEFILE)
+
+    #message (STATUS "Performing ${OTHER_TEST}")
+    TRY_COMPILE (${OTHER_TEST}
+        ${CMAKE_BINARY_DIR}
+        ${HDF_RESOURCES_EXT_DIR}/HDFCXXTests.cpp
+        CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${MACRO_CHECK_FUNCTION_DEFINITIONS}
+        "${OTHER_TEST_ADD_LIBRARIES}"
+        OUTPUT_VARIABLE OUTPUT
+    )
+    if (${OTHER_TEST} EQUAL 0)
+      set (${OTHER_TEST} 1 CACHE INTERNAL "CXX test ${FUNCTION}")
+      message (STATUS "Performing CXX Test ${OTHER_TEST} - Success")
+    else (${OTHER_TEST} EQUAL 0)
+      message (STATUS "Performing CXX Test ${OTHER_TEST} - Failed")
+      set (${OTHER_TEST} "" CACHE INTERNAL "CXX test ${FUNCTION}")
+      file (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log
+          "Performing CXX Test ${OTHER_TEST} failed with the following output:\n"
+          "${OUTPUT}\n"
+      )
+    endif (${OTHER_TEST} EQUAL 0)
+  endif ("${OTHER_TEST}" MATCHES "^${OTHER_TEST}$")
+ENDMACRO (HDF_CXX_FUNCTION_TEST)
+
+#-----------------------------------------------------------------------------
+# Check a bunch of cxx functions
+#-----------------------------------------------------------------------------
+if (CMAKE_CXX_COMPILER_LOADED)
+  foreach (test
+      OLD_HEADER_FILENAME
+      ${HDF_PREFIX}_NO_NAMESPACE
+      ${HDF_PREFIX}_NO_STD
+      BOOL_NOTDEFINED
+      NO_STATIC_CAST
+  )
+    HDF_CXX_FUNCTION_TEST (${test})
+  endforeach (test)
+endif (CMAKE_CXX_COMPILER_LOADED)
+
+#-----------------------------------------------------------------------------
+# Check if InitOnceExecuteOnce is available
+#-----------------------------------------------------------------------------
+if (WINDOWS)
+  if (NOT HDF_NO_IOEO_TEST)
+  message (STATUS "Checking for InitOnceExecuteOnce:")
+  if ("${${HDF_PREFIX}_HAVE_IOEO}" MATCHES "^${${HDF_PREFIX}_HAVE_IOEO}$")
+    if (LARGEFILE)
+      set (CMAKE_REQUIRED_DEFINITIONS
+          "${CURRENT_TEST_DEFINITIONS} -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE"
+      )
+    endif (LARGEFILE)
+    set (MACRO_CHECK_FUNCTION_DEFINITIONS 
+      "-DHAVE_IOEO ${CMAKE_REQUIRED_FLAGS}")
+    if (CMAKE_REQUIRED_LIBRARIES)
+      set (CHECK_C_SOURCE_COMPILES_ADD_LIBRARIES
+        "-DLINK_LIBRARIES:STRING=${CMAKE_REQUIRED_LIBRARIES}")
+    else (CMAKE_REQUIRED_LIBRARIES)
+      set (CHECK_C_SOURCE_COMPILES_ADD_LIBRARIES)
+    endif (CMAKE_REQUIRED_LIBRARIES)
+    if (CMAKE_REQUIRED_INCLUDES)
+      set (CHECK_C_SOURCE_COMPILES_ADD_INCLUDES
+        "-DINCLUDE_DIRECTORIES:STRING=${CMAKE_REQUIRED_INCLUDES}")
+    else (CMAKE_REQUIRED_INCLUDES)
+      set (CHECK_C_SOURCE_COMPILES_ADD_INCLUDES)
+    endif (CMAKE_REQUIRED_INCLUDES)
+
+    TRY_RUN(HAVE_IOEO_EXITCODE HAVE_IOEO_COMPILED
+      ${CMAKE_BINARY_DIR}
+      ${HDF_RESOURCES_EXT_DIR}/HDFTests.c
+      COMPILE_DEFINITIONS ${CMAKE_REQUIRED_DEFINITIONS}
+      CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${MACRO_CHECK_FUNCTION_DEFINITIONS}
+      -DCMAKE_SKIP_RPATH:BOOL=${CMAKE_SKIP_RPATH}
+      "${CHECK_C_SOURCE_COMPILES_ADD_LIBRARIES}"
+      "${CHECK_C_SOURCE_COMPILES_ADD_INCLUDES}"
+      COMPILE_OUTPUT_VARIABLE OUTPUT)
+    # if it did not compile make the return value fail code of 1
+    if (NOT HAVE_IOEO_COMPILED)
+      set (HAVE_IOEO_EXITCODE 1)
+    endif (NOT HAVE_IOEO_COMPILED)
+    # if the return value was 0 then it worked
+    if ("${HAVE_IOEO_EXITCODE}" EQUAL 0)
+      set (${HDF_PREFIX}_HAVE_IOEO 1 CACHE INTERNAL "Test InitOnceExecuteOnce")
+      message (STATUS "Performing Test InitOnceExecuteOnce - Success")
+      file (APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log 
+        "Performing C SOURCE FILE Test InitOnceExecuteOnce succeded with the following output:\n"
+        "${OUTPUT}\n"
+        "Return value: ${HAVE_IOEO}\n")
+    else ("${HAVE_IOEO_EXITCODE}" EQUAL 0)
+      if (CMAKE_CROSSCOMPILING AND "${HAVE_IOEO_EXITCODE}" MATCHES  "FAILED_TO_RUN")
+        set (${HDF_PREFIX}_HAVE_IOEO "${HAVE_IOEO_EXITCODE}")
+      else (CMAKE_CROSSCOMPILING AND "${HAVE_IOEO_EXITCODE}" MATCHES  "FAILED_TO_RUN")
+        set (${HDF_PREFIX}_HAVE_IOEO "" CACHE INTERNAL "Test InitOnceExecuteOnce")
+      endif (CMAKE_CROSSCOMPILING AND "${HAVE_IOEO_EXITCODE}" MATCHES  "FAILED_TO_RUN")
+
+      message (STATUS "Performing Test InitOnceExecuteOnce - Failed")
+      file (APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log 
+        "Performing InitOnceExecuteOnce Test  failed with the following output:\n"
+        "${OUTPUT}\n"
+        "Return value: ${HAVE_IOEO_EXITCODE}\n")
+    endif ("${HAVE_IOEO_EXITCODE}" EQUAL 0)
+  endif ("${${HDF_PREFIX}_HAVE_IOEO}" MATCHES "^${${HDF_PREFIX}_HAVE_IOEO}$")
+  endif (NOT HDF_NO_IOEO_TEST)
+endif (WINDOWS)
+
+#-----------------------------------------------------------------------------
+# Determine how 'inline' is used
+#-----------------------------------------------------------------------------
+set (HDF_EXTRA_TEST_DEFINITIONS INLINE_TEST_INLINE)
+foreach (inline_test inline __inline__ __inline)
+  set (INLINE_TEST_INLINE ${inline_test})
+  HDF_FUNCTION_TEST (INLINE_TEST_${inline_test})
+endforeach (inline_test)
+
+set (HDF_EXTRA_TEST_DEFINITIONS)
+if (INLINE_TEST___inline__)
+  set (${HDF_PREFIX}_inline __inline__)
+else (INLINE_TEST___inline__)
+  if (INLINE_TEST___inline)
+    set (${HDF_PREFIX}_inline __inline)
+  else (INLINE_TEST___inline)
+    if (INLINE_TEST_inline)
+      set (${HDF_PREFIX}_inline inline)
+    endif (INLINE_TEST_inline)
+  endif (INLINE_TEST___inline)
+endif (INLINE_TEST___inline__)
+
+#-----------------------------------------------------------------------------
+# Check how to print a Long Long integer
+#-----------------------------------------------------------------------------
+if (NOT ${HDF_PREFIX}_PRINTF_LL_WIDTH OR ${HDF_PREFIX}_PRINTF_LL_WIDTH MATCHES "unknown")
+  set (PRINT_LL_FOUND 0)
+  message (STATUS "Checking for appropriate format for 64 bit long:")
+  foreach (HDF5_PRINTF_LL l64 l L q I64 ll)
+    set (CURRENT_TEST_DEFINITIONS "-DPRINTF_LL_WIDTH=${HDF5_PRINTF_LL}")
+    if (${HDF_PREFIX}_SIZEOF_LONG_LONG)
+      set (CURRENT_TEST_DEFINITIONS "${CURRENT_TEST_DEFINITIONS} -DHAVE_LONG_LONG")
+    endif (${HDF_PREFIX}_SIZEOF_LONG_LONG)
+    TRY_RUN (HDF5_PRINTF_LL_TEST_RUN   HDF5_PRINTF_LL_TEST_COMPILE
+        ${CMAKE_BINARY_DIR}
+        ${HDF_RESOURCES_EXT_DIR}/HDFTests.c
+        CMAKE_FLAGS -DCOMPILE_DEFINITIONS:STRING=${CURRENT_TEST_DEFINITIONS}
+        OUTPUT_VARIABLE OUTPUT
+    )
+    if (HDF5_PRINTF_LL_TEST_COMPILE)
+      if (HDF5_PRINTF_LL_TEST_RUN MATCHES 0)
+        set (${HDF_PREFIX}_PRINTF_LL_WIDTH "\"${HDF5_PRINTF_LL}\"" CACHE INTERNAL "Width for printf for type `long long' or `__int64', us. `ll")
+        set (PRINT_LL_FOUND 1)
+      else (HDF5_PRINTF_LL_TEST_RUN MATCHES 0)
+        message ("Width with ${HDF5_PRINTF_LL} failed with result: ${HDF5_PRINTF_LL_TEST_RUN}")
+      endif (HDF5_PRINTF_LL_TEST_RUN MATCHES 0)
+    else (HDF5_PRINTF_LL_TEST_COMPILE)
+      file (APPEND ${CMAKE_BINARY_DIR}/CMakeFiles/CMakeError.log
+          "Test ${HDF_PREFIX}_PRINTF_LL_WIDTH for ${HDF5_PRINTF_LL} failed with the following output:\n ${OUTPUT}\n"
+      )
+    endif (HDF5_PRINTF_LL_TEST_COMPILE)
+  endforeach (HDF5_PRINTF_LL)
+
+  if (PRINT_LL_FOUND)
+    message (STATUS "Checking for apropriate format for 64 bit long: found ${${HDF_PREFIX}_PRINTF_LL_WIDTH}")
+  else (PRINT_LL_FOUND)
+    message (STATUS "Checking for apropriate format for 64 bit long: not found")
+    set (${HDF_PREFIX}_PRINTF_LL_WIDTH "\"unknown\"" CACHE INTERNAL
+        "Width for printf for type `long long' or `__int64', us. `ll"
+    )
+  endif (PRINT_LL_FOUND)
+endif (NOT ${HDF_PREFIX}_PRINTF_LL_WIDTH OR ${HDF_PREFIX}_PRINTF_LL_WIDTH MATCHES "unknown")
+
+# ----------------------------------------------------------------------
+# Set the flag to indicate that the machine can handle converting
+# denormalized floating-point values.
+# (This flag should be set for all machines, except for the Crays, where
+# the cache value is set in it's config file)
+#
+set (${HDF_PREFIX}_CONVERT_DENORMAL_FLOAT 1)
diff --git a/config/cmake_ext_mod/FindSZIP.cmake b/config/cmake_ext_mod/FindSZIP.cmake
new file mode 100644
index 0000000..e8e7f9f
--- /dev/null
+++ b/config/cmake_ext_mod/FindSZIP.cmake
@@ -0,0 +1,179 @@
+
+# - Find SZIP library
+# - Derived from the FindTiff.cmake that is included with cmake
+# Find the native SZIP includes and library
+# This module defines
+#  SZIP_INCLUDE_DIRS, where to find tiff.h, etc.
+#  SZIP_LIBRARIES, libraries to link against to use SZIP.
+#  SZIP_FOUND, If false, do not try to use SZIP.
+#    also defined, but not for general use are
+#  SZIP_LIBRARY, where to find the SZIP library.
+#  SZIP_LIBRARY_DEBUG - Debug version of SZIP library
+#  SZIP_LIBRARY_RELEASE - Release Version of SZIP library
+
+# message (STATUS "Finding SZIP library and headers..." )
+
+############################################
+#
+# Check the existence of the libraries.
+#
+############################################
+# This macro was taken directly from the FindQt4.cmake file that is included
+# with the CMake distribution. This is NOT my work. All work was done by the
+# original authors of the FindQt4.cmake file. Only minor modifications were
+# made to remove references to Qt and make this file more generally applicable
+#########################################################################
+
+MACRO (SZIP_ADJUST_LIB_VARS basename)
+  if (${basename}_INCLUDE_DIR)
+
+    # if only the release version was found, set the debug variable also to the release version
+    if (${basename}_LIBRARY_RELEASE AND NOT ${basename}_LIBRARY_DEBUG)
+      set (${basename}_LIBRARY_DEBUG ${${basename}_LIBRARY_RELEASE})
+      set (${basename}_LIBRARY       ${${basename}_LIBRARY_RELEASE})
+      set (${basename}_LIBRARIES     ${${basename}_LIBRARY_RELEASE})
+    endif (${basename}_LIBRARY_RELEASE AND NOT ${basename}_LIBRARY_DEBUG)
+
+    # if only the debug version was found, set the release variable also to the debug version
+    if (${basename}_LIBRARY_DEBUG AND NOT ${basename}_LIBRARY_RELEASE)
+      set (${basename}_LIBRARY_RELEASE ${${basename}_LIBRARY_DEBUG})
+      set (${basename}_LIBRARY         ${${basename}_LIBRARY_DEBUG})
+      set (${basename}_LIBRARIES       ${${basename}_LIBRARY_DEBUG})
+    endif (${basename}_LIBRARY_DEBUG AND NOT ${basename}_LIBRARY_RELEASE)
+    if (${basename}_LIBRARY_DEBUG AND ${basename}_LIBRARY_RELEASE)
+      # if the generator supports configuration types then set
+      # optimized and debug libraries, or if the CMAKE_BUILD_TYPE has a value
+      if (CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE)
+        set (${basename}_LIBRARY       optimized ${${basename}_LIBRARY_RELEASE} debug ${${basename}_LIBRARY_DEBUG})
+      else (CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE)
+        # if there are no configuration types and CMAKE_BUILD_TYPE has no value
+        # then just use the release libraries
+        set (${basename}_LIBRARY       ${${basename}_LIBRARY_RELEASE} )
+      endif (CMAKE_CONFIGURATION_TYPES OR CMAKE_BUILD_TYPE)
+      set (${basename}_LIBRARIES       optimized ${${basename}_LIBRARY_RELEASE} debug ${${basename}_LIBRARY_DEBUG})
+    endif (${basename}_LIBRARY_DEBUG AND ${basename}_LIBRARY_RELEASE)
+
+    set (${basename}_LIBRARY ${${basename}_LIBRARY} CACHE FILEPATH "The ${basename} library")
+
+    if (${basename}_LIBRARY)
+      set (${basename}_FOUND 1)
+    endif (${basename}_LIBRARY)
+
+  endif (${basename}_INCLUDE_DIR )
+
+  # Make variables changeble to the advanced user
+  MARK_AS_ADVANCED (${basename}_LIBRARY ${basename}_LIBRARY_RELEASE ${basename}_LIBRARY_DEBUG ${basename}_INCLUDE_DIR )
+ENDMACRO (SZIP_ADJUST_LIB_VARS)
+
+
+# Look for the header file.
+set (SZIP_INCLUDE_SEARCH_DIRS
+    $ENV{SZIP_INSTALL}/include
+    $ENV{SZIP_INSTALL}/include/szip
+    /usr/include
+    /usr/include/szip
+)
+
+set (SZIP_LIB_SEARCH_DIRS
+    $ENV{SZIP_INSTALL}/lib
+    /usr/lib
+)
+
+set (SZIP_BIN_SEARCH_DIRS
+    $ENV{SZIP_INSTALL}/bin
+    /usr/bin
+)
+
+FIND_PATH (SZIP_INCLUDE_DIR
+    NAMES szlib.h
+    PATHS ${SZIP_INCLUDE_SEARCH_DIRS}
+    NO_DEFAULT_PATH
+)
+
+if (WIN32)
+    set (SZIP_SEARCH_DEBUG_NAMES "sz_d;libsz_d")
+    set (SZIP_SEARCH_RELEASE_NAMES "sz;libsz;libszip")
+else (WIN32)
+    set (SZIP_SEARCH_DEBUG_NAMES "sz_d")
+    set (SZIP_SEARCH_RELEASE_NAMES "sz;szip")
+endif (WIN32)
+
+# Look for the library.
+FIND_LIBRARY (SZIP_LIBRARY_DEBUG
+    NAMES ${SZIP_SEARCH_DEBUG_NAMES}
+    PATHS ${SZIP_LIB_SEARCH_DIRS}
+    NO_DEFAULT_PATH
+)
+
+FIND_LIBRARY (SZIP_LIBRARY_RELEASE
+    NAMES ${SZIP_SEARCH_RELEASE_NAMES}
+    PATHS ${SZIP_LIB_SEARCH_DIRS}
+    NO_DEFAULT_PATH
+)
+
+SZIP_ADJUST_LIB_VARS (SZIP)
+
+if (SZIP_INCLUDE_DIR AND SZIP_LIBRARY)
+  set (SZIP_FOUND 1)
+  set (SZIP_LIBRARIES ${SZIP_LIBRARY})
+  set (SZIP_INCLUDE_DIRS ${SZIP_INCLUDE_DIR})
+  if (SZIP_LIBRARY_DEBUG)
+    get_filename_component (SZIP_LIBRARY_PATH ${SZIP_LIBRARY_DEBUG} PATH)
+    set (SZIP_LIB_DIR  ${SZIP_LIBRARY_PATH})
+  elseif (SZIP_LIBRARY_RELEASE)
+    get_filename_component (SZIP_LIBRARY_PATH ${SZIP_LIBRARY_RELEASE} PATH)
+    set (SZIP_LIB_DIR  ${SZIP_LIBRARY_PATH})
+  endif (SZIP_LIBRARY_DEBUG)
+
+else (SZIP_INCLUDE_DIR AND SZIP_LIBRARY)
+  set (SZIP_FOUND 0)
+  set (SZIP_LIBRARIES)
+  set (SZIP_INCLUDE_DIRS)
+endif (SZIP_INCLUDE_DIR AND SZIP_LIBRARY)
+
+# Report the results.
+if (NOT SZIP_FOUND)
+  set (SZIP_DIR_MESSAGE
+      "SZip was not found. Make sure SZIP_LIBRARY and SZIP_INCLUDE_DIR are set or set the SZIP_INSTALL environment variable."
+  )
+  if (NOT SZIP_FIND_QUIETLY)
+    message (STATUS "${SZIP_DIR_MESSAGE}")
+  else (NOT SZIP_FIND_QUIETLY)
+    if (SZIP_FIND_REQUIRED)
+      message (FATAL_ERROR "SZip was NOT found and is Required by this project")
+    endif (SZIP_FIND_REQUIRED)
+  endif (NOT SZIP_FIND_QUIETLY)
+endif (NOT SZIP_FOUND)
+
+if (SZIP_FOUND)
+  include (CheckSymbolExists)
+  #############################################
+  # Find out if SZIP was build using dll's
+  #############################################
+  # Save required variable
+  set (CMAKE_REQUIRED_INCLUDES_SAVE ${CMAKE_REQUIRED_INCLUDES})
+  set (CMAKE_REQUIRED_FLAGS_SAVE    ${CMAKE_REQUIRED_FLAGS})
+  # Add SZIP_INCLUDE_DIR to CMAKE_REQUIRED_INCLUDES
+  set (CMAKE_REQUIRED_INCLUDES "${CMAKE_REQUIRED_INCLUDES};${SZIP_INCLUDE_DIRS}")
+
+  CHECK_SYMBOL_EXISTS (SZIP_BUILT_AS_DYNAMIC_LIB "SZconfig.h" HAVE_SZIP_DLL)
+
+  if (HAVE_SZIP_DLL STREQUAL "TRUE")
+    set (HAVE_SZIP_DLL "1")
+  endif (HAVE_SZIP_DLL STREQUAL "TRUE")
+
+  # Restore CMAKE_REQUIRED_INCLUDES and CMAKE_REQUIRED_FLAGS variables
+  set (CMAKE_REQUIRED_INCLUDES ${CMAKE_REQUIRED_INCLUDES_SAVE})
+  set (CMAKE_REQUIRED_FLAGS    ${CMAKE_REQUIRED_FLAGS_SAVE})
+  #
+  #############################################
+endif (SZIP_FOUND)
+
+if (FIND_SZIP_DEBUG)
+  message (STATUS "SZIP_INCLUDE_DIR: ${SZIP_INCLUDE_DIR}")
+  message (STATUS "SZIP_INCLUDE_DIRS: ${SZIP_INCLUDE_DIRS}")
+  message (STATUS "SZIP_LIBRARY_DEBUG: ${SZIP_LIBRARY_DEBUG}")
+  message (STATUS "SZIP_LIBRARY_RELEASE: ${SZIP_LIBRARY_RELEASE}")
+  message (STATUS "HAVE_SZIP_DLL: ${HAVE_SZIP_DLL}")
+  message (STATUS "CMAKE_BUILD_TYPE: ${CMAKE_BUILD_TYPE}")
+endif (FIND_SZIP_DEBUG)
diff --git a/config/cmake_ext_mod/GetTimeOfDayTest.cpp b/config/cmake_ext_mod/GetTimeOfDayTest.cpp
new file mode 100644
index 0000000..3b5bf60
--- /dev/null
+++ b/config/cmake_ext_mod/GetTimeOfDayTest.cpp
@@ -0,0 +1,15 @@
+#if defined (TRY_SYS_TIME_H)
+#include <sys/time.h>
+/* #include <time.h> */
+#endif
+
+
+#if defined (TRY_TIME_H)
+#include <time.h>
+#endif
+
+int main(int argc, char **argv) {
+	  struct timeval t1;
+	  gettimeofday(&t1, 0x00);
+	return 0;
+}
diff --git a/config/cmake_ext_mod/HDFCXXTests.cpp b/config/cmake_ext_mod/HDFCXXTests.cpp
new file mode 100644
index 0000000..6b47421
--- /dev/null
+++ b/config/cmake_ext_mod/HDFCXXTests.cpp
@@ -0,0 +1,56 @@
+
+#ifdef OLD_HEADER_FILENAME
+
+#include <iostream>
+
+int main(void) { return 0; }
+
+#endif
+
+
+#ifdef HDF_NO_NAMESPACE
+
+namespace HDF {
+int fnord;
+}
+
+int main(void) {
+   using namespace HDF;
+   fnord = 37;
+   return 0;
+}
+
+#endif
+
+#ifdef HDF_NO_STD
+
+#include <string>
+
+using namespace std;
+
+int main(void) {
+   string myString("testing namespace std");
+   return 0;
+}
+
+#endif
+
+#ifdef BOOL_NOTDEFINED
+int main(void) {
+   bool flag;
+   return 0;
+}
+
+#endif
+
+#ifdef NO_STATIC_CAST
+
+int main(void) {
+   float test_float;
+   int test_int;
+   test_float = 37.0;
+   test_int = static_cast <int> (test_float);
+   return 0;
+}
+
+#endif
diff --git a/config/cmake_ext_mod/HDFLibMacros.cmake b/config/cmake_ext_mod/HDFLibMacros.cmake
new file mode 100644
index 0000000..f499b00
--- /dev/null
+++ b/config/cmake_ext_mod/HDFLibMacros.cmake
@@ -0,0 +1,249 @@
+#-------------------------------------------------------------------------------
+MACRO (EXTERNAL_JPEG_LIBRARY compress_type libtype jpeg_pic)
+  # May need to build JPEG with PIC on x64 machines with gcc
+  # Need to use CMAKE_ANSI_CFLAGS define so that compiler test works
+
+  if (${compress_type} MATCHES "SVN")
+    EXTERNALPROJECT_ADD (JPEG
+        SVN_REPOSITORY ${JPEG_URL}
+        # [SVN_REVISION rev] 
+        INSTALL_COMMAND ""
+        CMAKE_ARGS
+            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
+            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
+            -DJPEG_EXTERNALLY_CONFIGURED:BOOL=OFF
+            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
+            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
+            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
+            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
+            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
+            -DCMAKE_ANSI_CFLAGS:STRING=${jpeg_pic}
+    ) 
+  elseif (${compress_type} MATCHES "GIT")
+    EXTERNALPROJECT_ADD (JPEG
+        GIT_REPOSITORY ${JPEG_URL}
+        INSTALL_COMMAND ""
+        CMAKE_ARGS
+            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
+            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
+            -DJPEG_EXTERNALLY_CONFIGURED:BOOL=OFF
+            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
+            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
+            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
+            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
+            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
+            -DCMAKE_ANSI_CFLAGS:STRING=${jpeg_pic}
+    ) 
+  elseif (${compress_type} MATCHES "TGZ")
+    EXTERNALPROJECT_ADD (JPEG
+        URL ${JPEG_URL}
+        URL_MD5 ""
+        INSTALL_COMMAND ""
+        CMAKE_ARGS
+            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
+            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
+            -DJPEG_EXTERNALLY_CONFIGURED:BOOL=OFF
+            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
+            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
+            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
+            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
+            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
+            -DCMAKE_ANSI_CFLAGS:STRING=${jpeg_pic}
+    ) 
+  endif (${compress_type} MATCHES "SVN")
+  externalproject_get_property (JPEG BINARY_DIR SOURCE_DIR) 
+
+  # Create imported target szip
+  add_library (jpeg ${libtype} IMPORTED)
+  HDF_IMPORT_SET_LIB_OPTIONS (jpeg "jpeg" ${libtype} "")
+  add_dependencies (JPEG jpeg)
+
+#  include (${BINARY_DIR}/JPEG-targets.cmake)  
+  set (JPEG_LIBRARY "jpeg")
+  
+  set (JPEG_INCLUDE_DIR_GEN "${BINARY_DIR}")
+  set (JPEG_INCLUDE_DIR "${SOURCE_DIR}/src")
+  set (JPEG_FOUND 1)
+  set (JPEG_LIBRARIES ${JPEG_LIBRARY})
+  set (JPEG_INCLUDE_DIRS ${JPEG_INCLUDE_DIR_GEN} ${JPEG_INCLUDE_DIR})
+ENDMACRO (EXTERNAL_JPEG_LIBRARY)
+
+#-------------------------------------------------------------------------------
+MACRO (PACKAGE_JPEG_LIBRARY compress_type)
+  add_custom_target (JPEG-GenHeader-Copy ALL
+      COMMAND ${CMAKE_COMMAND} -E copy_if_different ${JPEG_INCLUDE_DIR_GEN}/jconfig.h ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/
+      COMMENT "Copying ${JPEG_INCLUDE_DIR_GEN}/jconfig.h to ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/"
+  )
+  set (EXTERNAL_HEADER_LIST ${EXTERNAL_HEADER_LIST} ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/jconfig.h)
+  if (${compress_type} MATCHES "SVN" OR ${compress_type} MATCHES "TGZ")
+    add_dependencies (JPEG-GenHeader-Copy JPEG)
+  endif (${compress_type} MATCHES "SVN" OR ${compress_type} MATCHES "TGZ")
+ENDMACRO (PACKAGE_JPEG_LIBRARY)
+
+#-------------------------------------------------------------------------------
+MACRO (EXTERNAL_SZIP_LIBRARY compress_type libtype encoding)
+  if (${compress_type} MATCHES "SVN")
+    EXTERNALPROJECT_ADD (SZIP
+        SVN_REPOSITORY ${SZIP_URL}
+        # [SVN_REVISION rev] 
+        INSTALL_COMMAND ""
+        CMAKE_ARGS
+            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
+            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
+            -DSZIP_EXTERNALLY_CONFIGURED:BOOL=OFF
+            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
+            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
+            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
+            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
+            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
+            -DCMAKE_ANSI_CFLAGS:STRING=${CMAKE_ANSI_CFLAGS}
+            -DSZIP_ENABLE_ENCODING:BOOL=${encoding}
+    ) 
+  elseif (${compress_type} MATCHES "GIT")
+    EXTERNALPROJECT_ADD (SZIP
+        GIT_REPOSITORY ${SZIP_URL}
+        # [SVN_REVISION rev] 
+        INSTALL_COMMAND ""
+        CMAKE_ARGS
+            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
+            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
+            -DSZIP_EXTERNALLY_CONFIGURED:BOOL=OFF
+            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
+            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
+            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
+            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
+            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
+            -DCMAKE_ANSI_CFLAGS:STRING=${CMAKE_ANSI_CFLAGS}
+            -DSZIP_ENABLE_ENCODING:BOOL=${encoding}
+    ) 
+  elseif (${compress_type} MATCHES "TGZ")
+    EXTERNALPROJECT_ADD (SZIP
+        URL ${SZIP_URL}
+        URL_MD5 ""
+        INSTALL_COMMAND ""
+        CMAKE_ARGS
+            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
+            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
+            -DSZIP_EXTERNALLY_CONFIGURED:BOOL=OFF
+            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
+            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
+            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
+            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
+            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
+            -DCMAKE_ANSI_CFLAGS:STRING=${CMAKE_ANSI_CFLAGS}
+            -DSZIP_ENABLE_ENCODING:BOOL=${encoding}
+    ) 
+  endif (${compress_type} MATCHES "SVN")
+  externalproject_get_property (SZIP BINARY_DIR SOURCE_DIR) 
+
+  # Create imported target szip
+  add_library (szip ${libtype} IMPORTED)
+  HDF_IMPORT_SET_LIB_OPTIONS (szip "szip" ${libtype} "")
+  add_dependencies (SZIP szip)
+
+#  include (${BINARY_DIR}/SZIP-targets.cmake)  
+  set (SZIP_LIBRARY "szip")
+
+  set (SZIP_INCLUDE_DIR_GEN "${BINARY_DIR}")
+  set (SZIP_INCLUDE_DIR "${SOURCE_DIR}/src")
+  set (SZIP_FOUND 1)
+  set (SZIP_LIBRARIES ${SZIP_LIBRARY})
+  set (SZIP_INCLUDE_DIRS ${SZIP_INCLUDE_DIR_GEN} ${SZIP_INCLUDE_DIR})
+ENDMACRO (EXTERNAL_SZIP_LIBRARY)
+
+#-------------------------------------------------------------------------------
+MACRO (PACKAGE_SZIP_LIBRARY compress_type)
+  add_custom_target (SZIP-GenHeader-Copy ALL
+      COMMAND ${CMAKE_COMMAND} -E copy_if_different ${SZIP_INCLUDE_DIR_GEN}/SZconfig.h ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/
+      COMMENT "Copying ${SZIP_INCLUDE_DIR_GEN}/SZconfig.h to ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/"
+  )
+  set (EXTERNAL_HEADER_LIST ${EXTERNAL_HEADER_LIST} ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/SZconfig.h)
+  if (${compress_type} MATCHES "SVN" OR ${compress_type} MATCHES "TGZ")
+    add_dependencies (SZIP-GenHeader-Copy SZIP)
+  endif (${compress_type} MATCHES "SVN" OR ${compress_type} MATCHES "TGZ")
+ENDMACRO (PACKAGE_SZIP_LIBRARY)
+
+#-------------------------------------------------------------------------------
+MACRO (EXTERNAL_ZLIB_LIBRARY compress_type libtype)
+  if (${compress_type} MATCHES "SVN")
+    EXTERNALPROJECT_ADD (ZLIB
+        SVN_REPOSITORY ${ZLIB_URL}
+        # [SVN_REVISION rev] 
+        INSTALL_COMMAND ""
+        CMAKE_ARGS
+            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
+            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
+            -DZLIB_EXTERNALLY_CONFIGURED:BOOL=OFF
+            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
+            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
+            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
+            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
+            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
+            -DCMAKE_ANSI_CFLAGS:STRING=${CMAKE_ANSI_CFLAGS}
+    ) 
+  elseif (${compress_type} MATCHES "GIT")
+    EXTERNALPROJECT_ADD (ZLIB
+        GIT_REPOSITORY ${ZLIB_URL}
+        # [SVN_REVISION rev] 
+        INSTALL_COMMAND ""
+        CMAKE_ARGS
+            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
+            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
+            -DZLIB_EXTERNALLY_CONFIGURED:BOOL=OFF
+            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
+            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
+            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
+            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
+            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
+            -DCMAKE_ANSI_CFLAGS:STRING=${CMAKE_ANSI_CFLAGS}
+    ) 
+  elseif (${compress_type} MATCHES "TGZ")
+    EXTERNALPROJECT_ADD (ZLIB
+        URL ${ZLIB_URL}
+        URL_MD5 ""
+        INSTALL_COMMAND ""
+        CMAKE_ARGS
+            -DBUILD_SHARED_LIBS:BOOL=${BUILD_SHARED_LIBS}
+            -DHDF_PACKAGE_EXT:STRING=${HDF_PACKAGE_EXT}
+            -DZLIB_EXTERNALLY_CONFIGURED:BOOL=OFF
+            -DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
+            -DCMAKE_INSTALL_PREFIX:PATH=${CMAKE_INSTALL_PREFIX}
+            -DCMAKE_RUNTIME_OUTPUT_DIRECTORY:PATH=${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
+            -DCMAKE_LIBRARY_OUTPUT_DIRECTORY:PATH=${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
+            -DCMAKE_ARCHIVE_OUTPUT_DIRECTORY:PATH=${CMAKE_ARCHIVE_OUTPUT_DIRECTORY}
+            -DCMAKE_ANSI_CFLAGS:STRING=${CMAKE_ANSI_CFLAGS}
+    ) 
+  endif (${compress_type} MATCHES "SVN")
+  externalproject_get_property (ZLIB BINARY_DIR SOURCE_DIR) 
+
+  # Create imported target zlib
+  add_library (zlib ${libtype} IMPORTED)
+  if (WIN32)
+    set (ZLIB_LIB_NAME "zlib")
+  else (WIN32)
+    set (ZLIB_LIB_NAME "z")
+  endif (WIN32)
+  HDF_IMPORT_SET_LIB_OPTIONS (zlib ${ZLIB_LIB_NAME} ${libtype} "")
+  add_dependencies (ZLIB zlib)
+
+#  include (${BINARY_DIR}/ZLIB-targets.cmake)  
+  set (ZLIB_LIBRARY "zlib")
+  
+  set (ZLIB_INCLUDE_DIR_GEN "${BINARY_DIR}")
+  set (ZLIB_INCLUDE_DIR "${SOURCE_DIR}")
+  set (ZLIB_FOUND 1)
+  set (ZLIB_LIBRARIES ${ZLIB_LIBRARY})
+  set (ZLIB_INCLUDE_DIRS ${ZLIB_INCLUDE_DIR_GEN} ${ZLIB_INCLUDE_DIR})
+ENDMACRO (EXTERNAL_ZLIB_LIBRARY)
+
+#-------------------------------------------------------------------------------
+MACRO (PACKAGE_ZLIB_LIBRARY compress_type)
+  add_custom_target (ZLIB-GenHeader-Copy ALL
+      COMMAND ${CMAKE_COMMAND} -E copy_if_different ${ZLIB_INCLUDE_DIR_GEN}/zconf.h ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/
+      COMMENT "Copying ${ZLIB_INCLUDE_DIR_GEN}/zconf.h to ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/"
+  )
+  set (EXTERNAL_HEADER_LIST ${EXTERNAL_HEADER_LIST} ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}/zconf.h)
+  if (${compress_type} MATCHES "SVN" OR ${compress_type} MATCHES "TGZ")
+    add_dependencies (ZLIB-GenHeader-Copy ZLIB)
+  endif (${compress_type} MATCHES "SVN" OR ${compress_type} MATCHES "TGZ")
+ENDMACRO (PACKAGE_ZLIB_LIBRARY)
diff --git a/config/cmake_ext_mod/HDFMacros.cmake b/config/cmake_ext_mod/HDFMacros.cmake
new file mode 100644
index 0000000..f6e9b91
--- /dev/null
+++ b/config/cmake_ext_mod/HDFMacros.cmake
@@ -0,0 +1,288 @@
+#-------------------------------------------------------------------------------
+MACRO (SET_GLOBAL_VARIABLE name value)
+  set (${name} ${value} CACHE INTERNAL "Used to pass variables between directories" FORCE)
+ENDMACRO (SET_GLOBAL_VARIABLE)
+
+#-------------------------------------------------------------------------------
+MACRO (IDE_GENERATED_PROPERTIES SOURCE_PATH HEADERS SOURCES)
+  #set(source_group_path "Source/AIM/${NAME}")
+  string (REPLACE "/" "\\\\" source_group_path ${SOURCE_PATH})
+  source_group (${source_group_path} FILES ${HEADERS} ${SOURCES})
+
+  #-- The following is needed if we ever start to use OS X Frameworks but only
+  #--  works on CMake 2.6 and greater
+  #set_property (SOURCE ${HEADERS}
+  #       PROPERTY MACOSX_PACKAGE_LOCATION Headers/${NAME}
+  #)
+ENDMACRO (IDE_GENERATED_PROPERTIES)
+
+#-------------------------------------------------------------------------------
+MACRO (IDE_SOURCE_PROPERTIES SOURCE_PATH HEADERS SOURCES)
+  #  install (FILES ${HEADERS}
+  #       DESTINATION include/R3D/${NAME}
+  #       COMPONENT Headers       
+  #  )
+
+  string (REPLACE "/" "\\\\" source_group_path ${SOURCE_PATH}  )
+  source_group (${source_group_path} FILES ${HEADERS} ${SOURCES})
+
+  #-- The following is needed if we ever start to use OS X Frameworks but only
+  #--  works on CMake 2.6 and greater
+  #set_property (SOURCE ${HEADERS}
+  #       PROPERTY MACOSX_PACKAGE_LOCATION Headers/${NAME}
+  #)
+ENDMACRO (IDE_SOURCE_PROPERTIES)
+
+#-------------------------------------------------------------------------------
+MACRO (TARGET_NAMING libtarget libtype)
+  if (WIN32)
+    if (${libtype} MATCHES "SHARED")
+      set_target_properties (${libtarget} PROPERTIES OUTPUT_NAME "${libtarget}dll")
+    endif (${libtype} MATCHES "SHARED")
+  endif (WIN32)
+ENDMACRO (TARGET_NAMING)
+
+#-------------------------------------------------------------------------------
+MACRO (INSTALL_TARGET_PDB libtarget targetdestination targetcomponent)
+  if (WIN32 AND MSVC)
+    get_target_property (target_name ${libtarget} OUTPUT_NAME_RELWITHDEBINFO)
+    install (
+      FILES
+          ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${CMAKE_IMPORT_LIBRARY_PREFIX}${target_name}.pdb
+      DESTINATION
+          ${targetdestination}
+      CONFIGURATIONS RelWithDebInfo
+      COMPONENT ${targetcomponent}
+  )
+  endif (WIN32 AND MSVC)
+ENDMACRO (INSTALL_TARGET_PDB)
+
+#-------------------------------------------------------------------------------
+MACRO (INSTALL_PROGRAM_PDB progtarget targetdestination targetcomponent)
+  if (WIN32 AND MSVC)
+    get_target_property (target_name ${progtarget} OUTPUT_NAME_RELWITHDEBINFO)
+    get_target_property (target_prefix ${progtarget} PREFIX)
+    install (
+      FILES
+          ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${target_prefix}${target_name}.pdb
+      DESTINATION
+          ${targetdestination}
+      CONFIGURATIONS RelWithDebInfo
+      COMPONENT ${targetcomponent}
+  )
+  endif (WIN32 AND MSVC)
+ENDMACRO (INSTALL_PROGRAM_PDB)
+
+#-------------------------------------------------------------------------------
+MACRO (HDF_SET_LIB_OPTIONS libtarget libname libtype)
+  if (${libtype} MATCHES "SHARED")
+    if (WIN32)
+      set (LIB_RELEASE_NAME "${libname}")
+      set (LIB_DEBUG_NAME "${libname}_D")
+    else (WIN32)
+      set (LIB_RELEASE_NAME "${libname}")
+      set (LIB_DEBUG_NAME "${libname}_debug")
+    endif (WIN32)
+  else (${libtype} MATCHES "SHARED")
+    if (WIN32)
+      set (LIB_RELEASE_NAME "lib${libname}")
+      set (LIB_DEBUG_NAME "lib${libname}_D")
+    else (WIN32)
+      set (LIB_RELEASE_NAME "${libname}")
+      set (LIB_DEBUG_NAME "${libname}_debug")
+    endif (WIN32)
+  endif (${libtype} MATCHES "SHARED")
+  
+  set_target_properties (${libtarget}
+      PROPERTIES
+      OUTPUT_NAME_DEBUG          ${LIB_DEBUG_NAME}
+      OUTPUT_NAME_RELEASE        ${LIB_RELEASE_NAME}
+      OUTPUT_NAME_MINSIZEREL     ${LIB_RELEASE_NAME}
+      OUTPUT_NAME_RELWITHDEBINFO ${LIB_RELEASE_NAME}
+  )
+  
+  #----- Use MSVC Naming conventions for Shared Libraries
+  if (MINGW AND ${libtype} MATCHES "SHARED")
+    set_target_properties (${libtarget}
+        PROPERTIES
+        IMPORT_SUFFIX ".lib"
+        IMPORT_PREFIX ""
+        PREFIX ""
+    )
+  endif (MINGW AND ${libtype} MATCHES "SHARED")
+
+ENDMACRO (HDF_SET_LIB_OPTIONS)
+
+#-------------------------------------------------------------------------------
+MACRO (HDF_IMPORT_SET_LIB_OPTIONS libtarget libname libtype libversion)
+  HDF_SET_LIB_OPTIONS (${libtarget} ${libname} ${libtype})
+
+  if (${importtype} MATCHES "IMPORT")
+    set (importprefix "${CMAKE_STATIC_LIBRARY_PREFIX}")
+  endif (${importtype} MATCHES "IMPORT")
+  if (${CMAKE_BUILD_TYPE} MATCHES "Debug")
+    set (IMPORT_LIB_NAME ${LIB_DEBUG_NAME})
+  else (${CMAKE_BUILD_TYPE} MATCHES "Debug")
+    set (IMPORT_LIB_NAME ${LIB_RELEASE_NAME})
+  endif (${CMAKE_BUILD_TYPE} MATCHES "Debug")
+
+  if (${libtype} MATCHES "SHARED")
+    if (WIN32)
+      if (MINGW)
+        set_target_properties (${libtarget} PROPERTIES
+            IMPORTED_IMPLIB "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${IMPORT_LIB_NAME}.lib"
+            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${IMPORT_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
+        )
+      else (MINGW)
+        set_target_properties (${libtarget} PROPERTIES
+            IMPORTED_IMPLIB "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${CMAKE_IMPORT_LIBRARY_PREFIX}${IMPORT_LIB_NAME}${CMAKE_IMPORT_LIBRARY_SUFFIX}"
+            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${CMAKE_IMPORT_LIBRARY_PREFIX}${IMPORT_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
+         )
+      endif (MINGW)
+    else (WIN32)
+      if (CYGWIN)
+        set_target_properties (${libtarget} PROPERTIES
+            IMPORTED_IMPLIB "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_IMPORT_LIBRARY_PREFIX}${IMPORT_LIB_NAME}${CMAKE_IMPORT_LIBRARY_SUFFIX}"
+            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_IMPORT_LIBRARY_PREFIX}${IMPORT_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
+        )
+      else (CYGWIN)
+        set_target_properties (${libtarget} PROPERTIES
+            IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_SHARED_LIBRARY_PREFIX}${IMPORT_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}"
+            IMPORTED_SONAME "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_SHARED_LIBRARY_PREFIX}${IMPORT_LIB_NAME}${CMAKE_SHARED_LIBRARY_SUFFIX}.${libversion}"
+            SOVERSION "${libversion}"
+        )
+      endif (CYGWIN)
+    endif (WIN32)
+  else (${libtype} MATCHES "SHARED")
+    if (WIN32 AND NOT MINGW)
+      set_target_properties (${libtarget} PROPERTIES
+          IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_BUILD_TYPE}/${IMPORT_LIB_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX}"
+          IMPORTED_LINK_INTERFACE_LANGUAGES "C"
+      )
+    else (WIN32 AND NOT MINGW)
+      set_target_properties (${libtarget} PROPERTIES
+          IMPORTED_LOCATION "${CMAKE_LIBRARY_OUTPUT_DIRECTORY}/${CMAKE_STATIC_LIBRARY_PREFIX}${IMPORT_LIB_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX}"
+          IMPORTED_LINK_INTERFACE_LANGUAGES "C"
+      )
+    endif (WIN32 AND NOT MINGW)
+  endif (${libtype} MATCHES "SHARED")
+
+ENDMACRO (HDF_IMPORT_SET_LIB_OPTIONS)
+
+#-------------------------------------------------------------------------------
+MACRO (TARGET_C_PROPERTIES wintarget addcompileflags addlinkflags)
+  if (MSVC)
+    TARGET_MSVC_PROPERTIES (${wintarget} "${addcompileflags} ${WIN_COMPILE_FLAGS}" "${addlinkflags} ${WIN_LINK_FLAGS}")
+  else (MSVC)
+    if (BUILD_SHARED_LIBS)
+      set_target_properties (${wintarget}
+          PROPERTIES
+              COMPILE_FLAGS "${addcompileflags}"
+              LINK_FLAGS "${addlinkflags}"
+      ) 
+    else (BUILD_SHARED_LIBS)
+      set_target_properties (${wintarget}
+          PROPERTIES
+              COMPILE_FLAGS "${addcompileflags}"
+              LINK_FLAGS "${addlinkflags}"
+      ) 
+    endif (BUILD_SHARED_LIBS)
+  endif (MSVC)
+ENDMACRO (TARGET_C_PROPERTIES)
+
+#-------------------------------------------------------------------------------
+MACRO (TARGET_MSVC_PROPERTIES wintarget addcompileflags addlinkflags)
+  if (MSVC)
+    if (BUILD_SHARED_LIBS)
+      set_target_properties (${wintarget}
+          PROPERTIES
+              COMPILE_FLAGS "${addcompileflags}"
+              LINK_FLAGS "${addlinkflags}"
+      ) 
+    else (BUILD_SHARED_LIBS)
+      set_target_properties (${wintarget}
+          PROPERTIES
+              COMPILE_FLAGS "${addcompileflags}"
+              LINK_FLAGS "${addlinkflags}"
+      ) 
+    endif (BUILD_SHARED_LIBS)
+  endif (MSVC)
+ENDMACRO (TARGET_MSVC_PROPERTIES)
+
+#-------------------------------------------------------------------------------
+MACRO (TARGET_FORTRAN_PROPERTIES forttarget addcompileflags addlinkflags)
+  if (WIN32)
+    TARGET_FORTRAN_WIN_PROPERTIES (${forttarget} "${addcompileflags} ${WIN_COMPILE_FLAGS}" "${addlinkflags} ${WIN_LINK_FLAGS}")
+  endif (WIN32)
+ENDMACRO (TARGET_FORTRAN_PROPERTIES)
+
+#-------------------------------------------------------------------------------
+MACRO (TARGET_FORTRAN_WIN_PROPERTIES forttarget addcompileflags addlinkflags)
+  if (MSVC)
+    if (BUILD_SHARED_LIBS)
+      set_target_properties (${forttarget}
+          PROPERTIES
+              COMPILE_FLAGS "/dll ${addcompileflags}"
+              LINK_FLAGS "/SUBSYSTEM:CONSOLE ${addlinkflags}"
+      ) 
+    else (BUILD_SHARED_LIBS)
+      set_target_properties (${forttarget}
+          PROPERTIES
+              COMPILE_FLAGS "${addcompileflags}"
+              LINK_FLAGS "/SUBSYSTEM:CONSOLE ${addlinkflags}"
+      ) 
+    endif (BUILD_SHARED_LIBS)
+  endif (MSVC)
+ENDMACRO (TARGET_FORTRAN_WIN_PROPERTIES)
+
+#-----------------------------------------------------------------------------
+# Configure the README.txt file for the binary package
+#-----------------------------------------------------------------------------
+MACRO (HDF_README_PROPERTIES target_fortran)
+  set (BINARY_SYSTEM_NAME ${CMAKE_SYSTEM_NAME})
+  set (BINARY_PLATFORM "${CMAKE_SYSTEM_NAME}")
+  if (WIN32)
+    set (BINARY_EXAMPLE_ENDING "zip")
+    set (BINARY_INSTALL_ENDING "exe")
+    if (CMAKE_CL_64)
+      set (BINARY_SYSTEM_NAME "win64")
+    else (CMAKE_CL_64)
+      set (BINARY_SYSTEM_NAME "win32")
+    endif (CMAKE_CL_64)
+    if (${CMAKE_SYSTEM_VERSION} MATCHES "6.1")
+      set (BINARY_PLATFORM "${BINARY_PLATFORM} 7")
+    elseif (${CMAKE_SYSTEM_VERSION} MATCHES "6.2")
+      set (BINARY_PLATFORM "${BINARY_PLATFORM} 8")
+    endif (${CMAKE_SYSTEM_VERSION} MATCHES "6.1")
+    set (BINARY_PLATFORM "${BINARY_PLATFORM} ${MSVC_C_ARCHITECTURE_ID}")
+    if (${CMAKE_C_COMPILER_VERSION} MATCHES "16.*")
+      set (BINARY_PLATFORM "${BINARY_PLATFORM}, using VISUAL STUDIO 2010")
+    elseif (${CMAKE_C_COMPILER_VERSION} MATCHES "15.*")
+      set (BINARY_PLATFORM "${BINARY_PLATFORM}, using VISUAL STUDIO 2008")
+    elseif (${CMAKE_C_COMPILER_VERSION} MATCHES "17.*")
+      set (BINARY_PLATFORM "${BINARY_PLATFORM}, using VISUAL STUDIO 2012")
+    elseif (${CMAKE_C_COMPILER_VERSION} MATCHES "18.*")
+      set (BINARY_PLATFORM "${BINARY_PLATFORM}, using VISUAL STUDIO 2013")
+    else (${CMAKE_C_COMPILER_VERSION} MATCHES "16.*")
+      set (BINARY_PLATFORM "${BINARY_PLATFORM}, using VISUAL STUDIO ${CMAKE_C_COMPILER_VERSION}")
+    endif (${CMAKE_C_COMPILER_VERSION} MATCHES "16.*")
+  elseif (APPLE)
+    set (BINARY_EXAMPLE_ENDING "tar.gz")
+    set (BINARY_INSTALL_ENDING "dmg")
+    set (BINARY_PLATFORM "${BINARY_PLATFORM} ${CMAKE_SYSTEM_VERSION} ${CMAKE_SYSTEM_PROCESSOR}")
+    set (BINARY_PLATFORM "${BINARY_PLATFORM}, using ${CMAKE_C_COMPILER_ID} C ${CMAKE_C_COMPILER_VERSION}")
+  else (WIN32)
+    set (BINARY_EXAMPLE_ENDING "tar.gz")
+    set (BINARY_INSTALL_ENDING "sh")
+    set (BINARY_PLATFORM "${BINARY_PLATFORM} ${CMAKE_SYSTEM_VERSION} ${CMAKE_SYSTEM_PROCESSOR}")
+    set (BINARY_PLATFORM "${BINARY_PLATFORM}, using ${CMAKE_C_COMPILER_ID} C ${CMAKE_C_COMPILER_VERSION}")
+  endif (WIN32)
+  if (target_fortran)
+    set (BINARY_PLATFORM "${BINARY_PLATFORM} / ${CMAKE_Fortran_COMPILER_ID} Fortran")
+  endif (target_fortran)
+    
+  configure_file (
+      ${HDF_RESOURCES_DIR}/README.txt.cmake.in 
+      ${CMAKE_BINARY_DIR}/README.txt @ONLY
+  )
+ENDMACRO (HDF_README_PROPERTIES)
diff --git a/config/cmake/HDFTests.c b/config/cmake_ext_mod/HDFTests.c
similarity index 93%
rename from config/cmake/HDFTests.c
rename to config/cmake_ext_mod/HDFTests.c
index 2f69ec8..03aab43 100644
--- a/config/cmake/HDFTests.c
+++ b/config/cmake_ext_mod/HDFTests.c
@@ -104,27 +104,6 @@ return 0;
 int main() { return 0; }
 #endif /* STDC_HEADERS */
 
-#ifdef HAVE_TM_ZONE
-
-#include <sys/types.h>
-#ifdef HAVE_SYS_TIME_H
-#include <sys/time.h>
-#endif
-#include <time.h>
-SIMPLE_TEST(struct tm tm; tm.tm_zone);
-
-#endif /* HAVE_TM_ZONE */
-
-#ifdef HAVE_STRUCT_TM_TM_ZONE
-
-#include <sys/types.h>
-#ifdef HAVE_SYS_TIME_H
-#include <sys/time.h>
-#endif
-#include <time.h>
-SIMPLE_TEST(struct tm tm; tm.tm_zone);
-
-#endif /* HAVE_STRUCT_TM_TM_ZONE */
 
 #ifdef HAVE_ATTRIBUTE
 
@@ -377,10 +356,10 @@ int main(int argc, char **argv)
 #endif
 
 #ifdef GETTIMEOFDAY_GIVES_TZ
+#include <time.h>
 #ifdef HAVE_SYS_TIME_H
 #include <sys/time.h>
 #endif
-#include <time.h>
 int main(void)
 {
  struct timeval tv;
@@ -437,17 +416,6 @@ main ()
 
 #endif
 
-#ifdef HAVE_GPFS
-
-#include <gpfs.h>
-int main ()
-{
-    int fd = 0; 
-    gpfs_fcntl(fd, (void *)0);
-}
-
-#endif /* HAVE_GPFS */
-
 #ifdef HAVE_IOEO
 
 #include <windows.h>
diff --git a/config/cmake_ext_mod/HDFUseFortran.cmake b/config/cmake_ext_mod/HDFUseFortran.cmake
new file mode 100644
index 0000000..4955d20
--- /dev/null
+++ b/config/cmake_ext_mod/HDFUseFortran.cmake
@@ -0,0 +1,167 @@
+#
+# This file provides functions for Fortran support.
+#
+#-------------------------------------------------------------------------------
+ENABLE_LANGUAGE (Fortran)
+  
+#-----------------------------------------------------------------------------
+# Detect name mangling convention used between Fortran and C
+#-----------------------------------------------------------------------------
+include (FortranCInterface)
+FortranCInterface_HEADER (
+    ${CMAKE_BINARY_DIR}/FCMangle.h
+    MACRO_NAMESPACE "H5_FC_"
+    SYMBOL_NAMESPACE "H5_FC_"
+    SYMBOLS mysub mymod:my_sub
+)
+
+file (STRINGS ${CMAKE_BINARY_DIR}/FCMangle.h CONTENTS REGEX "H5_FC_GLOBAL\\(.*,.*\\) +(.*)")
+string (REGEX MATCH "H5_FC_GLOBAL\\(.*,.*\\) +(.*)" RESULT ${CONTENTS})
+set (H5_FC_FUNC "H5_FC_FUNC(name,NAME) ${CMAKE_MATCH_1}")
+
+file (STRINGS ${CMAKE_BINARY_DIR}/FCMangle.h CONTENTS REGEX "H5_FC_GLOBAL_\\(.*,.*\\) +(.*)")
+string (REGEX MATCH "H5_FC_GLOBAL_\\(.*,.*\\) +(.*)" RESULT ${CONTENTS})
+set (H5_FC_FUNC_ "H5_FC_FUNC_(name,NAME) ${CMAKE_MATCH_1}")
+
+#-----------------------------------------------------------------------------
+# The provided CMake Fortran macros don't provide a general check function
+# so this one is used for a sizeof test.
+#-----------------------------------------------------------------------------
+MACRO (CHECK_FORTRAN_FEATURE FUNCTION CODE VARIABLE)
+  if (NOT DEFINED ${VARIABLE})
+    message (STATUS "Testing Fortran ${FUNCTION}")
+    if (CMAKE_REQUIRED_LIBRARIES)
+      set (CHECK_FUNCTION_EXISTS_ADD_LIBRARIES
+          "-DLINK_LIBRARIES:STRING=${CMAKE_REQUIRED_LIBRARIES}")
+    else (CMAKE_REQUIRED_LIBRARIES)
+      set (CHECK_FUNCTION_EXISTS_ADD_LIBRARIES)
+    endif (CMAKE_REQUIRED_LIBRARIES)
+    file (WRITE
+        ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testFortranCompiler.f
+        "${CODE}"
+    )
+    TRY_COMPILE (${VARIABLE}
+        ${CMAKE_BINARY_DIR}
+        ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeTmp/testFortranCompiler.f
+        CMAKE_FLAGS "${CHECK_FUNCTION_EXISTS_ADD_LIBRARIES}"
+        OUTPUT_VARIABLE OUTPUT
+    )
+
+#    message ( "* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * ")
+#    message ( "Test result ${OUTPUT}")
+#    message ( "* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * ")
+
+    if (${VARIABLE})
+      set (${VARIABLE} 1 CACHE INTERNAL "Have Fortran function ${FUNCTION}")
+      message (STATUS "Testing Fortran ${FUNCTION} - OK")
+      file (APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeOutput.log
+          "Determining if the Fortran ${FUNCTION} exists passed with the following output:\n"
+          "${OUTPUT}\n\n"
+      )
+    else (${VARIABLE})
+      message (STATUS "Testing Fortran ${FUNCTION} - Fail")
+      set (${VARIABLE} "" CACHE INTERNAL "Have Fortran function ${FUNCTION}")
+      file (APPEND ${CMAKE_BINARY_DIR}${CMAKE_FILES_DIRECTORY}/CMakeError.log
+          "Determining if the Fortran ${FUNCTION} exists failed with the following output:\n"
+          "${OUTPUT}\n\n")
+    endif (${VARIABLE})
+  endif (NOT DEFINED ${VARIABLE})
+ENDMACRO (CHECK_FORTRAN_FEATURE)
+
+#-----------------------------------------------------------------------------
+# Configure Checks which require Fortran compilation must go in here
+# not in the main ConfigureChecks.cmake files, because if the user has
+# no Fortran compiler, problems arise.
+#
+# Be careful with leading spaces here, do not remove them.
+#-----------------------------------------------------------------------------
+
+# Check for Non-standard extension intrinsic function SIZEOF
+CHECK_FORTRAN_FEATURE(sizeof
+  "
+       PROGRAM main
+       i = sizeof(x)
+       END PROGRAM
+  "
+  FORTRAN_HAVE_SIZEOF
+)
+
+# Check for F2008 standard intrinsic function C_SIZEOF
+CHECK_FORTRAN_FEATURE(c_sizeof
+  "
+       PROGRAM main
+         USE ISO_C_BINDING
+         INTEGER(C_INT) :: a
+         INTEGER(C_SIZE_T) :: result
+         result = c_sizeof(a)
+       END PROGRAM
+  "
+  FORTRAN_HAVE_C_SIZEOF
+)
+
+# Check for F2008 standard intrinsic function STORAGE_SIZE
+CHECK_FORTRAN_FEATURE(storage_size
+  "
+       PROGRAM main
+         INTEGER :: a
+         INTEGER :: result
+         result = storage_size(a)
+       END PROGRAM
+  "
+  FORTRAN_HAVE_STORAGE_SIZE
+)
+
+
+CHECK_FORTRAN_FEATURE(RealIsNotDouble
+  "
+       MODULE type_mod
+         INTERFACE h5t
+           MODULE PROCEDURE h5t_real
+           MODULE PROCEDURE h5t_dble
+         END INTERFACE
+       CONTAINS
+         SUBROUTINE h5t_real(r)
+           REAL :: r
+         END SUBROUTINE h5t_real
+         SUBROUTINE h5t_dble(d)
+           DOUBLE PRECISION :: d
+         END SUBROUTINE h5t_dble
+       END MODULE type_mod
+       PROGRAM main
+         USE type_mod
+         REAL :: r
+         DOUBLE PRECISION :: d
+         CALL h5t(r)
+         CALL h5t(d)
+       END PROGRAM main
+  "
+  FORTRAN_DEFAULT_REAL_NOT_DOUBLE
+)
+
+#-----------------------------------------------------------------------------
+# Checks if the ISO_C_BINDING module meets all the requirements
+#-----------------------------------------------------------------------------
+CHECK_FORTRAN_FEATURE(iso_c_binding
+  "
+       PROGRAM main
+            USE iso_c_binding
+            IMPLICIT NONE
+            TYPE(C_PTR) :: ptr
+            TYPE(C_FUNPTR) :: funptr
+            INTEGER(C_INT64_T) :: c_int64_type 
+            CHARACTER(LEN=80, KIND=c_char), TARGET :: ichr
+            ptr = C_LOC(ichr(1:1))
+       END PROGRAM
+  "
+  FORTRAN_HAVE_ISO_C_BINDING
+)
+
+#-----------------------------------------------------------------------------
+# Add debug information (intel Fortran : JB)
+#-----------------------------------------------------------------------------
+if (CMAKE_Fortran_COMPILER MATCHES ifort)
+    if (WIN32)
+        set (CMAKE_Fortran_FLAGS_DEBUG "/debug:full /dbglibs " CACHE "flags" STRING FORCE)
+        set (CMAKE_EXE_LINKER_FLAGS_DEBUG "/DEBUG" CACHE "flags" STRING FORCE)
+    endif (WIN32)
+endif (CMAKE_Fortran_COMPILER MATCHES ifort)
diff --git a/config/cmake/NSIS.InstallOptions.ini.in b/config/cmake_ext_mod/NSIS.InstallOptions.ini.in
similarity index 71%
copy from config/cmake/NSIS.InstallOptions.ini.in
copy to config/cmake_ext_mod/NSIS.InstallOptions.ini.in
index 83ca053..9954f28 100644
--- a/config/cmake/NSIS.InstallOptions.ini.in
+++ b/config/cmake_ext_mod/NSIS.InstallOptions.ini.in
@@ -3,7 +3,7 @@ NumFields=5
 
 [Field 1]
 Type=label
-Text=By default @CPACK_PACKAGE_INSTALL_DIRECTORY@ does add its directory to the system PATH.
+Text=By default the @CPACK_PACKAGE_NAME@ bin directory is added to the system PATH. This allows shared library (dll) discovery (if installed) and running HDF5 tools from the command line.
 Left=0
 Right=-1
 Top=0
diff --git a/config/cmake/NSIS.template.in b/config/cmake_ext_mod/NSIS.template.in
similarity index 100%
rename from config/cmake/NSIS.template.in
rename to config/cmake_ext_mod/NSIS.template.in
diff --git a/config/cmake_ext_mod/grepTest.cmake b/config/cmake_ext_mod/grepTest.cmake
new file mode 100644
index 0000000..579d855
--- /dev/null
+++ b/config/cmake_ext_mod/grepTest.cmake
@@ -0,0 +1,64 @@
+# grepTest.cmake executes a command and captures the output in a file. File is then compared
+# against a reference file. Exit status of command can also be compared.
+
+# arguments checking
+if (NOT TEST_PROGRAM)
+  message (FATAL_ERROR "Require TEST_PROGRAM to be defined")
+endif (NOT TEST_PROGRAM)
+#if (NOT TEST_ARGS)
+#  message (STATUS "Require TEST_ARGS to be defined")
+#endif (NOT TEST_ARGS)
+if (NOT TEST_FOLDER)
+  message ( FATAL_ERROR "Require TEST_FOLDER to be defined")
+endif (NOT TEST_FOLDER)
+if (NOT TEST_OUTPUT)
+  message (FATAL_ERROR "Require TEST_OUTPUT to be defined")
+endif (NOT TEST_OUTPUT)
+#if (NOT TEST_EXPECT)
+#  message (STATUS "Require TEST_EXPECT to be defined")
+#endif (NOT TEST_EXPECT)
+if (NOT TEST_FILTER)
+  message (STATUS "Require TEST_FILTER to be defined")
+endif (NOT TEST_FILTER)
+if (NOT TEST_REFERENCE)
+  message (FATAL_ERROR "Require TEST_REFERENCE to be defined")
+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 (
+    COMMAND ${TEST_PROGRAM} ${TEST_ARGS}
+    WORKING_DIRECTORY ${TEST_FOLDER}
+    RESULT_VARIABLE TEST_RESULT
+    OUTPUT_FILE ${TEST_OUTPUT}
+    ERROR_FILE ${TEST_OUTPUT}.err
+    OUTPUT_VARIABLE TEST_ERROR
+    ERROR_VARIABLE TEST_ERROR
+)
+
+message (STATUS "COMMAND Result: ${TEST_RESULT}")
+message (STATUS "COMMAND Error: ${TEST_ERROR}")
+
+# now grep the output with the reference
+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) 
+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}) 
+if (${TEST_EXPECT} STREQUAL "1")
+  # TEST_EXPECT (1) interperts TEST_FILTER as NOT to match
+  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")
+endif (${TEST_EXPECT} STREQUAL "1")
+
+# everything went fine...
+message ("Passed: The output of ${TEST_PROGRAM} matched")
+
diff --git a/config/cmake_ext_mod/hdf.bmp b/config/cmake_ext_mod/hdf.bmp
new file mode 100644
index 0000000..9e9e4aa
Binary files /dev/null and b/config/cmake_ext_mod/hdf.bmp differ
diff --git a/config/cmake_ext_mod/hdf.icns b/config/cmake_ext_mod/hdf.icns
new file mode 100644
index 0000000..66f025d
Binary files /dev/null and b/config/cmake_ext_mod/hdf.icns differ
diff --git a/config/cmake_ext_mod/hdf.ico b/config/cmake_ext_mod/hdf.ico
new file mode 100644
index 0000000..26abc96
Binary files /dev/null and b/config/cmake_ext_mod/hdf.ico differ
diff --git a/config/cmake_ext_mod/prunTest.cmake b/config/cmake_ext_mod/prunTest.cmake
new file mode 100644
index 0000000..3d5ec31
--- /dev/null
+++ b/config/cmake_ext_mod/prunTest.cmake
@@ -0,0 +1,145 @@
+# runTest.cmake executes a command and captures the output in a file. File is then compared
+# against a reference file. Exit status of command can also be compared.
+cmake_policy(SET CMP0007 NEW)
+
+# arguments checking
+if (NOT TEST_PROGRAM)
+  message (FATAL_ERROR "Require TEST_PROGRAM to be defined")
+endif (NOT TEST_PROGRAM)
+#if (NOT TEST_ARGS)
+#  message (STATUS "Require TEST_ARGS to be defined")
+#endif (NOT TEST_ARGS)
+if (NOT TEST_FOLDER)
+  message ( FATAL_ERROR "Require TEST_FOLDER to be defined")
+endif (NOT TEST_FOLDER)
+if (NOT TEST_OUTPUT)
+  message (FATAL_ERROR "Require TEST_OUTPUT to be defined")
+endif (NOT TEST_OUTPUT)
+#if (NOT TEST_EXPECT)
+#  message (STATUS "Require TEST_EXPECT to be defined")
+#endif (NOT TEST_EXPECT)
+#if (NOT TEST_FILTER)
+#  message (STATUS "Require TEST_FILTER to be defined")
+#endif (NOT TEST_FILTER)
+if (NOT TEST_SKIP_COMPARE AND NOT TEST_REFERENCE)
+  message (FATAL_ERROR "Require TEST_REFERENCE to be defined")
+endif (NOT TEST_SKIP_COMPARE AND NOT TEST_REFERENCE)
+
+set (ERROR_APPEND 1)
+
+message (STATUS "COMMAND: ${TEST_PROGRAM} ${TEST_ARGS}")
+
+if (TEST_ENV_VAR)
+  set (ENV{${TEST_ENV_VAR}} "${TEST_ENV_VALUE}") 
+endif (TEST_ENV_VAR)
+
+# run the test program, capture the stdout/stderr and the result var
+EXECUTE_PROCESS (
+    COMMAND ${TEST_PROGRAM} ${TEST_ARGS}
+    WORKING_DIRECTORY ${TEST_FOLDER}
+    RESULT_VARIABLE TEST_RESULT
+    OUTPUT_FILE ${TEST_OUTPUT}
+    ERROR_FILE ${TEST_OUTPUT}.err
+    OUTPUT_VARIABLE TEST_ERROR
+    ERROR_VARIABLE TEST_ERROR
+)
+
+message (STATUS "COMMAND Result: ${TEST_RESULT}")
+
+file (READ ${TEST_FOLDER}/${TEST_REFERENCE} TEST_STREAM)
+file (WRITE ${TEST_FOLDER}/P_${TEST_REFERENCE} "${TEST_STREAM}")
+
+if (ERROR_APPEND)
+  file (READ ${TEST_FOLDER}/${TEST_OUTPUT}.err TEST_STREAM)
+  file (APPEND ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}") 
+endif (ERROR_APPEND)
+
+if (TEST_APPEND)
+  file (APPEND ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_APPEND} ${TEST_ERROR}\n") 
+endif (TEST_APPEND)
+
+message (STATUS "COMMAND Error: ${TEST_ERROR}")
+
+if (TEST_MASK)
+  file (READ ${TEST_FOLDER}/${TEST_OUTPUT} TEST_STREAM)
+  STRING(REGEX REPLACE "Storage:[^\n]+\n" "Storage:   <details removed for portability>\n" TEST_STREAM "${TEST_STREAM}") 
+  file (WRITE ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}")
+endif (TEST_MASK)
+
+if (TEST_MASK_MOD)
+  file (READ ${TEST_FOLDER}/${TEST_OUTPUT} TEST_STREAM)
+  STRING(REGEX REPLACE "Modified:[^\n]+\n" "Modified:  XXXX-XX-XX XX:XX:XX XXX\n" TEST_STREAM "${TEST_STREAM}") 
+  file (WRITE ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}")
+endif (TEST_MASK_MOD)
+
+if (TEST_MASK_ERROR)
+  file (READ ${TEST_FOLDER}/${TEST_OUTPUT} TEST_STREAM)
+  STRING(REGEX REPLACE "thread [0-9]*:" "thread (IDs):" TEST_STREAM "${TEST_STREAM}") 
+  STRING(REGEX REPLACE ": ([^\n]*)[.]c " ": (file name) " TEST_STREAM "${TEST_STREAM}") 
+  STRING(REGEX REPLACE " line [0-9]*" " line (number)" TEST_STREAM "${TEST_STREAM}") 
+  STRING(REGEX REPLACE "v[1-9]*[.][0-9]*[.]" "version (number)." TEST_STREAM "${TEST_STREAM}") 
+  STRING(REGEX REPLACE "[1-9]*[.][0-9]*[.][0-9]*[^)]*" "version (number)" TEST_STREAM "${TEST_STREAM}") 
+  STRING(REGEX REPLACE "H5Eget_auto[1-2]*" "H5Eget_auto(1 or 2)" TEST_STREAM "${TEST_STREAM}") 
+  STRING(REGEX REPLACE "H5Eset_auto[1-2]*" "H5Eset_auto(1 or 2)" TEST_STREAM "${TEST_STREAM}") 
+  file (WRITE ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}")
+endif (TEST_MASK_ERROR)
+
+if (TEST_FILTER)
+  file (READ ${TEST_FOLDER}/${TEST_OUTPUT} TEST_STREAM)
+  STRING(REGEX REPLACE "${TEST_FILTER}" "" TEST_STREAM "${TEST_STREAM}") 
+  file (WRITE ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}")
+endif (TEST_FILTER)
+
+#if (TEST_REF_FILTER)
+#  message (STATUS "TEST_REF_FILTER: ${TEST_APPEND}${TEST_REF_FILTER}")
+#  file (READ ${TEST_FOLDER}/P_${TEST_REFERENCE} TEST_STREAM)
+#  STRING(REGEX REPLACE "${TEST_APPEND}" "${TEST_REF_FILTER}" TEST_STREAM "${TEST_STREAM}") 
+#  file (WRITE ${TEST_FOLDER}/P_${TEST_REFERENCE} "${TEST_STREAM}")
+#endif (TEST_REF_FILTER)
+
+if (NOT TEST_SKIP_COMPARE)
+  if (WIN32 AND NOT MINGW)
+    file (READ ${TEST_FOLDER}/P_${TEST_REFERENCE} TEST_STREAM)
+    file (WRITE ${TEST_FOLDER}/P_${TEST_REFERENCE} "${TEST_STREAM}")
+  endif (WIN32 AND NOT MINGW)
+
+  # now compare the output with the reference
+  EXECUTE_PROCESS (
+      COMMAND ${CMAKE_COMMAND} -E compare_files ${TEST_FOLDER}/${TEST_OUTPUT} ${TEST_FOLDER}/P_${TEST_REFERENCE}
+      RESULT_VARIABLE TEST_RESULT
+  )
+  if (NOT ${TEST_RESULT} STREQUAL 0)
+  set (TEST_RESULT 0)
+  file (STRINGS ${TEST_FOLDER}/${TEST_OUTPUT} test_act)
+  LIST (LENGTH test_act len_act)
+  file (STRINGS ${TEST_FOLDER}/P_${TEST_REFERENCE} test_ref)
+  LIST (LENGTH test_ref len_ref)
+  if (NOT ${len_act} STREQUAL "0")
+    MATH (EXPR _FP_LEN "${len_ref} - 1")
+    foreach (line RANGE 0 ${_FP_LEN})
+      LIST (GET test_act ${line} str_act)
+      LIST (GET test_ref ${line} str_ref)
+      if (NOT "${str_act}" STREQUAL "${str_ref}")
+        if (NOT "${str_act}" STREQUAL "")
+          set (TEST_RESULT 1)
+          message ("line = ${line}\n***ACTUAL: ${str_act}\n****REFER: ${str_ref}\n")
+         endif (NOT "${str_act}" STREQUAL "")
+      endif (NOT "${str_act}" STREQUAL "${str_ref}")
+    endforeach (line RANGE 0 ${_FP_LEN})
+  endif (NOT ${len_act} STREQUAL "0")
+  if (NOT ${len_act} STREQUAL ${len_ref})
+    set (TEST_RESULT 1)
+  endif (NOT ${len_act} STREQUAL ${len_ref})
+  endif (NOT ${TEST_RESULT} STREQUAL 0)
+
+  message (STATUS "COMPARE Result: ${TEST_RESULT}")
+
+  # again, if return value is !=0 scream and shout
+  if (NOT ${TEST_RESULT} STREQUAL 0)
+    message (FATAL_ERROR "Failed: The output of ${TEST_OUTPUT} did not match P_${TEST_REFERENCE}")
+  endif (NOT ${TEST_RESULT} STREQUAL 0)
+endif (NOT TEST_SKIP_COMPARE)
+
+# everything went fine...
+message ("Passed: The output of ${TEST_PROGRAM} matches P_${TEST_REFERENCE}")
+
diff --git a/config/cmake_ext_mod/runTest.cmake b/config/cmake_ext_mod/runTest.cmake
new file mode 100644
index 0000000..bfaae2b
--- /dev/null
+++ b/config/cmake_ext_mod/runTest.cmake
@@ -0,0 +1,207 @@
+# runTest.cmake executes a command and captures the output in a file. File is then compared
+# against a reference file. Exit status of command can also be compared.
+cmake_policy(SET CMP0007 NEW)
+
+# arguments checking
+if (NOT TEST_PROGRAM)
+  message (FATAL_ERROR "Require TEST_PROGRAM to be defined")
+endif (NOT TEST_PROGRAM)
+#if (NOT TEST_ARGS)
+#  message (STATUS "Require TEST_ARGS to be defined")
+#endif (NOT TEST_ARGS)
+if (NOT TEST_FOLDER)
+  message ( FATAL_ERROR "Require TEST_FOLDER to be defined")
+endif (NOT TEST_FOLDER)
+if (NOT TEST_OUTPUT)
+  message (FATAL_ERROR "Require TEST_OUTPUT to be defined")
+endif (NOT TEST_OUTPUT)
+if (NOT TEST_EXPECT)
+  message (STATUS "Require TEST_EXPECT to be defined")
+endif (NOT TEST_EXPECT)
+#if (NOT TEST_FILTER)
+#  message (STATUS "Require TEST_FILTER to be defined")
+#endif (NOT TEST_FILTER)
+if (NOT TEST_SKIP_COMPARE AND NOT TEST_REFERENCE)
+  message (FATAL_ERROR "Require TEST_REFERENCE to be defined")
+endif (NOT TEST_SKIP_COMPARE AND NOT TEST_REFERENCE)
+
+if (NOT TEST_ERRREF)
+  set (ERROR_APPEND 1)
+endif (NOT TEST_ERRREF)
+
+message (STATUS "COMMAND: ${TEST_PROGRAM} ${TEST_ARGS}")
+
+if (TEST_ENV_VAR)
+  set (ENV{${TEST_ENV_VAR}} "${TEST_ENV_VALUE}") 
+endif (TEST_ENV_VAR)
+
+if (NOT TEST_INPUT)
+  # run the test program, capture the stdout/stderr and the result var
+  EXECUTE_PROCESS (
+      COMMAND ${TEST_PROGRAM} ${TEST_ARGS}
+      WORKING_DIRECTORY ${TEST_FOLDER}
+      RESULT_VARIABLE TEST_RESULT
+      OUTPUT_FILE ${TEST_OUTPUT}
+      ERROR_FILE ${TEST_OUTPUT}.err
+      OUTPUT_VARIABLE TEST_ERROR
+      ERROR_VARIABLE TEST_ERROR
+  )
+else (NOT TEST_INPUT)
+  # run the test program with stdin, capture the stdout/stderr and the result var
+  EXECUTE_PROCESS (
+      COMMAND ${TEST_PROGRAM} ${TEST_ARGS}
+      WORKING_DIRECTORY ${TEST_FOLDER}
+      RESULT_VARIABLE TEST_RESULT
+      INPUT_FILE ${TEST_INPUT}
+      OUTPUT_FILE ${TEST_OUTPUT}
+      ERROR_FILE ${TEST_OUTPUT}.err
+      OUTPUT_VARIABLE TEST_ERROR
+      ERROR_VARIABLE TEST_ERROR
+  )
+endif (NOT TEST_INPUT)
+
+message (STATUS "COMMAND Result: ${TEST_RESULT}")
+
+if (ERROR_APPEND)
+  file (READ ${TEST_FOLDER}/${TEST_OUTPUT}.err TEST_STREAM)
+  file (APPEND ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}") 
+endif (ERROR_APPEND)
+
+if (TEST_APPEND)
+  file (APPEND ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_APPEND} ${TEST_RESULT}\n") 
+endif (TEST_APPEND)
+
+# if the return value is !=${TEST_EXPECT} bail out
+if (NOT ${TEST_RESULT} STREQUAL ${TEST_EXPECT})
+  message ( FATAL_ERROR "Failed: Test program ${TEST_PROGRAM} exited != ${TEST_EXPECT}.\n${TEST_ERROR}")
+endif (NOT ${TEST_RESULT} STREQUAL ${TEST_EXPECT})
+
+message (STATUS "COMMAND Error: ${TEST_ERROR}")
+
+if (TEST_MASK)
+  file (READ ${TEST_FOLDER}/${TEST_OUTPUT} TEST_STREAM)
+  STRING(REGEX REPLACE "Storage:[^\n]+\n" "Storage:   <details removed for portability>\n" TEST_STREAM "${TEST_STREAM}") 
+  file (WRITE ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}")
+endif (TEST_MASK)
+
+if (TEST_MASK_MOD)
+  file (READ ${TEST_FOLDER}/${TEST_OUTPUT} TEST_STREAM)
+  STRING(REGEX REPLACE "Modified:[^\n]+\n" "Modified:  XXXX-XX-XX XX:XX:XX XXX\n" TEST_STREAM "${TEST_STREAM}") 
+  file (WRITE ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}")
+endif (TEST_MASK_MOD)
+
+if (TEST_MASK_ERROR)
+  if (NOT TEST_ERRREF)
+    file (READ ${TEST_FOLDER}/${TEST_OUTPUT} TEST_STREAM)
+  else (NOT TEST_ERRREF)
+    file (READ ${TEST_FOLDER}/${TEST_OUTPUT}.err TEST_STREAM)
+  endif (NOT TEST_ERRREF)
+  STRING(REGEX REPLACE "thread [0-9]*:" "thread (IDs):" TEST_STREAM "${TEST_STREAM}") 
+  STRING(REGEX REPLACE ": ([^\n]*)[.]c " ": (file name) " TEST_STREAM "${TEST_STREAM}") 
+  STRING(REGEX REPLACE " line [0-9]*" " line (number)" TEST_STREAM "${TEST_STREAM}") 
+  STRING(REGEX REPLACE "v[1-9]*[.][0-9]*[.]" "version (number)." TEST_STREAM "${TEST_STREAM}") 
+  STRING(REGEX REPLACE "[1-9]*[.][0-9]*[.][0-9]*[^)]*" "version (number)" TEST_STREAM "${TEST_STREAM}") 
+  STRING(REGEX REPLACE "H5Eget_auto[1-2]*" "H5Eget_auto(1 or 2)" TEST_STREAM "${TEST_STREAM}") 
+  STRING(REGEX REPLACE "H5Eset_auto[1-2]*" "H5Eset_auto(1 or 2)" TEST_STREAM "${TEST_STREAM}") 
+  if (NOT TEST_ERRREF)
+    file (WRITE ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}")
+  else (NOT TEST_ERRREF)
+    file (WRITE ${TEST_FOLDER}/${TEST_OUTPUT}.err "${TEST_STREAM}")
+  endif (NOT TEST_ERRREF)
+endif (TEST_MASK_ERROR)
+
+if (TEST_FILTER)
+  file (READ ${TEST_FOLDER}/${TEST_OUTPUT} TEST_STREAM)
+  STRING(REGEX REPLACE "${TEST_FILTER}" "" TEST_STREAM "${TEST_STREAM}") 
+  file (WRITE ${TEST_FOLDER}/${TEST_OUTPUT} "${TEST_STREAM}")
+endif (TEST_FILTER)
+
+if (NOT TEST_SKIP_COMPARE)
+  if (WIN32 AND NOT MINGW)
+    file (READ ${TEST_FOLDER}/${TEST_REFERENCE} TEST_STREAM)
+    file (WRITE ${TEST_FOLDER}/${TEST_REFERENCE} "${TEST_STREAM}")
+  endif (WIN32 AND NOT MINGW)
+
+  # now compare the output with the reference
+  EXECUTE_PROCESS (
+      COMMAND ${CMAKE_COMMAND} -E compare_files ${TEST_FOLDER}/${TEST_OUTPUT} ${TEST_FOLDER}/${TEST_REFERENCE}
+      RESULT_VARIABLE TEST_RESULT
+  )
+  if (NOT ${TEST_RESULT} STREQUAL 0)
+  set (TEST_RESULT 0)
+  file (STRINGS ${TEST_FOLDER}/${TEST_OUTPUT} test_act)
+  LIST (LENGTH test_act len_act)
+  file (STRINGS ${TEST_FOLDER}/${TEST_REFERENCE} test_ref)
+  LIST (LENGTH test_ref len_ref)
+  if (NOT ${len_act} STREQUAL "0")
+    MATH (EXPR _FP_LEN "${len_ref} - 1")
+    foreach (line RANGE 0 ${_FP_LEN})
+      LIST (GET test_act ${line} str_act)
+      LIST (GET test_ref ${line} str_ref)
+      if (NOT "${str_act}" STREQUAL "${str_ref}")
+        if (NOT "${str_act}" STREQUAL "")
+          set (TEST_RESULT 1)
+          message ("line = ${line}\n***ACTUAL: ${str_act}\n****REFER: ${str_ref}\n")
+         endif (NOT "${str_act}" STREQUAL "")
+      endif (NOT "${str_act}" STREQUAL "${str_ref}")
+    endforeach (line RANGE 0 ${_FP_LEN})
+  endif (NOT ${len_act} STREQUAL "0")
+  if (NOT ${len_act} STREQUAL ${len_ref})
+    set (TEST_RESULT 1)
+  endif (NOT ${len_act} STREQUAL ${len_ref})
+  endif (NOT ${TEST_RESULT} STREQUAL 0)
+
+  message (STATUS "COMPARE Result: ${TEST_RESULT}")
+
+  # again, if return value is !=0 scream and shout
+  if (NOT ${TEST_RESULT} STREQUAL 0)
+    message (FATAL_ERROR "Failed: The output of ${TEST_OUTPUT} did not match ${TEST_REFERENCE}")
+  endif (NOT ${TEST_RESULT} STREQUAL 0)
+  
+  if (TEST_ERRREF)
+    if (WIN32 AND NOT MINGW)
+      file (READ ${TEST_FOLDER}/${TEST_ERRREF} TEST_STREAM)
+      file (WRITE ${TEST_FOLDER}/${TEST_ERRREF} "${TEST_STREAM}")
+    endif (WIN32 AND NOT MINGW)
+
+    # now compare the error output with the error reference
+    EXECUTE_PROCESS (
+        COMMAND ${CMAKE_COMMAND} -E compare_files ${TEST_FOLDER}/${TEST_OUTPUT}.err ${TEST_FOLDER}/${TEST_ERRREF}
+        RESULT_VARIABLE TEST_RESULT
+    )
+    if (NOT ${TEST_RESULT} STREQUAL 0)
+    set (TEST_RESULT 0)
+    file (STRINGS ${TEST_FOLDER}/${TEST_OUTPUT}.err test_act)
+    LIST (LENGTH test_act len_act)
+    file (STRINGS ${TEST_FOLDER}/${TEST_ERRREF} test_ref)
+    LIST (LENGTH test_ref len_ref)
+    MATH (EXPR _FP_LEN "${len_ref} - 1")
+    if (NOT ${len_act} STREQUAL "0")
+      MATH (EXPR _FP_LEN "${len_ref} - 1")
+      foreach (line RANGE 0 ${_FP_LEN})
+        LIST (GET test_act ${line} str_act)
+        LIST (GET test_ref ${line} str_ref)
+        if (NOT "${str_act}" STREQUAL "${str_ref}")
+          if (NOT "${str_act}" STREQUAL "")
+            set (TEST_RESULT 1)
+            message ("line = ${line}\n***ACTUAL: ${str_act}\n****REFER: ${str_ref}\n")
+           endif (NOT "${str_act}" STREQUAL "")
+        endif (NOT "${str_act}" STREQUAL "${str_ref}")
+      endforeach (line RANGE 0 ${_FP_LEN})
+    endif (NOT ${len_act} STREQUAL "0")
+    if (NOT ${len_act} STREQUAL ${len_ref})
+      set (TEST_RESULT 1)
+    endif (NOT ${len_act} STREQUAL ${len_ref})
+    endif (NOT ${TEST_RESULT} STREQUAL 0)
+
+    message (STATUS "COMPARE Result: ${TEST_RESULT}")
+
+    # again, if return value is !=0 scream and shout
+    if (NOT ${TEST_RESULT} STREQUAL 0)
+      message (FATAL_ERROR "Failed: The error output of ${TEST_OUTPUT}.err did not match ${TEST_ERRREF}")
+    endif (NOT ${TEST_RESULT} STREQUAL 0)
+  endif (TEST_ERRREF)
+endif (NOT TEST_SKIP_COMPARE)
+
+# everything went fine...
+message ("Passed: The output of ${TEST_PROGRAM} matches ${TEST_REFERENCE}")
diff --git a/config/cmake_ext_mod/version.plist.in b/config/cmake_ext_mod/version.plist.in
new file mode 100644
index 0000000..817d89e
--- /dev/null
+++ b/config/cmake_ext_mod/version.plist.in
@@ -0,0 +1,17 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
+
+<plist version="1.0">
+<dict>
+    <key>BuildVersion</key>
+    <string>@CPACK_PACKAGE_VERSION_MAJOR@</string>
+    <key>CFBundleShortVersionString</key>
+    <string>@CPACK_APPLE_GUI_SHORT_VERSION_STRING@</string>
+    <key>CFBundleVersion</key>
+    <string>@CPACK_APPLE_GUI_SHORT_VERSION_STRING@</string>
+    <key>ProjectName</key>
+    <string>@CPACK_APPLE_GUI_BUNDLE_NAME@</string>
+    <key>SourceVersion</key>
+    <string>@CPACK_PACKAGE_VERSION_MINOR@</string>
+</dict>
+</plist>
diff --git a/configure b/configure
index 4fa35d1..f37d2fa 100755
--- a/configure
+++ b/configure
@@ -1,7 +1,7 @@
 #! /bin/sh
-# From configure.ac Id: configure.ac 6079 2014-02-08 00:29:03Z bmribler .
+# From configure.ac Id: configure.ac 6194 2015-02-05 14:17:12Z bmribler .
 # Guess values for system-dependent variables and create Makefiles.
-# Generated by GNU Autoconf 2.69 for HDF 4.2.10.
+# Generated by GNU Autoconf 2.69 for HDF 4.2.11.
 #
 # Report bugs to <help at hdfgroup.org>.
 #
@@ -591,8 +591,8 @@ MAKEFLAGS=
 # Identity of this package.
 PACKAGE_NAME='HDF'
 PACKAGE_TARNAME='hdf'
-PACKAGE_VERSION='4.2.10'
-PACKAGE_STRING='HDF 4.2.10'
+PACKAGE_VERSION='4.2.11'
+PACKAGE_STRING='HDF 4.2.11'
 PACKAGE_BUGREPORT='help at hdfgroup.org'
 PACKAGE_URL=''
 
@@ -654,6 +654,7 @@ BUILD_SHARED_SZIP_CONDITIONAL_FALSE
 BUILD_SHARED_SZIP_CONDITIONAL_TRUE
 SZIP_INFO
 LL_PATH
+SZIP_HAS_ENCODER
 USE_COMP_SZIP
 CXXCPP
 OTOOL64
@@ -735,6 +736,10 @@ build
 MAINT
 MAINTAINER_MODE_FALSE
 MAINTAINER_MODE_TRUE
+AM_BACKSLASH
+AM_DEFAULT_VERBOSITY
+AM_DEFAULT_V
+AM_V
 am__untar
 am__tar
 AMTAR
@@ -799,6 +804,7 @@ SHELL'
 ac_subst_files=''
 ac_user_opts='
 enable_option_checking
+enable_silent_rules
 enable_maintainer_mode
 enable_netcdf
 enable_dependency_tracking
@@ -1374,7 +1380,7 @@ if test "$ac_init_help" = "long"; then
   # Omit some internal or obsolete options to make the list less imposing.
   # This message is too long to be a string in the A/UX 3.1 sh.
   cat <<_ACEOF
-\`configure' configures HDF 4.2.10 to adapt to many kinds of systems.
+\`configure' configures HDF 4.2.11 to adapt to many kinds of systems.
 
 Usage: $0 [OPTION]... [VAR=VALUE]...
 
@@ -1444,7 +1450,7 @@ fi
 
 if test -n "$ac_init_help"; then
   case $ac_init_help in
-     short | recursive ) echo "Configuration of HDF 4.2.10:";;
+     short | recursive ) echo "Configuration of HDF 4.2.11:";;
    esac
   cat <<\_ACEOF
 
@@ -1452,6 +1458,8 @@ Optional Features:
   --disable-option-checking  ignore unrecognized --enable/--with options
   --disable-FEATURE       do not include FEATURE (same as --enable-FEATURE=no)
   --enable-FEATURE[=ARG]  include FEATURE [ARG=yes]
+  --enable-silent-rules   less verbose build output (undo: "make V=1")
+  --disable-silent-rules  verbose build output (undo: "make V=0")
   --enable-maintainer-mode
                           enable make rules and dependencies not useful (and
                           sometimes confusing) to the casual installer
@@ -1577,7 +1585,7 @@ fi
 test -n "$ac_init_help" && exit $ac_status
 if $ac_init_version; then
   cat <<\_ACEOF
-HDF configure 4.2.10
+HDF configure 4.2.11
 generated by GNU Autoconf 2.69
 
 Copyright (C) 2012 Free Software Foundation, Inc.
@@ -2390,7 +2398,7 @@ cat >config.log <<_ACEOF
 This file contains any messages produced by compilers while
 running configure, to aid debugging if configure makes a mistake.
 
-It was created by HDF $as_me 4.2.10, which was
+It was created by HDF $as_me 4.2.11, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   $ $0 $@
@@ -2774,7 +2782,7 @@ ac_config_headers="$ac_config_headers hdf/src/h4config.h"
 
 ## AM_INIT_AUTOMAKE takes a list of options that should be applied to
 ## every Makefile.am when automake is run.
-am__api_version='1.12'
+am__api_version='1.14'
 
 # Find a good install program.  We prefer a C program (faster),
 # so one script is as good as another.  But avoid the broken or
@@ -2958,8 +2966,8 @@ if test x"${MISSING+set}" != xset; then
   esac
 fi
 # Use eval to expand $SHELL
-if eval "$MISSING --run true"; then
-  am_missing_run="$MISSING --run "
+if eval "$MISSING --is-lightweight"; then
+  am_missing_run="$MISSING "
 else
   am_missing_run=
   { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: 'missing' script is too old or missing" >&5
@@ -3199,6 +3207,45 @@ else
 fi
 rmdir .tst 2>/dev/null
 
+# Check whether --enable-silent-rules was given.
+if test "${enable_silent_rules+set}" = set; then :
+  enableval=$enable_silent_rules;
+fi
+
+case $enable_silent_rules in # (((
+  yes) AM_DEFAULT_VERBOSITY=0;;
+   no) AM_DEFAULT_VERBOSITY=1;;
+    *) AM_DEFAULT_VERBOSITY=1;;
+esac
+am_make=${MAKE-make}
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
+$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
+if ${am_cv_make_support_nested_variables+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  if $as_echo 'TRUE=$(BAR$(V))
+BAR0=false
+BAR1=true
+V=1
+am__doit:
+	@$(TRUE)
+.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
+  am_cv_make_support_nested_variables=yes
+else
+  am_cv_make_support_nested_variables=no
+fi
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
+$as_echo "$am_cv_make_support_nested_variables" >&6; }
+if test $am_cv_make_support_nested_variables = yes; then
+    AM_V='$(V)'
+  AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
+else
+  AM_V=$AM_DEFAULT_VERBOSITY
+  AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
+fi
+AM_BACKSLASH='\'
+
 if test "`cd $srcdir && pwd`" != "`pwd`"; then
   # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
   # is not polluted with repeated "-I."
@@ -3221,7 +3268,7 @@ fi
 
 # Define the identity of the package.
  PACKAGE='hdf'
- VERSION='4.2.10'
+ VERSION='4.2.11'
 
 
 cat >>confdefs.h <<_ACEOF
@@ -3261,6 +3308,10 @@ mkdir_p='$(MKDIR_P)'
 # in the wild :-(  We should find a proper way to deprecate it ...
 AMTAR='$${TAR-tar}'
 
+
+# We'll loop over all known methods to create a tar archive until one works.
+_am_tools='gnutar  pax cpio none'
+
 am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
 
 
@@ -3268,6 +3319,48 @@ am__tar='$${TAR-tar} chof - "$$tardir"' am__untar='$${TAR-tar} xf -'
 
 
 
+# POSIX will say in a future version that running "rm -f" with no argument
+# is OK; and we want to be able to make that assumption in our Makefile
+# recipes.  So use an aggressive probe to check that the usage we want is
+# actually supported "in the wild" to an acceptable degree.
+# See automake bug#10828.
+# To make any issue more visible, cause the running configure to be aborted
+# by default if the 'rm' program in use doesn't match our expectations; the
+# user can still override this though.
+if rm -f && rm -fr && rm -rf; then : OK; else
+  cat >&2 <<'END'
+Oops!
+
+Your 'rm' program seems unable to run without file operands specified
+on the command line, even when the '-f' option is present.  This is contrary
+to the behaviour of most rm programs out there, and not conforming with
+the upcoming POSIX standard: <http://austingroupbugs.net/view.php?id=542>
+
+Please tell bug-automake at gnu.org about your system, including the value
+of your $PATH and any error possibly output before this message.  This
+can help us improve future automake versions.
+
+END
+  if test x"$ACCEPT_INFERIOR_RM_PROGRAM" = x"yes"; then
+    echo 'Configuration will proceed anyway, since you have set the' >&2
+    echo 'ACCEPT_INFERIOR_RM_PROGRAM variable to "yes"' >&2
+    echo >&2
+  else
+    cat >&2 <<'END'
+Aborting the configuration process, to ensure you take notice of the issue.
+
+You can download and install GNU coreutils to get an 'rm' implementation
+that behaves properly: <http://www.gnu.org/software/coreutils/>.
+
+If you want to complete the configuration process using your problematic
+'rm' anyway, export the environment variable ACCEPT_INFERIOR_RM_PROGRAM
+to "yes", and re-run configure.
+
+END
+    as_fn_error $? "Your 'rm' program is bad, sorry." "$LINENO" 5
+  fi
+fi
+
 ## AM_MAINTAINER_MODE turns off "rebuild rules" that contain dependencies
 ## for Makefiles, configure, etc.  If AM_MAINTAINER_MODE
 ## is *not* included here, these files will be rebuilt if out of date.
@@ -4338,6 +4431,65 @@ ac_cpp='$CPP $CPPFLAGS'
 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
 ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC understands -c and -o together" >&5
+$as_echo_n "checking whether $CC understands -c and -o together... " >&6; }
+if ${am_cv_prog_cc_c_o+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h.  */
+
+int
+main ()
+{
+
+  ;
+  return 0;
+}
+_ACEOF
+  # Make sure it works both with $CC and with simple cc.
+  # Following AC_PROG_CC_C_O, we do the test twice because some
+  # compilers refuse to overwrite an existing .o file with -o,
+  # though they will create one.
+  am_cv_prog_cc_c_o=yes
+  for am_i in 1 2; do
+    if { echo "$as_me:$LINENO: $CC -c conftest.$ac_ext -o conftest2.$ac_objext" >&5
+   ($CC -c conftest.$ac_ext -o conftest2.$ac_objext) >&5 2>&5
+   ac_status=$?
+   echo "$as_me:$LINENO: \$? = $ac_status" >&5
+   (exit $ac_status); } \
+         && test -f conftest2.$ac_objext; then
+      : OK
+    else
+      am_cv_prog_cc_c_o=no
+      break
+    fi
+  done
+  rm -f core conftest*
+  unset am_i
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_prog_cc_c_o" >&5
+$as_echo "$am_cv_prog_cc_c_o" >&6; }
+if test "$am_cv_prog_cc_c_o" != yes; then
+   # Losing compiler, so override with the script.
+   # FIXME: It is wrong to rewrite CC.
+   # But if we don't then we get into trouble of one sort or another.
+   # A longer-term fix would be to have automake use am__CC in this case,
+   # and then we could set am__CC="\$(top_srcdir)/compile \$(CC)"
+   CC="$am_aux_dir/compile $CC"
+fi
+ac_ext=c
+ac_cpp='$CPP $CPPFLAGS'
+ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
+ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
+ac_compiler_gnu=$ac_cv_c_compiler_gnu
+
 DEPDIR="${am__leading_dot}deps"
 
 ac_config_commands="$ac_config_commands depfiles"
@@ -20108,7 +20260,7 @@ Usage: $0 [OPTIONS]
 Report bugs to <bug-libtool at gnu.org>."
 
 lt_cl_version="\
-HDF config.lt 4.2.10
+HDF config.lt 4.2.11
 configured by $0, generated by GNU Autoconf 2.69.
 
 Copyright (C) 2011 Free Software Foundation, Inc.
@@ -22047,6 +22199,7 @@ esac
 ## ----------------------------------------------------------------------
 ## Is the szip library present?
  USE_COMP_SZIP="no"
+ SZIP_HAS_ENCODER="no"
 
 # Check whether --with-szlib was given.
 if test "${with_szlib+set}" = set; then :
@@ -22338,6 +22491,7 @@ $as_echo "#define HAVE_SZIP_ENCODER 1" >>confdefs.h
 fi
 
 
+
  if test "X$USE_COMP_SZIP" = "Xyes" && test "X$LL_PATH" != "X"; then
   BUILD_SHARED_SZIP_CONDITIONAL_TRUE=
   BUILD_SHARED_SZIP_CONDITIONAL_FALSE='#'
@@ -22372,6 +22526,18 @@ $as_echo "using HDF4 XDR" >&6; };
     ;;
 esac
 
+## For Solaris systems, add the -nsl for XDR support
+##
+## The SunRPC of the glibc has been replaced by a TI-RPC (Transport Independent RPC) library for IPv6 support
+case "$host" in
+  *-solaris*)
+    LIBS="$LIBS -lnsl"  ;;
+  *-pc-cygwin*)
+    LIBS="$LIBS -ltirpc"
+    CPPFLAGS="$CPPFLAGS -I/usr/include/tirpc"  ;;
+  *) ;;
+esac
+
 if test "X$BUILD_XDR" != "Xyes"; then
     cat confdefs.h - <<_ACEOF >conftest.$ac_ext
 /* end confdefs.h.  */
@@ -22417,16 +22583,6 @@ fi
 
 ## Check headers and add libraries for XDR if the HDF4 XDR library is not used.
 if test "X$BUILD_XDR" != "Xyes"; then
-  ## For Solaris systems, add the -nsl for XDR support
-  ##
-  ## The SunRPC of the glibc has been replaced by a TI-RPC (Transport Independent RPC) library for IPv6 support
-  case "$host" in
-    *-solaris*)
-      LIBS="$LIBS -lnsl"  ;;
-    *-pc-cygwin*)
-      LIBS="$LIBS -ltirpc"  ;;
-    *) ;;
-  esac
 
   ## ======================================================================
   ## Checks for header files
@@ -23596,7 +23752,7 @@ $as_echo "#define NO_DEPRECATED_SYMBOLS 1" >>confdefs.h
     ;;
 esac
 
-ac_config_files="$ac_config_files Makefile libhdf4.settings hdf/Makefile hdf/examples/Makefile hdf/fortran/Makefile hdf/fortran/examples/Makefile hdf/src/Makefile hdf/test/Makefile hdf/util/Makefile hdf/util/h4cc hdf/util/h4fc hdf/util/h4redeploy hdf/util/testutil.sh man/Makefile mfhdf/fortran/ftest.f mfhdf/fortran/jackets.c mfhdf/fortran/netcdf.inc mfhdf/libsrc/netcdf.h mfhdf/Makefile mfhdf/dumper/Makefile mfhdf/dumper/testhdp.sh mfhdf/examples/Makefile mfhdf/examples/testexamples.sh mf [...]
+ac_config_files="$ac_config_files Makefile libhdf4.settings hdf/Makefile hdf/examples/Makefile hdf/fortran/Makefile hdf/fortran/examples/Makefile hdf/src/Makefile hdf/test/Makefile hdf/util/Makefile hdf/util/h4cc hdf/util/h4fc hdf/util/h4redeploy hdf/util/testutil.sh man/Makefile mfhdf/fortran/ftest.f mfhdf/fortran/jackets.c mfhdf/fortran/netcdf.inc mfhdf/libsrc/netcdf.h mfhdf/Makefile mfhdf/dumper/Makefile mfhdf/dumper/testhdp.sh mfhdf/examples/Makefile mfhdf/examples/testexamples.sh mf [...]
 
 
 cat >confcache <<\_ACEOF
@@ -24158,7 +24314,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
 # report actual input values of CONFIG_FILES etc. instead of their
 # values after options handling.
 ac_log="
-This file was extended by HDF $as_me 4.2.10, which was
+This file was extended by HDF $as_me 4.2.11, which was
 generated by GNU Autoconf 2.69.  Invocation command line was
 
   CONFIG_FILES    = $CONFIG_FILES
@@ -24224,7 +24380,7 @@ _ACEOF
 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
 ac_cs_version="\\
-HDF config.status 4.2.10
+HDF config.status 4.2.11
 configured by $0, generated by GNU Autoconf 2.69,
   with options \\"\$ac_cs_config\\"
 
@@ -24850,6 +25006,7 @@ do
     "mfhdf/hdiff/Makefile") CONFIG_FILES="$CONFIG_FILES mfhdf/hdiff/Makefile" ;;
     "mfhdf/hdiff/testhdiff.sh") CONFIG_FILES="$CONFIG_FILES mfhdf/hdiff/testhdiff.sh" ;;
     "mfhdf/hrepack/Makefile") CONFIG_FILES="$CONFIG_FILES mfhdf/hrepack/Makefile" ;;
+    "mfhdf/hrepack/hrepack.sh") CONFIG_FILES="$CONFIG_FILES mfhdf/hrepack/hrepack.sh" ;;
     "mfhdf/hrepack/hrepack_all.sh") CONFIG_FILES="$CONFIG_FILES mfhdf/hrepack/hrepack_all.sh" ;;
     "mfhdf/libsrc/Makefile") CONFIG_FILES="$CONFIG_FILES mfhdf/libsrc/Makefile" ;;
     "mfhdf/ncdump/Makefile") CONFIG_FILES="$CONFIG_FILES mfhdf/ncdump/Makefile" ;;
@@ -25477,7 +25634,7 @@ $as_echo "$as_me: executing $ac_file commands" >&6;}
   rm -f libhdf4.settings.TMP
  ;;
     "depfiles":C) test x"$AMDEP_TRUE" != x"" || {
-  # Autoconf 2.62 quotes --file arguments for eval, but not when files
+  # Older Autoconf quotes --file arguments for eval, but not when files
   # are listed without --file.  Let's play safe and only enable the eval
   # if we detect the quoting.
   case $CONFIG_FILES in
@@ -25528,7 +25685,7 @@ $as_echo X"$mf" |
     DEPDIR=`sed -n 's/^DEPDIR = //p' < "$mf"`
     test -z "$DEPDIR" && continue
     am__include=`sed -n 's/^am__include = //p' < "$mf"`
-    test -z "am__include" && continue
+    test -z "$am__include" && continue
     am__quote=`sed -n 's/^am__quote = //p' < "$mf"`
     # Find all dependency output files, they are included files with
     # $(DEPDIR) in their names.  We invoke sed twice because it is the
diff --git a/configure.ac b/configure.ac
index 79417b2..72ec872 100644
--- a/configure.ac
+++ b/configure.ac
@@ -13,7 +13,7 @@
 ## access to either file, you may request a copy from help at hdfgroup.org.
 ## 
 ##
-AC_REVISION($Id: configure.ac 6079 2014-02-08 00:29:03Z bmribler $)
+AC_REVISION($Id: configure.ac 6194 2015-02-05 14:17:12Z bmribler $)
 
 ## ======================================================================
 ## Initialize configure.
@@ -25,7 +25,7 @@ AC_REVISION($Id: configure.ac 6079 2014-02-08 00:29:03Z bmribler $)
 ## NOTE: Do not forget to change the version number here when we do a
 ## release!!!
 ##
-AC_INIT([HDF], [4.2.10], [help at hdfgroup.org])
+AC_INIT([HDF], [4.2.11], [help at hdfgroup.org])
 AC_CONFIG_SRCDIR([hdf/src/atom.c])
 AC_CONFIG_AUX_DIR([bin])
 AC_CONFIG_HEADER([hdf/src/h4config.h])
@@ -463,6 +463,7 @@ esac
 ## ----------------------------------------------------------------------
 ## Is the szip library present?
 AC_SUBST(USE_COMP_SZIP) USE_COMP_SZIP="no"
+AC_SUBST(SZIP_HAS_ENCODER) SZIP_HAS_ENCODER="no"
 AC_ARG_WITH([szlib],
             [AS_HELP_STRING([--with-szlib=DIR],
                             [Use szlib library [default=no]])],,
@@ -591,6 +592,7 @@ if test "X$HAVE_SZIP" = "Xyes" -a "x$HAVE_SZLIB_H" = "xyes"; then
     fi
 fi
 AC_SUBST([SZIP_INFO])
+AC_SUBST([SZIP_HAS_ENCODER])
 
 AM_CONDITIONAL([BUILD_SHARED_SZIP_CONDITIONAL], [test "X$USE_COMP_SZIP" = "Xyes" && test "X$LL_PATH" != "X"])
 
@@ -615,6 +617,18 @@ case "$enableval" in
     ;;
 esac
 
+## For Solaris systems, add the -nsl for XDR support
+##
+## The SunRPC of the glibc has been replaced by a TI-RPC (Transport Independent RPC) library for IPv6 support
+case "$host" in
+  *-solaris*)
+    LIBS="$LIBS -lnsl"  ;;
+  *-pc-cygwin*)
+    LIBS="$LIBS -ltirpc"
+    CPPFLAGS="$CPPFLAGS -I/usr/include/tirpc"  ;;
+  *) ;;
+esac
+
 if test "X$BUILD_XDR" != "Xyes"; then
     AC_TRY_LINK([
     #include <rpc/types.h>
@@ -628,16 +642,6 @@ AM_CONDITIONAL([HDF_BUILD_XDR], [test "X$BUILD_XDR" = "Xyes"])
 
 ## Check headers and add libraries for XDR if the HDF4 XDR library is not used.
 if test "X$BUILD_XDR" != "Xyes"; then
-  ## For Solaris systems, add the -nsl for XDR support
-  ##
-  ## The SunRPC of the glibc has been replaced by a TI-RPC (Transport Independent RPC) library for IPv6 support
-  case "$host" in
-    *-solaris*)
-      LIBS="$LIBS -lnsl"  ;;
-    *-pc-cygwin*)
-      LIBS="$LIBS -ltirpc"  ;;
-    *) ;;
-  esac
 
   ## ======================================================================
   ## Checks for header files
@@ -996,6 +1000,7 @@ AC_CONFIG_FILES([Makefile
                  mfhdf/hdiff/Makefile
                  mfhdf/hdiff/testhdiff.sh
                  mfhdf/hrepack/Makefile
+                 mfhdf/hrepack/hrepack.sh
                  mfhdf/hrepack/hrepack_all.sh
                  mfhdf/libsrc/Makefile
                  mfhdf/ncdump/Makefile
diff --git a/hdf/CMakeLists.txt b/hdf/CMakeLists.txt
index 0346584..85e8bb6 100644
--- a/hdf/CMakeLists.txt
+++ b/hdf/CMakeLists.txt
@@ -4,9 +4,9 @@ PROJECT (HDF4_HDF)
 #-----------------------------------------------------------------------------
 # Option to build HDF4 Utilities
 #-----------------------------------------------------------------------------
-IF (EXISTS "${HDF4_HDF_SOURCE_DIR}/util" AND IS_DIRECTORY "${HDF4_HDF_SOURCE_DIR}/util")
-  OPTION (HDF4_BUILD_UTILS  "Build HDF4 Utilities" OFF)
-  IF (HDF4_BUILD_UTILS OR HDF4_BUILD_TOOLS)
-    ADD_SUBDIRECTORY (${HDF4_HDF_SOURCE_DIR}/util   ${HDF4_HDF_BINARY_DIR}/util)
-  ENDIF (HDF4_BUILD_UTILS OR HDF4_BUILD_TOOLS)
-ENDIF (EXISTS "${HDF4_HDF_SOURCE_DIR}/util" AND IS_DIRECTORY "${HDF4_HDF_SOURCE_DIR}/util")
+if (EXISTS "${HDF4_HDF_SOURCE_DIR}/util" AND IS_DIRECTORY "${HDF4_HDF_SOURCE_DIR}/util")
+  option (HDF4_BUILD_UTILS  "Build HDF4 Utilities" OFF)
+  if (HDF4_BUILD_UTILS OR HDF4_BUILD_TOOLS)
+    add_subdirectory (${HDF4_HDF_SOURCE_DIR}/util   ${HDF4_HDF_BINARY_DIR}/util)
+  endif (HDF4_BUILD_UTILS OR HDF4_BUILD_TOOLS)
+endif (EXISTS "${HDF4_HDF_SOURCE_DIR}/util" AND IS_DIRECTORY "${HDF4_HDF_SOURCE_DIR}/util")
diff --git a/hdf/Makefile.in b/hdf/Makefile.in
index cb95bfb..8a4e0d1 100644
--- a/hdf/Makefile.in
+++ b/hdf/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -14,23 +14,51 @@
 
 @SET_MAKE@
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
+    esac; \
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -49,9 +77,8 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am
+DIST_COMMON = $(top_srcdir)/config/commence.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs
 subdir = hdf
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 am__aclocal_m4_deps = $(top_srcdir)/configure.ac
@@ -61,15 +88,28 @@ mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs
 CONFIG_HEADER = $(top_builddir)/hdf/src/h4config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 SOURCES =
 DIST_SOURCES =
-RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
-	html-recursive info-recursive install-data-recursive \
-	install-dvi-recursive install-exec-recursive \
-	install-html-recursive install-info-recursive \
-	install-pdf-recursive install-ps-recursive install-recursive \
-	installcheck-recursive installdirs-recursive pdf-recursive \
-	ps-recursive uninstall-recursive
+RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
+	ctags-recursive dvi-recursive html-recursive info-recursive \
+	install-data-recursive install-dvi-recursive \
+	install-exec-recursive install-html-recursive \
+	install-info-recursive install-pdf-recursive \
+	install-ps-recursive install-recursive installcheck-recursive \
+	installdirs-recursive pdf-recursive ps-recursive \
+	tags-recursive uninstall-recursive
 am__can_run_installinfo = \
   case $$AM_UPDATE_INFO_DIR in \
     n|no|NO) false;; \
@@ -77,9 +117,29 @@ am__can_run_installinfo = \
   esac
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
   distclean-recursive maintainer-clean-recursive
-AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
-	$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
+am__recursive_targets = \
+  $(RECURSIVE_TARGETS) \
+  $(RECURSIVE_CLEAN_TARGETS) \
+  $(am__extra_recursive_targets)
+AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
 	distdir
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
@@ -110,6 +170,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -194,6 +255,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -327,14 +389,13 @@ clean-libtool:
 # (1) if the variable is set in 'config.status', edit 'config.status'
 #     (which will cause the Makefiles to be regenerated when you run 'make');
 # (2) otherwise, pass the desired values on the 'make' command line.
-$(RECURSIVE_TARGETS) $(RECURSIVE_CLEAN_TARGETS):
-	@fail= failcom='exit 1'; \
-	for f in x $$MAKEFLAGS; do \
-	  case $$f in \
-	    *=* | --[!k]*);; \
-	    *k*) failcom='fail=yes';; \
-	  esac; \
-	done; \
+$(am__recursive_targets):
+	@fail=; \
+	if $(am__make_keepgoing); then \
+	  failcom='fail=yes'; \
+	else \
+	  failcom='exit 1'; \
+	fi; \
 	dot_seen=no; \
 	target=`echo $@ | sed s/-recursive//`; \
 	case "$@" in \
@@ -355,31 +416,13 @@ $(RECURSIVE_TARGETS) $(RECURSIVE_CLEAN_TARGETS):
 	if test "$$dot_seen" = "no"; then \
 	  $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
 	fi; test -z "$$fail"
-tags-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
-	done
-ctags-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
-	done
-cscopelist-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) cscopelist); \
-	done
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-recursive
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
@@ -395,12 +438,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
 	  fi; \
 	done; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -412,15 +450,11 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-recursive
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -429,9 +463,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-recursive
 
-cscopelist: cscopelist-recursive $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -603,24 +638,21 @@ ps-am:
 
 uninstall-am:
 
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) \
-	cscopelist-recursive ctags-recursive install-am install-strip \
-	tags-recursive
+.MAKE: $(am__recursive_targets) install-am install-strip
 
-.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
-	all all-am check check-am clean clean-generic clean-libtool \
-	cscopelist cscopelist-recursive ctags ctags-recursive \
-	distclean distclean-generic distclean-libtool distclean-tags \
-	distdir dvi dvi-am html html-am info info-am install \
-	install-am install-data install-data-am install-dvi \
+.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \
+	check-am clean clean-generic clean-libtool cscopelist-am ctags \
+	ctags-am distclean distclean-generic distclean-libtool \
+	distclean-tags distdir dvi dvi-am html html-am info info-am \
+	install install-am install-data install-data-am install-dvi \
 	install-dvi-am install-exec install-exec-am install-html \
 	install-html-am install-info install-info-am install-man \
 	install-pdf install-pdf-am install-ps install-ps-am \
 	install-strip installcheck installcheck-am installcheck-local \
 	installdirs installdirs-am maintainer-clean \
 	maintainer-clean-generic mostlyclean mostlyclean-generic \
-	mostlyclean-libtool pdf pdf-am ps ps-am tags tags-recursive \
-	uninstall uninstall-am
+	mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \
+	uninstall-am
 
 
 installcheck-local:
diff --git a/hdf/examples/CMakeLists.txt b/hdf/examples/CMakeLists.txt
index b60d2b6..6f2128b 100644
--- a/hdf/examples/CMakeLists.txt
+++ b/hdf/examples/CMakeLists.txt
@@ -4,7 +4,7 @@ PROJECT (HDF4_HDF_EXAMPLES C CXX)
 #-----------------------------------------------------------------------------
 # Define Sources
 #-----------------------------------------------------------------------------
-SET (examples
+set (examples
     VD_create_vdatas 
     VD_write_mixed_vdata
     VD_write_mixed_vdata_struct 
@@ -35,18 +35,18 @@ SET (examples
     AN_read_annotation
 )
 
-FOREACH (example ${examples})
+foreach (example ${examples})
   ADD_EXECUTABLE (hdf_${example} ${HDF4_HDF_EXAMPLES_SOURCE_DIR}/${example}.c)
   TARGET_NAMING (hdf_${example} ${LIB_TYPE})
   TARGET_C_PROPERTIES (hdf_${example} " " " ")
-  TARGET_LINK_LIBRARIES (hdf_${example} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDFOREACH (example ${examples})
+  target_link_libraries (hdf_${example} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endforeach (example ${examples})
 
 ADD_EXECUTABLE (hdf_VG_add_sds_to_vgroup ${HDF4_HDF_EXAMPLES_SOURCE_DIR}/VG_add_sds_to_vgroup.c)
 TARGET_NAMING (hdf_VG_add_sds_to_vgroup ${LIB_TYPE})
 TARGET_C_PROPERTIES (hdf_VG_add_sds_to_vgroup " " " ")
-TARGET_LINK_LIBRARIES (hdf_VG_add_sds_to_vgroup ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+target_link_libraries (hdf_VG_add_sds_to_vgroup ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
-IF (BUILD_TESTING)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING)
+if (BUILD_TESTING)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING)
diff --git a/hdf/examples/CMakeTests.cmake b/hdf/examples/CMakeTests.cmake
index 0079918..83bd69a 100644
--- a/hdf/examples/CMakeTests.cmake
+++ b/hdf/examples/CMakeTests.cmake
@@ -6,7 +6,7 @@
 ##############################################################################
 
 # Remove any output file left over from previous test run
-ADD_TEST (
+add_test (
     NAME HDF_EXAMPLES-clearall-objects
     COMMAND    ${CMAKE_COMMAND}
         -E remove 
@@ -19,27 +19,27 @@ ADD_TEST (
         Two_Vdatas.hdf
         Two_Vgroups.hdf
 )
-IF (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (HDF_EXAMPLES-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS EXAMPLES)
-ELSE (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (HDF_EXAMPLES-clearall-objects PROPERTIES LABELS EXAMPLES)
-ENDIF (NOT "${last_test}" STREQUAL "")
-SET (last_test "HDF_EXAMPLES-clearall-objects")
+if (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (HDF_EXAMPLES-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS EXAMPLES)
+else (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (HDF_EXAMPLES-clearall-objects PROPERTIES LABELS EXAMPLES)
+endif (NOT "${last_test}" STREQUAL "")
+set (last_test "HDF_EXAMPLES-clearall-objects")
 
-FOREACH (example ${examples})
-  ADD_TEST (NAME hdftest_${example} COMMAND $<TARGET_FILE:hdf_${example}>)
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (hdftest_${example} PROPERTIES DEPENDS ${last_test} LABELS EXAMPLES)
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (hdftest_${example} PROPERTIES LABELS EXAMPLES)
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "hdftest_${example}")
-ENDFOREACH (example ${examples})
+foreach (example ${examples})
+  add_test (NAME hdftest_${example} COMMAND $<TARGET_FILE:hdf_${example}>)
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (hdftest_${example} PROPERTIES DEPENDS ${last_test} LABELS EXAMPLES)
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (hdftest_${example} PROPERTIES LABELS EXAMPLES)
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "hdftest_${example}")
+endforeach (example ${examples})
 
-ADD_TEST (NAME hdftest_VG_add_sds_to_vgroup COMMAND $<TARGET_FILE:hdf_VG_add_sds_to_vgroup>)
-IF (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (hdftest_VG_add_sds_to_vgroup PROPERTIES DEPENDS ${last_test} LABELS EXAMPLES)
-ELSE (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (hdftest_VG_add_sds_to_vgroup PROPERTIES LABELS EXAMPLES)
-ENDIF (NOT "${last_test}" STREQUAL "")
-SET (last_test "hdftest_VG_add_sds_to_vgroup")
+add_test (NAME hdftest_VG_add_sds_to_vgroup COMMAND $<TARGET_FILE:hdf_VG_add_sds_to_vgroup>)
+if (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (hdftest_VG_add_sds_to_vgroup PROPERTIES DEPENDS ${last_test} LABELS EXAMPLES)
+else (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (hdftest_VG_add_sds_to_vgroup PROPERTIES LABELS EXAMPLES)
+endif (NOT "${last_test}" STREQUAL "")
+set (last_test "hdftest_VG_add_sds_to_vgroup")
diff --git a/hdf/examples/Makefile.in b/hdf/examples/Makefile.in
index 2b5b87e..095b650 100644
--- a/hdf/examples/Makefile.in
+++ b/hdf/examples/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -21,23 +21,51 @@
 # built using h4cc (or h4fc, etc.) instead of the standard compilers.
 # This creates some extra work for us.
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -56,11 +84,11 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am \
-	$(top_srcdir)/config/examples.am
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/examples.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
+	$(top_srcdir)/bin/test-driver README
 TESTS = $(TEST_PROG)
 subdir = hdf/examples
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -71,6 +99,18 @@ mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs
 CONFIG_HEADER = $(top_builddir)/hdf/src/h4config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 SOURCES =
 DIST_SOURCES =
 am__can_run_installinfo = \
@@ -78,13 +118,213 @@ am__can_run_installinfo = \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+  test -z "$$files" \
+    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+         $(am__cd) "$$dir" && rm -f $$files; }; \
+  }
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
+TEST_SUITE_LOG = test-suite.log
+LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -169,6 +409,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -322,6 +563,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
+.SUFFIXES: .log .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/examples.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -359,15 +601,361 @@ mostlyclean-libtool:
 
 clean-libtool:
 	-rm -rf .libs _libs
-tags: TAGS
-TAGS:
+tags TAGS:
 
-ctags: CTAGS
-CTAGS:
+ctags CTAGS:
 
 cscope cscopelist:
 
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all 
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+VD_create_vdatas.log: VD_create_vdatas
+	@p='VD_create_vdatas'; \
+	b='VD_create_vdatas'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_write_mixed_vdata.log: VD_write_mixed_vdata
+	@p='VD_write_mixed_vdata'; \
+	b='VD_write_mixed_vdata'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_write_mixed_vdata_struct.log: VD_write_mixed_vdata_struct
+	@p='VD_write_mixed_vdata_struct'; \
+	b='VD_write_mixed_vdata_struct'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_write_to_vdata.log: VD_write_to_vdata
+	@p='VD_write_to_vdata'; \
+	b='VD_write_to_vdata'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_read_from_vdata.log: VD_read_from_vdata
+	@p='VD_read_from_vdata'; \
+	b='VD_read_from_vdata'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_read_mixed_vdata.log: VD_read_mixed_vdata
+	@p='VD_read_mixed_vdata'; \
+	b='VD_read_mixed_vdata'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_set_get_vdata_attr.log: VD_set_get_vdata_attr
+	@p='VD_set_get_vdata_attr'; \
+	b='VD_set_get_vdata_attr'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_create_onefield_vdatas.log: VD_create_onefield_vdatas
+	@p='VD_create_onefield_vdatas'; \
+	b='VD_create_onefield_vdatas'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_get_vdata_info.log: VD_get_vdata_info
+	@p='VD_get_vdata_info'; \
+	b='VD_get_vdata_info'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_locate_vdata.log: VD_locate_vdata
+	@p='VD_locate_vdata'; \
+	b='VD_locate_vdata'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VG_create_vgroup.log: VG_create_vgroup
+	@p='VG_create_vgroup'; \
+	b='VG_create_vgroup'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VG_add_sds_to_vgroup.log: VG_add_sds_to_vgroup
+	@p='VG_add_sds_to_vgroup'; \
+	b='VG_add_sds_to_vgroup'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VG_insert_vdatas_to_vgroup.log: VG_insert_vdatas_to_vgroup
+	@p='VG_insert_vdatas_to_vgroup'; \
+	b='VG_insert_vdatas_to_vgroup'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VG_set_get_vgroup_attr.log: VG_set_get_vgroup_attr
+	@p='VG_set_get_vgroup_attr'; \
+	b='VG_set_get_vgroup_attr'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VG_vgroup_contents.log: VG_vgroup_contents
+	@p='VG_vgroup_contents'; \
+	b='VG_vgroup_contents'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VG_get_vgroup_info.log: VG_get_vgroup_info
+	@p='VG_get_vgroup_info'; \
+	b='VG_get_vgroup_info'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_create_and_write_image.log: GR_create_and_write_image
+	@p='GR_create_and_write_image'; \
+	b='GR_create_and_write_image'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_modify_image.log: GR_modify_image
+	@p='GR_modify_image'; \
+	b='GR_modify_image'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_set_attribute.log: GR_set_attribute
+	@p='GR_set_attribute'; \
+	b='GR_set_attribute'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_get_attribute.log: GR_get_attribute
+	@p='GR_get_attribute'; \
+	b='GR_get_attribute'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_write_palette.log: GR_write_palette
+	@p='GR_write_palette'; \
+	b='GR_write_palette'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_read_palette.log: GR_read_palette
+	@p='GR_read_palette'; \
+	b='GR_read_palette'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_image_info.log: GR_image_info
+	@p='GR_image_info'; \
+	b='GR_image_info'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_read_image.log: GR_read_image
+	@p='GR_read_image'; \
+	b='GR_read_image'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_write_chunks.log: GR_write_chunks
+	@p='GR_write_chunks'; \
+	b='GR_write_chunks'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_read_chunks.log: GR_read_chunks
+	@p='GR_read_chunks'; \
+	b='GR_read_chunks'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+AN_create_annotation.log: AN_create_annotation
+	@p='AN_create_annotation'; \
+	b='AN_create_annotation'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+AN_get_annotation_info.log: AN_get_annotation_info
+	@p='AN_get_annotation_info'; \
+	b='AN_get_annotation_info'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+AN_read_annotation.log: AN_read_annotation
+	@p='AN_read_annotation'; \
+	b='AN_read_annotation'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -424,6 +1012,9 @@ install-strip:
 	fi
 mostlyclean-generic:
 	-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 	-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
@@ -506,17 +1097,18 @@ uninstall-am: uninstall-local
 .MAKE: check-am install-am install-strip
 
 .PHONY: all all-am all-local check check-TESTS check-am clean \
-	clean-generic clean-libtool distclean distclean-generic \
-	distclean-libtool distdir dvi dvi-am html html-am info info-am \
-	install install-am install-data install-data-am \
-	install-data-local install-dvi install-dvi-am install-exec \
-	install-exec-am install-html install-html-am install-info \
-	install-info-am install-man install-pdf install-pdf-am \
-	install-ps install-ps-am install-strip installcheck \
-	installcheck-am installcheck-local installdirs \
+	clean-generic clean-libtool cscopelist-am ctags-am distclean \
+	distclean-generic distclean-libtool distdir dvi dvi-am html \
+	html-am info info-am install install-am install-data \
+	install-data-am install-data-local install-dvi install-dvi-am \
+	install-exec install-exec-am install-html install-html-am \
+	install-info install-info-am install-man install-pdf \
+	install-pdf-am install-ps install-ps-am install-strip \
+	installcheck installcheck-am installcheck-local installdirs \
 	maintainer-clean maintainer-clean-generic mostlyclean \
 	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
-	pdf-am ps ps-am uninstall uninstall-am uninstall-local
+	pdf-am ps ps-am recheck tags-am uninstall uninstall-am \
+	uninstall-local
 
 
 # How to build C programs using h4cc
diff --git a/hdf/examples/README b/hdf/examples/README
index 1eb14bb..38e1452 100644
--- a/hdf/examples/README
+++ b/hdf/examples/README
@@ -1,5 +1,7 @@
                                HDF4 Examples
 
+Code Examples
+=============
 This directory contains example programs for the installed APIs and scripts to 
 compile and run them.  Examples in the c subdirectory are always 
 installed, and those in the fortan subdirectory will be installed 
@@ -9,14 +11,19 @@ Running the run-all-ex.sh script in this directory will run the scripts and in
 turn the examples in the subdirectories where examples are installed.  The 
 scripts can also be run individually.  The appropriate compile scripts in the 
 bin directory for this install will be used by default to compile and link the 
-example programs.  Note that h5redeploy must be run if these binaries are 
+example programs.  Note that h4redeploy must be run if these binaries are 
 copied or extracted in a directory other than the one where they were initially 
 installed.  Compile scripts from other locations can be used by setting an 
 environment variable prefix to the path of the directory containing the bin 
 directory with the compile scripts h4cc and h4fc.  For example, export 
-prefix=/usr/local/hdf4 to use h4cc and h5fc in /usr/local/hdf4/bin.
+prefix=/usr/local/hdf4 to use h4cc and h4fc in /usr/local/hdf4/bin.
 
 Running HDF4 examples built with shared libraries not in system locations may 
 result in an error message "...error while loading shared libraries: ...".  
 Setting LD_LIBRARY_PATH to include the directory containing the missing library
 should allow the examples to run.
+
+
+HDF4 Data File Examples
+=======================
+Examples of HDF4 data files (with extension .hdf) may be found in the source directory mfhdf/dumper/testfiles.  Also, running the run-all-ex.sh script produces HDF4 data files that are automatically deleted by the scripts.  The scripts in the c and fortran subdirectories can be modified to not delete those data files by commenting with "#" the line "rm *.hdf" in the last 5 lines of the scripts in those subdirectories.   
diff --git a/hdf/fortran/CMakeLists.txt b/hdf/fortran/CMakeLists.txt
index c7653bd..a9e575a 100644
--- a/hdf/fortran/CMakeLists.txt
+++ b/hdf/fortran/CMakeLists.txt
@@ -9,7 +9,7 @@ INCLUDE_DIRECTORIES (
     ${HDF4_HDF_BINARY_DIR}
 )
   
-SET (HDF4_HDF_SRC_CSTUB_FSRCS
+set (HDF4_HDF_SRC_CSTUB_FSRCS
     ${HDF4_HDFSOURCE_DIR}/dfanf.c
     ${HDF4_HDFSOURCE_DIR}/dff.c
     ${HDF4_HDFSOURCE_DIR}/dfpf.c
@@ -27,29 +27,29 @@ SET (HDF4_HDF_SRC_CSTUB_FSRCS
     ${HDF4_HDFSOURCE_DIR}/vgf.c
 )
 
-SET (HDF4_HDF_SRC_FHDRS
+set (HDF4_HDF_SRC_FHDRS
     ${HDF4_HDFSOURCE_DIR}/dffunc.inc
     ${HDF4_HDFSOURCE_DIR}/hdf.inc
 )
 
 SET_SOURCE_FILES_PROPERTIES (${HDF4_HDF_SRC_CSTUB_FSRCS} PROPERTIES LANGUAGE C) 
 
-SET (FORTRAN_SRC_DIR ${CMAKE_CURRENT_SOURCE_DIR})
+set (FORTRAN_SRC_DIR ${CMAKE_CURRENT_SOURCE_DIR})
 
 #-----------------------------------------------------------------------------
 # Add Main fortran library
 #-----------------------------------------------------------------------------
-ADD_LIBRARY (${HDF4_SRC_FCSTUB_LIB_TARGET} ${LIB_TYPE} ${HDF4_HDF_SRC_CSTUB_FSRCS} ${HDF4_HDF_SRC_CHDRS} ${HDF4_HDFSOURCE_DIR}/hproto_fortran.h ${HDF4_BINARY_DIR}/h4config.h)
-SET_TARGET_PROPERTIES (${HDF4_SRC_FCSTUB_LIB_TARGET} PROPERTIES LINKER_LANGUAGE C)
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS)
-ENDIF (WIN32 AND NOT CYGWIN)
+add_library (${HDF4_SRC_FCSTUB_LIB_TARGET} ${LIB_TYPE} ${HDF4_HDF_SRC_CSTUB_FSRCS} ${HDF4_HDF_SRC_CHDRS} ${HDF4_HDFSOURCE_DIR}/hproto_fortran.h ${HDF4_BINARY_DIR}/h4config.h)
+set_target_properties (${HDF4_SRC_FCSTUB_LIB_TARGET} PROPERTIES LINKER_LANGUAGE C)
+if (WIN32)
+  add_definitions (-DDOS_FS)
+endif (WIN32)
 TARGET_C_PROPERTIES (${HDF4_SRC_FCSTUB_LIB_TARGET} " " " ")
-TARGET_LINK_LIBRARIES (${HDF4_SRC_FCSTUB_LIB_TARGET} ${HDF4_SRC_LIB_TARGET})
-SET_GLOBAL_VARIABLE (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_SRC_FCSTUB_LIB_TARGET}")
+target_link_libraries (${HDF4_SRC_FCSTUB_LIB_TARGET} ${HDF4_SRC_LIB_TARGET})
+set_global_variable (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_SRC_FCSTUB_LIB_TARGET}")
 H4_SET_LIB_OPTIONS (${HDF4_SRC_FCSTUB_LIB_TARGET} ${HDF4_SRC_FCSTUB_LIB_NAME} ${LIB_TYPE})
 
-SET (HDF4_F_FORTRAN_SRCS 
+set (HDF4_F_FORTRAN_SRCS 
     ${HDF4_HDFSOURCE_DIR}/df24ff.f  
     ${HDF4_HDFSOURCE_DIR}/dfanff.f 
     ${HDF4_HDFSOURCE_DIR}/dfpff.f 
@@ -63,24 +63,24 @@ SET (HDF4_F_FORTRAN_SRCS
     ${HDF4_HDFSOURCE_DIR}/vgff.f 
 )
 #-----------------------------------------------------------------------------
-ADD_LIBRARY (${HDF4_SRC_FORTRAN_LIB_TARGET} ${LIB_TYPE} ${HDF4_F_FORTRAN_SRCS})
-SET (SHARED_LINK_FLAGS " ")
-IF (WIN32)
-  IF (${LIB_TYPE} MATCHES "SHARED")
-    IF (MSVC)
-      SET (SHARED_LINK_FLAGS "/DLL /DEF:${HDF4_HDF_FORTRAN_SOURCE_DIR}/hdf_fortrandll.def")
-    ENDIF (MSVC)
-  ENDIF (${LIB_TYPE} MATCHES "SHARED")
-ENDIF (WIN32)
+add_library (${HDF4_SRC_FORTRAN_LIB_TARGET} ${LIB_TYPE} ${HDF4_F_FORTRAN_SRCS})
+set (SHARED_LINK_FLAGS " ")
+if (WIN32)
+  if (${LIB_TYPE} MATCHES "SHARED")
+    if (MSVC)
+      set (SHARED_LINK_FLAGS "/DLL /DEF:${HDF4_HDF_FORTRAN_SOURCE_DIR}/hdf_fortrandll.def")
+    endif (MSVC)
+  endif (${LIB_TYPE} MATCHES "SHARED")
+endif (WIN32)
 TARGET_FORTRAN_PROPERTIES (${HDF4_SRC_FORTRAN_LIB_TARGET} " " ${SHARED_LINK_FLAGS})
-SET_TARGET_PROPERTIES (${HDF4_SRC_FORTRAN_LIB_TARGET} PROPERTIES LINKER_LANGUAGE Fortran)
-TARGET_LINK_LIBRARIES (${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_FCSTUB_LIB_TARGET} ${LINK_LIBS})
-SET_GLOBAL_VARIABLE (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_SRC_FORTRAN_LIB_TARGET}")
+set_target_properties (${HDF4_SRC_FORTRAN_LIB_TARGET} PROPERTIES LINKER_LANGUAGE Fortran)
+target_link_libraries (${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_FCSTUB_LIB_TARGET} ${LINK_LIBS})
+set_global_variable (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_SRC_FORTRAN_LIB_TARGET}")
 H4_SET_LIB_OPTIONS (${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_FORTRAN_LIB_NAME} ${LIB_TYPE})
   
-IF (BUILD_TESTING)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING)
+if (BUILD_TESTING)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING)
 
 ##############################################################################
 ##############################################################################
@@ -103,11 +103,11 @@ INSTALL (
 #-----------------------------------------------------------------------------
 # Add Target(s) to CMake Install for import into other projects
 #-----------------------------------------------------------------------------
-IF (HDF4_EXPORTED_TARGETS)
-  IF (BUILD_SHARED_LIBS)
+if (HDF4_EXPORTED_TARGETS)
+  if (BUILD_SHARED_LIBS)
     INSTALL_TARGET_PDB (${HDF4_SRC_FCSTUB_LIB_TARGET} ${HDF4_INSTALL_LIB_DIR} fortlibraries)
     INSTALL_TARGET_PDB (${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_INSTALL_LIB_DIR} fortlibraries)
-  ENDIF (BUILD_SHARED_LIBS)
+  endif (BUILD_SHARED_LIBS)
   
   INSTALL (
       TARGETS 
@@ -119,5 +119,5 @@ IF (HDF4_EXPORTED_TARGETS)
       ARCHIVE DESTINATION ${HDF4_INSTALL_LIB_DIR} COMPONENT fortlibraries
       RUNTIME DESTINATION ${HDF4_INSTALL_BIN_DIR} COMPONENT fortlibraries
   )
-ENDIF (HDF4_EXPORTED_TARGETS)
+endif (HDF4_EXPORTED_TARGETS)
     
\ No newline at end of file
diff --git a/hdf/fortran/CMakeTests.cmake b/hdf/fortran/CMakeTests.cmake
index 2d37e05..8bd6b7c 100644
--- a/hdf/fortran/CMakeTests.cmake
+++ b/hdf/fortran/CMakeTests.cmake
@@ -5,33 +5,33 @@
 ##############################################################################
 ##############################################################################
   
-  SET (FORTRAN_SRC_DIR ${HDF4_HDF_TEST_SOURCE_DIR})
+  set (FORTRAN_SRC_DIR ${HDF4_HDF_TEST_SOURCE_DIR})
 
   #-----------------------------------------------------------------------------
   # Add test fortran stub library
   #-----------------------------------------------------------------------------
-  ADD_LIBRARY (${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} ${LIB_TYPE} ${HDF4_HDF_TESTSOURCE_DIR}/forsupf.c)
-  SET_TARGET_PROPERTIES (${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} PROPERTIES LINKER_LANGUAGE C)
-  IF (WIN32 AND NOT CYGWIN)
-    ADD_DEFINITIONS (-DDOS_FS)
-  ENDIF (WIN32 AND NOT CYGWIN)
+  add_library (${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} ${LIB_TYPE} ${HDF4_HDF_TESTSOURCE_DIR}/forsupf.c)
+  set_target_properties (${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} PROPERTIES LINKER_LANGUAGE C)
+  if (WIN32)
+    add_definitions (-DDOS_FS)
+  endif (WIN32)
   TARGET_C_PROPERTIES (${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} " " " ")
-  TARGET_LINK_LIBRARIES (${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} ${HDF4_SRC_LIB_TARGET})
+  target_link_libraries (${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} ${HDF4_SRC_LIB_TARGET})
   H4_SET_LIB_OPTIONS (${HDF4_HDF_TEST_FCSTUB_LIB_TARGET}  ${HDF4_HDF_TEST_FCSTUB_LIB_NAME} ${LIB_TYPE})
   
   #-- Adding test for fortest
   ADD_EXECUTABLE (fortest ${HDF4_HDF_TESTSOURCE_DIR}/fortest.c)
   TARGET_NAMING (fortest ${LIB_TYPE})
   TARGET_C_PROPERTIES (fortest " " " ")
-  TARGET_LINK_LIBRARIES (fortest ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_LIB_TARGET})
-  IF (WIN32 AND MSVC)
-    TARGET_LINK_LIBRARIES (fortest "ws2_32.lib")
-  ENDIF (WIN32 AND MSVC)
-  SET_TARGET_PROPERTIES (fortest PROPERTIES LINKER_LANGUAGE C)
+  target_link_libraries (fortest ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_LIB_TARGET})
+  if (WIN32)
+    target_link_libraries (fortest "ws2_32.lib")
+  endif (WIN32)
+  set_target_properties (fortest PROPERTIES LINKER_LANGUAGE C)
 
   #-----------------------------------------------------------------------------
   #-- Adding test for fortestF
-  SET (FORTEST_FSRCS 
+  set (FORTEST_FSRCS 
       ${HDF4_HDF_TESTSOURCE_DIR}/fortestF.f
       ${HDF4_HDF_TESTSOURCE_DIR}/forsupff.f
       ${HDF4_HDF_TESTSOURCE_DIR}/manf.f
@@ -55,11 +55,11 @@
   ADD_EXECUTABLE (fortestF ${FORTEST_FSRCS} )
   TARGET_NAMING (fortestF ${LIB_TYPE})
   TARGET_FORTRAN_PROPERTIES (fortestF " " " ")
-  TARGET_LINK_LIBRARIES (fortestF ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_FCSTUB_LIB_TARGET} ${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} )
-  SET_TARGET_PROPERTIES (fortestF PROPERTIES LINKER_LANGUAGE Fortran)
+  target_link_libraries (fortestF ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_FCSTUB_LIB_TARGET} ${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} )
+  set_target_properties (fortestF PROPERTIES LINKER_LANGUAGE Fortran)
 
   #-- Copy all the dat files from the test directory into the source directory
-  SET (HDF4_REFERENCE_TEST_FILES
+  set (HDF4_REFERENCE_TEST_FILES
     8bit.dat
     bitio.dat
     gr_r24.dat
@@ -70,16 +70,16 @@
     tmgr.dat
     tvattr.dat
   )
-  FOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/test_files/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_HDF_TESTSOURCE_DIR}/test_files/${h4_file} to ${PROJECT_BINARY_DIR}/test_files/")
+  foreach (h4_file ${HDF4_REFERENCE_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/test_files/${h4_file}")
+    #message (STATUS " Copying ${HDF4_HDF_TESTSOURCE_DIR}/test_files/${h4_file} to ${PROJECT_BINARY_DIR}/test_files/")
     ADD_CUSTOM_COMMAND (
         TARGET     fortestF 
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_TESTSOURCE_DIR}/test_files/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
+  endforeach (h4_file ${HDF4_REFERENCE_TEST_FILES})
 
 ##############################################################################
 ##############################################################################
@@ -88,7 +88,7 @@
 ##############################################################################
 
   # Remove any output file left over from previous test run
-  ADD_TEST (
+  add_test (
       NAME HDF_FORTRAN-clearall-objects
       COMMAND    ${CMAKE_COMMAND}
           -E remove 
@@ -107,9 +107,9 @@
           tmgrf.hdf
   )
 
-  ADD_TEST (NAME fortest COMMAND $<TARGET_FILE:fortest>)
+  add_test (NAME fortest COMMAND $<TARGET_FILE:fortest>)
 
-  ADD_TEST (NAME fortestF COMMAND $<TARGET_FILE:fortestF>)
-  SET (passRegex "All Fortran Interface Tests Passed")
+  add_test (NAME fortestF COMMAND $<TARGET_FILE:fortestF>)
+  set (passRegex "All Fortran Interface Tests Passed")
   SET_PROPERTY (TEST fortestF PROPERTY PASS_REGULAR_EXPRESSION "${passRegex}")
     
\ No newline at end of file
diff --git a/hdf/fortran/Makefile.in b/hdf/fortran/Makefile.in
index 61961fe..6a57fb7 100644
--- a/hdf/fortran/Makefile.in
+++ b/hdf/fortran/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -14,23 +14,51 @@
 
 @SET_MAKE@
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
+    esac; \
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -49,9 +77,8 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am
+DIST_COMMON = $(top_srcdir)/config/commence.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs
 subdir = hdf/fortran
 SUBDIRS =
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -62,15 +89,28 @@ mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs
 CONFIG_HEADER = $(top_builddir)/hdf/src/h4config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 SOURCES =
 DIST_SOURCES =
-RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
-	html-recursive info-recursive install-data-recursive \
-	install-dvi-recursive install-exec-recursive \
-	install-html-recursive install-info-recursive \
-	install-pdf-recursive install-ps-recursive install-recursive \
-	installcheck-recursive installdirs-recursive pdf-recursive \
-	ps-recursive uninstall-recursive
+RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
+	ctags-recursive dvi-recursive html-recursive info-recursive \
+	install-data-recursive install-dvi-recursive \
+	install-exec-recursive install-html-recursive \
+	install-info-recursive install-pdf-recursive \
+	install-ps-recursive install-recursive installcheck-recursive \
+	installdirs-recursive pdf-recursive ps-recursive \
+	tags-recursive uninstall-recursive
 am__can_run_installinfo = \
   case $$AM_UPDATE_INFO_DIR in \
     n|no|NO) false;; \
@@ -78,9 +118,29 @@ am__can_run_installinfo = \
   esac
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
   distclean-recursive maintainer-clean-recursive
-AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
-	$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
+am__recursive_targets = \
+  $(RECURSIVE_TARGETS) \
+  $(RECURSIVE_CLEAN_TARGETS) \
+  $(am__extra_recursive_targets)
+AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
 	distdir
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
@@ -111,6 +171,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -195,6 +256,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -323,14 +385,13 @@ clean-libtool:
 # (1) if the variable is set in 'config.status', edit 'config.status'
 #     (which will cause the Makefiles to be regenerated when you run 'make');
 # (2) otherwise, pass the desired values on the 'make' command line.
-$(RECURSIVE_TARGETS) $(RECURSIVE_CLEAN_TARGETS):
-	@fail= failcom='exit 1'; \
-	for f in x $$MAKEFLAGS; do \
-	  case $$f in \
-	    *=* | --[!k]*);; \
-	    *k*) failcom='fail=yes';; \
-	  esac; \
-	done; \
+$(am__recursive_targets):
+	@fail=; \
+	if $(am__make_keepgoing); then \
+	  failcom='fail=yes'; \
+	else \
+	  failcom='exit 1'; \
+	fi; \
 	dot_seen=no; \
 	target=`echo $@ | sed s/-recursive//`; \
 	case "$@" in \
@@ -351,31 +412,13 @@ $(RECURSIVE_TARGETS) $(RECURSIVE_CLEAN_TARGETS):
 	if test "$$dot_seen" = "no"; then \
 	  $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
 	fi; test -z "$$fail"
-tags-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
-	done
-ctags-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
-	done
-cscopelist-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) cscopelist); \
-	done
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-recursive
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
@@ -391,12 +434,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
 	  fi; \
 	done; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -408,15 +446,11 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-recursive
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -425,9 +459,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-recursive
 
-cscopelist: cscopelist-recursive $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -599,24 +634,21 @@ ps-am:
 
 uninstall-am:
 
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) \
-	cscopelist-recursive ctags-recursive install-am install-strip \
-	tags-recursive
+.MAKE: $(am__recursive_targets) install-am install-strip
 
-.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
-	all all-am check check-am clean clean-generic clean-libtool \
-	cscopelist cscopelist-recursive ctags ctags-recursive \
-	distclean distclean-generic distclean-libtool distclean-tags \
-	distdir dvi dvi-am html html-am info info-am install \
-	install-am install-data install-data-am install-dvi \
+.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \
+	check-am clean clean-generic clean-libtool cscopelist-am ctags \
+	ctags-am distclean distclean-generic distclean-libtool \
+	distclean-tags distdir dvi dvi-am html html-am info info-am \
+	install install-am install-data install-data-am install-dvi \
 	install-dvi-am install-exec install-exec-am install-html \
 	install-html-am install-info install-info-am install-man \
 	install-pdf install-pdf-am install-ps install-ps-am \
 	install-strip installcheck installcheck-am installcheck-local \
 	installdirs installdirs-am maintainer-clean \
 	maintainer-clean-generic mostlyclean mostlyclean-generic \
-	mostlyclean-libtool pdf pdf-am ps ps-am tags tags-recursive \
-	uninstall uninstall-am
+	mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \
+	uninstall-am
 
 
 installcheck-local:
diff --git a/hdf/fortran/examples/CMakeLists.txt b/hdf/fortran/examples/CMakeLists.txt
index 86be112..e0436ea 100644
--- a/hdf/fortran/examples/CMakeLists.txt
+++ b/hdf/fortran/examples/CMakeLists.txt
@@ -8,12 +8,12 @@ PROJECT (HDF4_HDF_FORTRAN_EXAMPLES C CXX Fortran)
 #-----------------------------------------------------------------------------
 # Add debug information (intel Fortran : JB)
 #-----------------------------------------------------------------------------
-IF (CMAKE_Fortran_COMPILER MATCHES ifort)
-  IF (WIN32)
-    SET (CMAKE_Fortran_FLAGS_DEBUG "/debug:full /dbglibs " CACHE "flags" STRING FORCE)
-    SET (CMAKE_EXE_LINKER_FLAGS_DEBUG "/DEBUG" CACHE "flags" STRING FORCE)
-  ENDIF (WIN32)
-ENDIF (CMAKE_Fortran_COMPILER MATCHES ifort)
+if (CMAKE_Fortran_COMPILER MATCHES ifort)
+  if (WIN32)
+    set (CMAKE_Fortran_FLAGS_DEBUG "/debug:full /dbglibs " CACHE "flags" STRING FORCE)
+    set (CMAKE_EXE_LINKER_FLAGS_DEBUG "/DEBUG" CACHE "flags" STRING FORCE)
+  endif (WIN32)
+endif (CMAKE_Fortran_COMPILER MATCHES ifort)
 
 #-----------------------------------------------------------------------------
 # Setup include Directories
@@ -33,7 +33,7 @@ LINK_DIRECTORIES (
 #-----------------------------------------------------------------------------
 # Define Sources
 #-----------------------------------------------------------------------------
-SET (examples
+set (examples
     VD_create_vdatas 
     VD_write_mixed_vdata
     VD_write_to_vdata 
@@ -60,35 +60,35 @@ SET (examples
     AN_read_annotation
     #VD_set_get_vdata_attr
 )
-SET (mf_examples
+set (mf_examples
     VG_add_sds_to_vgroup
 )
-SET (skip_examples
+set (skip_examples
     VD_set_get_vdata_attr
 )
 
-FOREACH (example ${examples})
+foreach (example ${examples})
   ADD_EXECUTABLE (f_ex_${example} ${HDF4_HDF_FORTRAN_EXAMPLES_SOURCE_DIR}/${example}.f)
   TARGET_NAMING (f_ex_${example} ${LIB_TYPE})
   TARGET_FORTRAN_PROPERTIES (f_ex_${example} " " " ")
-  SET_TARGET_PROPERTIES (f_ex_${example} PROPERTIES LINKER_LANGUAGE Fortran)
-  TARGET_LINK_LIBRARIES (f_ex_${example} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDFOREACH (example ${examples})
+  set_target_properties (f_ex_${example} PROPERTIES LINKER_LANGUAGE Fortran)
+  target_link_libraries (f_ex_${example} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endforeach (example ${examples})
 
 ADD_EXECUTABLE (f_ex_VG_add_sds_to_vgroup ${HDF4_HDF_FORTRAN_EXAMPLES_SOURCE_DIR}/VG_add_sds_to_vgroup.f)
 TARGET_NAMING (f_ex_VG_add_sds_to_vgroup ${LIB_TYPE})
 TARGET_FORTRAN_PROPERTIES (f_ex_VG_add_sds_to_vgroup " " " ")
-SET_TARGET_PROPERTIES (f_ex_VG_add_sds_to_vgroup PROPERTIES LINKER_LANGUAGE Fortran)
-TARGET_LINK_LIBRARIES (f_ex_VG_add_sds_to_vgroup ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+set_target_properties (f_ex_VG_add_sds_to_vgroup PROPERTIES LINKER_LANGUAGE Fortran)
+target_link_libraries (f_ex_VG_add_sds_to_vgroup ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
-FOREACH (example ${skip_examples})
+foreach (example ${skip_examples})
   ADD_EXECUTABLE (f_ex_${example} ${HDF4_HDF_FORTRAN_EXAMPLES_SOURCE_DIR}/${example}.f)
   TARGET_NAMING (f_ex_${example} ${LIB_TYPE})
   TARGET_FORTRAN_PROPERTIES (f_ex_${example} " " " ")
-  SET_TARGET_PROPERTIES (f_ex_${example} PROPERTIES LINKER_LANGUAGE Fortran)
-  TARGET_LINK_LIBRARIES (f_ex_${example} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDFOREACH (example ${skip_examples})
+  set_target_properties (f_ex_${example} PROPERTIES LINKER_LANGUAGE Fortran)
+  target_link_libraries (f_ex_${example} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endforeach (example ${skip_examples})
 
-IF (BUILD_TESTING)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING)
+if (BUILD_TESTING)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING)
diff --git a/hdf/fortran/examples/CMakeTests.cmake b/hdf/fortran/examples/CMakeTests.cmake
index bb44f8d..d6f8bc2 100644
--- a/hdf/fortran/examples/CMakeTests.cmake
+++ b/hdf/fortran/examples/CMakeTests.cmake
@@ -6,7 +6,7 @@
 ##############################################################################
 
 # Remove any output file left over from previous test run
-ADD_TEST (
+add_test (
     NAME HDF_FORTRAN_EXAMPLES-clearall-objects
     COMMAND    ${CMAKE_COMMAND}
         -E remove 
@@ -19,31 +19,31 @@ ADD_TEST (
         Two_Vdatas.hdf
         Two_Vgroups.hdf
 )
-IF (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (HDF_FORTRAN_EXAMPLES-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS EXAMPLES)
-ELSE (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (HDF_FORTRAN_EXAMPLES-clearall-objects PROPERTIES LABELS EXAMPLES)
-ENDIF (NOT "${last_test}" STREQUAL "")
-SET (last_test "HDF_FORTRAN_EXAMPLES-clearall-objects")
+if (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (HDF_FORTRAN_EXAMPLES-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS EXAMPLES)
+else (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (HDF_FORTRAN_EXAMPLES-clearall-objects PROPERTIES LABELS EXAMPLES)
+endif (NOT "${last_test}" STREQUAL "")
+set (last_test "HDF_FORTRAN_EXAMPLES-clearall-objects")
 
-FOREACH (example ${examples})
-  ADD_TEST (NAME f_extest_${example} COMMAND $<TARGET_FILE:f_ex_${example}>)
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (f_extest_${example} PROPERTIES DEPENDS ${last_test} LABELS EXAMPLES)
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (f_extest_${example} PROPERTIES LABELS EXAMPLES)
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "f_extest_${example}")
-ENDFOREACH (example ${examples})
+foreach (example ${examples})
+  add_test (NAME f_extest_${example} COMMAND $<TARGET_FILE:f_ex_${example}>)
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (f_extest_${example} PROPERTIES DEPENDS ${last_test} LABELS EXAMPLES)
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (f_extest_${example} PROPERTIES LABELS EXAMPLES)
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "f_extest_${example}")
+endforeach (example ${examples})
 
-ADD_TEST (NAME f_extest_VG_add_sds_to_vgroup COMMAND $<TARGET_FILE:f_ex_VG_add_sds_to_vgroup>)
-IF (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (f_extest_VG_add_sds_to_vgroup PROPERTIES DEPENDS ${last_test} LABELS EXAMPLES)
-ELSE (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (f_extest_VG_add_sds_to_vgroup PROPERTIES LABELS EXAMPLES)
-ENDIF (NOT "${last_test}" STREQUAL "")
-SET (last_test "f_extest_VG_add_sds_to_vgroup")
+add_test (NAME f_extest_VG_add_sds_to_vgroup COMMAND $<TARGET_FILE:f_ex_VG_add_sds_to_vgroup>)
+if (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (f_extest_VG_add_sds_to_vgroup PROPERTIES DEPENDS ${last_test} LABELS EXAMPLES)
+else (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (f_extest_VG_add_sds_to_vgroup PROPERTIES LABELS EXAMPLES)
+endif (NOT "${last_test}" STREQUAL "")
+set (last_test "f_extest_VG_add_sds_to_vgroup")
 
-FOREACH (example ${skip_examples})
-  ADD_TEST (NAME f_extest_${example} COMMAND ${CMAKE_COMMAND} -E echo "SKIP f_extest_${example}")
-ENDFOREACH (example ${skip_examples})
+foreach (example ${skip_examples})
+  add_test (NAME f_extest_${example} COMMAND ${CMAKE_COMMAND} -E echo "SKIP f_extest_${example}")
+endforeach (example ${skip_examples})
diff --git a/hdf/fortran/examples/GR_get_attribute.f b/hdf/fortran/examples/GR_get_attribute.f
index 061c52d..a875c3e 100644
--- a/hdf/fortran/examples/GR_get_attribute.f
+++ b/hdf/fortran/examples/GR_get_attribute.f
@@ -51,6 +51,7 @@ C
 C
 C        Get information about the current file attribute.
 C 
+         attr_name = ' '
          status = mgatinf(gr_id, f_att_index, attr_name, data_type,
      +                    n_values)
 C
diff --git a/hdf/fortran/examples/GR_image_info.f b/hdf/fortran/examples/GR_image_info.f
index c0fb436..ab7c484 100644
--- a/hdf/fortran/examples/GR_image_info.f
+++ b/hdf/fortran/examples/GR_image_info.f
@@ -45,6 +45,7 @@ C     For each image in the file, get and display image information.
 C
       do 100 ri_index = 0, n_rimages-1
          ri_id = mgselct(gr_id, ri_index)
+         name = ' '
          status = mggiinf(ri_id, name, n_comps, data_type,
      +                    interlace_mode, dim_sizes, n_attrs)
 C
diff --git a/hdf/fortran/examples/Makefile.in b/hdf/fortran/examples/Makefile.in
index 05b6f9d..e255fac 100644
--- a/hdf/fortran/examples/Makefile.in
+++ b/hdf/fortran/examples/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -21,23 +21,51 @@
 # built using h4cc (or h4fc, etc.) instead of the standard compilers.
 # This creates some extra work for us.
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -56,11 +84,11 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am \
-	$(top_srcdir)/config/examples.am
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/examples.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
+	$(top_srcdir)/bin/test-driver
 TESTS = $(TEST_PROG)
 subdir = hdf/fortran/examples
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -71,6 +99,18 @@ mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs
 CONFIG_HEADER = $(top_builddir)/hdf/src/h4config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 SOURCES =
 DIST_SOURCES =
 am__can_run_installinfo = \
@@ -78,13 +118,213 @@ am__can_run_installinfo = \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+  test -z "$$files" \
+    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+         $(am__cd) "$$dir" && rm -f $$files; }; \
+  }
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
+TEST_SUITE_LOG = test-suite.log
+LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -169,6 +409,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -316,6 +557,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
+.SUFFIXES: .log .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/examples.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -353,15 +595,326 @@ mostlyclean-libtool:
 
 clean-libtool:
 	-rm -rf .libs _libs
-tags: TAGS
-TAGS:
+tags TAGS:
 
-ctags: CTAGS
-CTAGS:
+ctags CTAGS:
 
 cscope cscopelist:
 
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all 
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+VD_create_vdatas.log: VD_create_vdatas
+	@p='VD_create_vdatas'; \
+	b='VD_create_vdatas'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_write_mixed_vdata.log: VD_write_mixed_vdata
+	@p='VD_write_mixed_vdata'; \
+	b='VD_write_mixed_vdata'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_write_to_vdata.log: VD_write_to_vdata
+	@p='VD_write_to_vdata'; \
+	b='VD_write_to_vdata'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_create_onefield_vdatas.log: VD_create_onefield_vdatas
+	@p='VD_create_onefield_vdatas'; \
+	b='VD_create_onefield_vdatas'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_read_from_vdata.log: VD_read_from_vdata
+	@p='VD_read_from_vdata'; \
+	b='VD_read_from_vdata'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_read_mixed_vdata.log: VD_read_mixed_vdata
+	@p='VD_read_mixed_vdata'; \
+	b='VD_read_mixed_vdata'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_get_vdata_info.log: VD_get_vdata_info
+	@p='VD_get_vdata_info'; \
+	b='VD_get_vdata_info'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VD_locate_vdata.log: VD_locate_vdata
+	@p='VD_locate_vdata'; \
+	b='VD_locate_vdata'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VG_create_vgroup.log: VG_create_vgroup
+	@p='VG_create_vgroup'; \
+	b='VG_create_vgroup'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VG_add_sds_to_vgroup.log: VG_add_sds_to_vgroup
+	@p='VG_add_sds_to_vgroup'; \
+	b='VG_add_sds_to_vgroup'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VG_insert_vdatas_to_vgroup.log: VG_insert_vdatas_to_vgroup
+	@p='VG_insert_vdatas_to_vgroup'; \
+	b='VG_insert_vdatas_to_vgroup'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VG_set_get_vgroup_attr.log: VG_set_get_vgroup_attr
+	@p='VG_set_get_vgroup_attr'; \
+	b='VG_set_get_vgroup_attr'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VG_vgroup_contents.log: VG_vgroup_contents
+	@p='VG_vgroup_contents'; \
+	b='VG_vgroup_contents'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+VG_get_vgroup_info.log: VG_get_vgroup_info
+	@p='VG_get_vgroup_info'; \
+	b='VG_get_vgroup_info'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_create_and_write_image.log: GR_create_and_write_image
+	@p='GR_create_and_write_image'; \
+	b='GR_create_and_write_image'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_modify_image.log: GR_modify_image
+	@p='GR_modify_image'; \
+	b='GR_modify_image'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_set_attribute.log: GR_set_attribute
+	@p='GR_set_attribute'; \
+	b='GR_set_attribute'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_get_attribute.log: GR_get_attribute
+	@p='GR_get_attribute'; \
+	b='GR_get_attribute'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_write_palette.log: GR_write_palette
+	@p='GR_write_palette'; \
+	b='GR_write_palette'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_image_info.log: GR_image_info
+	@p='GR_image_info'; \
+	b='GR_image_info'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+GR_read_image.log: GR_read_image
+	@p='GR_read_image'; \
+	b='GR_read_image'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+AN_create_annotation.log: AN_create_annotation
+	@p='AN_create_annotation'; \
+	b='AN_create_annotation'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+AN_get_annotation_info.log: AN_get_annotation_info
+	@p='AN_get_annotation_info'; \
+	b='AN_get_annotation_info'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+AN_read_annotation.log: AN_read_annotation
+	@p='AN_read_annotation'; \
+	b='AN_read_annotation'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -418,6 +971,9 @@ install-strip:
 	fi
 mostlyclean-generic:
 	-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 	-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
@@ -500,17 +1056,18 @@ uninstall-am: uninstall-local
 .MAKE: check-am install-am install-strip
 
 .PHONY: all all-am all-local check check-TESTS check-am clean \
-	clean-generic clean-libtool distclean distclean-generic \
-	distclean-libtool distdir dvi dvi-am html html-am info info-am \
-	install install-am install-data install-data-am \
-	install-data-local install-dvi install-dvi-am install-exec \
-	install-exec-am install-html install-html-am install-info \
-	install-info-am install-man install-pdf install-pdf-am \
-	install-ps install-ps-am install-strip installcheck \
-	installcheck-am installcheck-local installdirs \
+	clean-generic clean-libtool cscopelist-am ctags-am distclean \
+	distclean-generic distclean-libtool distdir dvi dvi-am html \
+	html-am info info-am install install-am install-data \
+	install-data-am install-data-local install-dvi install-dvi-am \
+	install-exec install-exec-am install-html install-html-am \
+	install-info install-info-am install-man install-pdf \
+	install-pdf-am install-ps install-ps-am install-strip \
+	installcheck installcheck-am installcheck-local installdirs \
 	maintainer-clean maintainer-clean-generic mostlyclean \
 	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
-	pdf-am ps ps-am uninstall uninstall-am uninstall-local
+	pdf-am ps ps-am recheck tags-am uninstall uninstall-am \
+	uninstall-local
 
     # VD_set_get_vdata_attr
 
diff --git a/hdf/fortran/examples/VD_get_vdata_info.f b/hdf/fortran/examples/VD_get_vdata_info.f
index 3f1e8ae..b074242 100644
--- a/hdf/fortran/examples/VD_get_vdata_info.f
+++ b/hdf/fortran/examples/VD_get_vdata_info.f
@@ -59,18 +59,25 @@ C
 C     Test whether the current vdata is not a storage for an attribute,
 C     then obtain and display its information.
       if (vsfisat(vdata_id) .ne. 1) then
+C     Initialize buffers before getting values back.
+          vdata_name = ' ' 
+          fieldname_list = ' '
+          n_records = -1 
+          vdata_size = -1 
           status = vsfinq(vdata_id, n_records, interlace_mode,
      +                    fieldname_list, vdata_size, vdata_name)
-          write(*,*) 'Vdata: ', vdata_name
-          write(*,*) 'contains ', n_records, ' records'
-          if (interlace_mode .eq. 0) then
-              write(*,*) 'Interlace mode: FULL'
-          else	 
-              write(*,*) 'Interlace mode: NONE'
+          if (status .eq. 0) then
+             write(*,*) 'Vdata: ', vdata_name
+             write(*,*) 'contains ', n_records, ' records'
+             if (interlace_mode .eq. 0) then
+                 write(*,*) 'Interlace mode: FULL'
+             else	 
+                 write(*,*) 'Interlace mode: NONE'
+             endif
+             write(*,*) 'Fields: ', fieldname_list(1:30)
+             write(*,*) 'Vdata record size in bytes :', vdata_size
+             write(*,*)
           endif
-          write(*,*) 'Fields: ', fieldname_list(1:30)
-          write(*,*) 'Vdata record size in bytes :', vdata_size
-          write(*,*)
       endif
 C
 C     Detach from the current vdata.
diff --git a/hdf/fortran/examples/VG_set_get_vgroup_attr.f b/hdf/fortran/examples/VG_set_get_vgroup_attr.f
index cb14aa1..8b5de4a 100644
--- a/hdf/fortran/examples/VG_set_get_vgroup_attr.f
+++ b/hdf/fortran/examples/VG_set_get_vgroup_attr.f
@@ -84,6 +84,7 @@ C
 C     Get and display the name and the number of values of each attribute.
 C
       do 10 attr_index=1, n_attrs
+         attr_name = ' '
          status = vfainfo(vgroup_id, attr_index-1, attr_name, data_type,
      +                    n_values, size)
       write(*,*) 'Attribute #', attr_index-1, ' is named ', attr_name
diff --git a/hdf/src/CMakeLists.txt b/hdf/src/CMakeLists.txt
index 67f1f73..e684424 100644
--- a/hdf/src/CMakeLists.txt
+++ b/hdf/src/CMakeLists.txt
@@ -13,7 +13,7 @@ LINK_DIRECTORIES (
     ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
 )
 
-SET (HDF4_HDF_SRC_CSRCS
+set (HDF4_HDF_SRC_CSRCS
     ${HDF4_HDF_SRC_SOURCE_DIR}/atom.c
     ${HDF4_HDF_SRC_SOURCE_DIR}/bitvect.c
     ${HDF4_HDF_SRC_SOURCE_DIR}/cdeflate.c
@@ -72,7 +72,7 @@ SET (HDF4_HDF_SRC_CSRCS
     ${HDF4_HDF_SRC_SOURCE_DIR}/vsfld.c
 )
 
-SET (HDF4_HDF_SRC_CHDRS
+set (HDF4_HDF_SRC_CHDRS
     ${HDF4_HDF_SRC_SOURCE_DIR}/atom.h
     ${HDF4_HDF_SRC_SOURCE_DIR}/bitvect.h
     ${HDF4_HDF_SRC_SOURCE_DIR}/cdeflate.h
@@ -120,13 +120,13 @@ SET (HDF4_HDF_SRC_CHDRS
     ${HDF4_HDF_SRC_SOURCE_DIR}/vgint.h
 )
 
-ADD_LIBRARY (${HDF4_SRC_LIB_TARGET} ${LIB_TYPE} ${HDF4_HDF_SRC_CSRCS} ${HDF4_HDF_SRC_CHDRS} ${HDF4_BINARY_DIR}/h4config.h)
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS)
-ENDIF (WIN32 AND NOT CYGWIN)
+add_library (${HDF4_SRC_LIB_TARGET} ${LIB_TYPE} ${HDF4_HDF_SRC_CSRCS} ${HDF4_HDF_SRC_CHDRS} ${HDF4_BINARY_DIR}/h4config.h)
+if (WIN32)
+  add_definitions (-DDOS_FS)
+endif (WIN32)
 TARGET_C_PROPERTIES (${HDF4_SRC_LIB_TARGET} " " " ")
-TARGET_LINK_LIBRARIES (${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-SET_GLOBAL_VARIABLE (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_SRC_LIB_TARGET}")
+target_link_libraries (${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+set_global_variable (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_SRC_LIB_TARGET}")
 H4_SET_LIB_OPTIONS (${HDF4_SRC_LIB_TARGET} ${HDF4_SRC_LIB_NAME} ${LIB_TYPE})
 
 #-----------------------------------------------------------------------------
@@ -144,10 +144,10 @@ INSTALL (
 #-----------------------------------------------------------------------------
 # Add Target(s) to CMake Install for import into other projects
 #-----------------------------------------------------------------------------
-IF (HDF4_EXPORTED_TARGETS)
-  IF (BUILD_SHARED_LIBS)
+if (HDF4_EXPORTED_TARGETS)
+  if (BUILD_SHARED_LIBS)
     INSTALL_TARGET_PDB (${HDF4_SRC_LIB_TARGET} ${HDF4_INSTALL_LIB_DIR} libraries)
-  ENDIF (BUILD_SHARED_LIBS)
+  endif (BUILD_SHARED_LIBS)
   
   INSTALL (
       TARGETS 
@@ -158,5 +158,5 @@ IF (HDF4_EXPORTED_TARGETS)
       ARCHIVE DESTINATION ${HDF4_INSTALL_LIB_DIR} COMPONENT libraries
       RUNTIME DESTINATION ${HDF4_INSTALL_BIN_DIR} COMPONENT libraries
   )
-ENDIF (HDF4_EXPORTED_TARGETS)
+endif (HDF4_EXPORTED_TARGETS)
 
diff --git a/hdf/src/H4api_adpt.h b/hdf/src/H4api_adpt.h
index e3f7f55..4ce355a 100644
--- a/hdf/src/H4api_adpt.h
+++ b/hdf/src/H4api_adpt.h
@@ -29,7 +29,7 @@
 #if defined(H4_BUILT_AS_DYNAMIC_LIB)
 
 #if defined(xdr_EXPORTS)
-  #if defined (_MSC_VER)  /* MSVC Compiler Case */
+  #if defined (_MSC_VER) || defined(__MINGW32__) /* MSVC Compiler Case */
     #define XDRLIBAPI extern __declspec(dllexport)
   #elif (__GNUC__ >= 4)  /* GCC 4.x has support for visibility options */
     #define XDRLIBAPI extern __attribute__ ((visibility("default")))
@@ -37,7 +37,7 @@
 #endif /* xdr_EXPORTS */
 
 #if defined(hdf_EXPORTS)
-  #if defined (_MSC_VER)  /* MSVC Compiler Case */
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
     #define HDFERRPUBLIC __declspec(dllimport)
     #define HDFPUBLIC __declspec(dllexport)
     #define HDFLIBAPI extern __declspec(dllexport)
@@ -51,7 +51,7 @@
 #endif /* hdf_EXPORTS */
 
 #if defined(hdf_fcstub_EXPORTS)
-  #if defined (_MSC_VER)  /* MSVC Compiler Case */
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
     #define HDFPUBLIC __declspec(dllexport)
     #define HDFLIBAPI extern __declspec(dllimport)
     #define HDFFCLIBAPI extern __declspec(dllexport)
@@ -63,7 +63,7 @@
 #endif /* hdf_fcstub_EXPORTS */
 
 #if defined(mfhdf_EXPORTS)
-  #if defined (_MSC_VER)  /* MSVC Compiler Case */
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
     #define HDFERRPUBLIC extern __declspec(dllimport)
     #define HDFPUBLIC __declspec(dllimport)
     #define HDFLIBAPI extern __declspec(dllexport)
@@ -77,7 +77,7 @@
 #endif /* mfhdf_EXPORTS */
 
 #if defined(mfhdf_fcstub_EXPORTS)
-  #if defined (_MSC_VER)  /* MSVC Compiler Case */
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
     #define HDFPUBLIC __declspec(dllimport)
     #define HDFLIBAPI extern __declspec(dllimport)
     #define HDFFCLIBAPI extern __declspec(dllexport)
@@ -89,48 +89,79 @@
 #endif /* mfhdf_fcstub_EXPORTS */
 
 #if defined(hdf_test_fcstub_EXPORTS)
-  #if defined (_MSC_VER)  /* MSVC Compiler Case */
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
     #define HDFFCLIBAPI extern __declspec(dllexport)
   #elif (__GNUC__ >= 4)  /* GCC 4.x has support for visibility options */
     #define HDFFCLIBAPI extern __attribute__ ((visibility("default")))
   #endif
 #endif/* hdf_test_fcstub_EXPORTS */
 
+#if defined(mfhdf_hdiff_EXPORTS)
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
+    #define HDFPUBLIC __declspec(dllimport)
+    #define HDFLIBAPI extern __declspec(dllimport)
+    #define HDFTOOLSAPI extern __declspec(dllexport)
+  #elif (__GNUC__ >= 4)  /* GCC 4.x has support for visibility options */
+    #define HDFPUBLIC __attribute__ ((visibility("default")))
+    #define HDFLIBAPI extern __attribute__ ((visibility("default")))
+    #define HDFTOOLSAPI extern __attribute__ ((visibility("default")))
+  #endif
+#endif /* mfhdf_hdiff_EXPORTS */
+
+#if defined(mfhdf_hrepack_EXPORTS)
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
+    #define HDFPUBLIC __declspec(dllimport)
+    #define HDFLIBAPI extern __declspec(dllimport)
+    #define HDFTOOLSAPI extern __declspec(dllexport)
+  #elif (__GNUC__ >= 4)  /* GCC 4.x has support for visibility options */
+    #define HDFPUBLIC __attribute__ ((visibility("default")))
+    #define HDFLIBAPI extern __attribute__ ((visibility("default")))
+    #define HDFTOOLSAPI extern __attribute__ ((visibility("default")))
+  #endif
+#endif /* mfhdf_hrepack_EXPORTS */
+
 #if !defined(XDRLIBAPI)
-  #if defined (_MSC_VER)  /* MSVC Compiler Case */
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
     #define XDRLIBAPI extern __declspec(dllimport)
   #elif (__GNUC__ >= 4)  /* GCC 4.x has support for visibility options */
     #define XDRLIBAPI extern __attribute__ ((visibility("default")))
   #endif
 #endif
 #if !defined(HDFERRPUBLIC)
-  #if defined (_MSC_VER)  /* MSVC Compiler Case */
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
     #define HDFERRPUBLIC extern __declspec(dllimport)
   #elif (__GNUC__ >= 4)  /* GCC 4.x has support for visibility options */
     #define HDFERRPUBLIC extern __attribute__ ((visibility("default")))
   #endif
 #endif
 #if !defined(HDFPUBLIC)
-  #if defined (_MSC_VER)  /* MSVC Compiler Case */
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
     #define HDFPUBLIC __declspec(dllimport)
   #elif (__GNUC__ >= 4)  /* GCC 4.x has support for visibility options */
     #define HDFPUBLIC __attribute__ ((visibility("default")))
   #endif
 #endif
 #if !defined(HDFLIBAPI)
-  #if defined (_MSC_VER)  /* MSVC Compiler Case */
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
     #define HDFLIBAPI extern __declspec(dllimport)
   #elif (__GNUC__ >= 4)  /* GCC 4.x has support for visibility options */
     #define HDFLIBAPI extern __attribute__ ((visibility("default")))
   #endif
 #endif
 #if !defined(HDFFCLIBAPI)
-  #if defined (_MSC_VER)  /* MSVC Compiler Case */
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
     #define HDFFCLIBAPI extern __declspec(dllimport)
   #elif (__GNUC__ >= 4)  /* GCC 4.x has support for visibility options */
     #define HDFFCLIBAPI extern __attribute__ ((visibility("default")))
   #endif
 #endif
+#if !defined(HDFTOOLSAPI)
+  #if defined (_MSC_VER) || defined(__MINGW32__)  /* MSVC Compiler Case */
+    #define HDFTOOLSAPI extern __declspec(dllimport)
+  #elif (__GNUC__ >= 4)  /* GCC 4.x has support for visibility options */
+    #define HDFTOOLSAPI extern __attribute__ ((visibility("default")))
+  #endif
+#endif
 
 #elif defined(H4_BUILT_AS_STATIC_LIB)
   #define XDRLIBAPI extern
@@ -138,6 +169,7 @@
   #define HDFPUBLIC
   #define HDFLIBAPI extern
   #define HDFFCLIBAPI extern
+  #define HDFTOOLSAPI extern
 
 #else
 /* This is the original HDFGroup defined preprocessor code which should still work
@@ -198,6 +230,9 @@
 #    if !defined(HDFFCLIBAPI)
 #      define HDFFCLIBAPI extern __declspec(dllimport)
 #    endif
+#    if !defined(HDFTOOLSAPI)
+#      define HDFTOOLSAPI extern __declspec(dllimport)
+#    endif
 
 #  else
 #    define XDRLIBAPI extern
@@ -205,6 +240,7 @@
 #    define HDFPUBLIC
 #    define HDFLIBAPI extern
 #    define HDFFCLIBAPI extern
+#    define HDFTOOLSAPI extern
 #  endif
 #else  /* !defined( _WIN32 ) */
 #  define XDRLIBAPI extern
@@ -212,6 +248,7 @@
 #  define HDFPUBLIC
 #  define HDFLIBAPI extern
 #  define HDFFCLIBAPI extern
+#  define HDFTOOLSAPI extern
 #endif
 
 #endif /*H4_BUILT_AS_DYNAMIC_LIB  */
diff --git a/hdf/src/Makefile.in b/hdf/src/Makefile.in
index bfdd6e7..300567b 100644
--- a/hdf/src/Makefile.in
+++ b/hdf/src/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -19,23 +19,51 @@
 
 
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -54,13 +82,13 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(am__include_HEADERS_DIST) $(srcdir)/Makefile.am \
-	$(srcdir)/Makefile.in $(srcdir)/h4config.h.in \
-	$(top_srcdir)/bin/depcomp $(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am
-F77LINK = $(LIBTOOL) --tag=F77 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(F77LD) $(AM_FFLAGS) $(FFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+DIST_COMMON = $(top_srcdir)/config/commence.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(srcdir)/h4config.h.in \
+	$(top_srcdir)/bin/mkinstalldirs $(top_srcdir)/bin/depcomp \
+	$(am__include_HEADERS_DIST)
+F77LINK = $(LIBTOOL) $(AM_V_lt) --tag=F77 $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(F77LD) $(AM_FFLAGS) $(FFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
 subdir = hdf/src
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 am__aclocal_m4_deps = $(top_srcdir)/configure.ac
@@ -132,23 +160,56 @@ am__objects_2 = df24ff.lo dfanf.lo dfanff.lo dff.lo dfff.lo dfpf.lo \
 @HDF_BUILD_FORTRAN_TRUE at am_libdf_la_OBJECTS = $(am__objects_1) \
 @HDF_BUILD_FORTRAN_TRUE@	$(am__objects_2)
 libdf_la_OBJECTS = $(am_libdf_la_OBJECTS)
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 F77COMPILE = $(F77) $(AM_FFLAGS) $(FFLAGS)
-LTF77COMPILE = $(LIBTOOL) --tag=F77 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(F77) $(AM_FFLAGS) $(FFLAGS)
+LTF77COMPILE = $(LIBTOOL) $(AM_V_lt) --tag=F77 $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(F77) $(AM_FFLAGS) $(FFLAGS)
+AM_V_F77 = $(am__v_F77_ at AM_V@)
+am__v_F77_ = $(am__v_F77_ at AM_DEFAULT_V@)
+am__v_F77_0 = @echo "  F77     " $@;
+am__v_F77_1 = 
 F77LD = $(F77)
+AM_V_F77LD = $(am__v_F77LD_ at AM_V@)
+am__v_F77LD_ = $(am__v_F77LD_ at AM_DEFAULT_V@)
+am__v_F77LD_0 = @echo "  F77LD   " $@;
+am__v_F77LD_1 = 
 SOURCES = $(libdf_la_SOURCES)
 DIST_SOURCES = $(am__libdf_la_SOURCES_DIST)
 am__can_run_installinfo = \
@@ -165,11 +226,30 @@ am__include_HEADERS_DIST = atom.h bitvect.h cdeflate.h cnbit.h cnone.h \
 	hdatainfo.h hproto_fortran.h dffunc.f90 hdf.f90 dffunc.inc \
 	hdf.inc
 HEADERS = $(include_HEADERS)
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) \
+	$(LISP)h4config.h.in
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -254,6 +334,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -406,8 +487,8 @@ $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
 $(am__aclocal_m4_deps):
 
 h4config.h: stamp-h1
-	@if test ! -f $@; then rm -f stamp-h1; else :; fi
-	@if test ! -f $@; then $(MAKE) $(AM_MAKEFLAGS) stamp-h1; else :; fi
+	@test -f $@ || rm -f stamp-h1
+	@test -f $@ || $(MAKE) $(AM_MAKEFLAGS) stamp-h1
 
 stamp-h1: $(srcdir)/h4config.h.in $(top_builddir)/config.status
 	@rm -f stamp-h1
@@ -419,6 +500,7 @@ $(srcdir)/h4config.h.in: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
 
 distclean-hdr:
 	-rm -f h4config.h stamp-h1
+
 install-libLTLIBRARIES: $(lib_LTLIBRARIES)
 	@$(NORMAL_INSTALL)
 	@list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
@@ -453,8 +535,9 @@ clean-libLTLIBRARIES:
 	  echo rm -f $${locs}; \
 	  rm -f $${locs}; \
 	}
+
 libdf.la: $(libdf_la_OBJECTS) $(libdf_la_DEPENDENCIES) $(EXTRA_libdf_la_DEPENDENCIES) 
-	$(F77LINK) -rpath $(libdir) $(libdf_la_OBJECTS) $(libdf_la_LIBADD) $(LIBS)
+	$(AM_V_F77LD)$(F77LINK) -rpath $(libdir) $(libdf_la_OBJECTS) $(libdf_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -534,34 +617,34 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/vsfld.Plo at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 .f.o:
-	$(F77COMPILE) -c -o $@ $<
+	$(AM_V_F77)$(F77COMPILE) -c -o $@ $<
 
 .f.obj:
-	$(F77COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
+	$(AM_V_F77)$(F77COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f.lo:
-	$(LTF77COMPILE) -c -o $@ $<
+	$(AM_V_F77)$(LTF77COMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -590,26 +673,15 @@ uninstall-includeHEADERS:
 	files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
 	dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir)
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES) h4config.h.in $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS) h4config.h.in $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -621,15 +693,11 @@ TAGS:  $(HEADERS) $(SOURCES) h4config.h.in $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES) h4config.h.in $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS) h4config.h.in $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -638,9 +706,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -797,20 +866,20 @@ uninstall-am: uninstall-includeHEADERS uninstall-libLTLIBRARIES
 
 .MAKE: all install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \
-	clean-libLTLIBRARIES clean-libtool cscopelist ctags distclean \
-	distclean-compile distclean-generic distclean-hdr \
-	distclean-libtool distclean-tags distdir dvi dvi-am html \
-	html-am info info-am install install-am install-data \
-	install-data-am install-dvi install-dvi-am install-exec \
-	install-exec-am install-html install-html-am \
+.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \
+	clean-libLTLIBRARIES clean-libtool cscopelist-am ctags \
+	ctags-am distclean distclean-compile distclean-generic \
+	distclean-hdr distclean-libtool distclean-tags distdir dvi \
+	dvi-am html html-am info info-am install install-am \
+	install-data install-data-am install-dvi install-dvi-am \
+	install-exec install-exec-am install-html install-html-am \
 	install-includeHEADERS install-info install-info-am \
 	install-libLTLIBRARIES install-man install-pdf install-pdf-am \
 	install-ps install-ps-am install-strip installcheck \
 	installcheck-am installdirs maintainer-clean \
 	maintainer-clean-generic mostlyclean mostlyclean-compile \
 	mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
-	tags uninstall uninstall-am uninstall-includeHEADERS \
+	tags tags-am uninstall uninstall-am uninstall-includeHEADERS \
 	uninstall-libLTLIBRARIES
 
 
diff --git a/hdf/src/atom.c b/hdf/src/atom.c
index c8c6543..135e1e2 100644
--- a/hdf/src/atom.c
+++ b/hdf/src/atom.c
@@ -12,11 +12,11 @@
  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
 
 #ifdef RCSID
-static char RcsId[] = "@(#)$Revision: 5028 $";
+static char RcsId[] = "@(#)$Revision: 6140 $";
 #endif
 
 
-/* $Id: atom.c 5028 2008-01-27 16:49:37Z bmribler $ */
+/* $Id: atom.c 6140 2014-10-10 02:24:32Z acheng $ */
 
 /*
 FILE
@@ -560,13 +560,17 @@ static atom_info_t *HAIfind_atom(atom_t atm   /* IN: Atom to retrieve atom for *
               break;
           atm_ptr=atm_ptr->next;
       } /* end while */
-    ret_value=atm_ptr;
 
 #ifdef ATOMS_ARE_CACHED
-    atom_id_cache[ATOM_CACHE_SIZE-1]=atm;
-    atom_obj_cache[ATOM_CACHE_SIZE-1]=atm_ptr->obj_ptr;
+    if (atm_ptr){
+	/* if found, add it to the end of the cached list */
+	atom_id_cache[ATOM_CACHE_SIZE-1]=atm;
+	atom_obj_cache[ATOM_CACHE_SIZE-1]=atm_ptr->obj_ptr;
+    }
 #endif /* ATOMS_ARE_CACHED */
 
+    ret_value=atm_ptr;
+
 done:
   if(ret_value == NULL)   
     { /* Error condition cleanup */
diff --git a/hdf/src/bitvect.c b/hdf/src/bitvect.c
index 5679e14..83cbc40 100644
--- a/hdf/src/bitvect.c
+++ b/hdf/src/bitvect.c
@@ -12,10 +12,10 @@
  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
 
 #ifdef RCSID
-static char RcsId[] = "$Revision: 4932 $";
+static char RcsId[] = "$Revision: 6111 $";
 #endif
 
-/* $Id: bitvect.c 4932 2007-09-07 17:17:23Z bmribler $ */
+/* $Id: bitvect.c 6111 2014-06-02 20:52:09Z bmribler $ */
 
 /*
 FILE
@@ -454,12 +454,15 @@ int32 bv_find(bv_ptr b,int32 last_find,bv_bool value)
           if(last_find>=0)
             {   /* if the last bit found option is used, look for more bits in that same byte */
               intn bit_off;
+int unused;
 
               first_byte=(uint32)last_find/BV_BASE_BITS;
               bit_off=(intn)(((uint32)last_find-(first_byte*BV_BASE_BITS))+1);
               slush_bits=(bv_base)(b->buffer[first_byte]&(~bv_bit_mask[bit_off]));
               if(slush_bits!=0)
-                  return((int32)(first_byte*BV_BASE_BITS)+bv_first_zero[~slush_bits]);
+                  return((int32)(first_byte*BV_BASE_BITS)+bv_first_zero[(~slush_bits)]);
+                   /* return((int32)(first_byte*BV_BASE_BITS)+bv_first_zero[(bv_base)(~slush_bits)]);
+ */ 
               first_byte++;
             } /* end if */
 
@@ -474,7 +477,7 @@ int32 bv_find(bv_ptr b,int32 last_find,bv_bool value)
             {
                 slush_bits=(bv_base)(b->buffer[u]&bv_bit_mask[b->bits_used-(bytes_used*BV_BASE_BITS)]);
                 if(slush_bits!=0)
-                    return((int32)(u*BV_BASE_BITS)+bv_first_zero[~slush_bits]);
+                    return((int32)(u*BV_BASE_BITS)+bv_first_zero[(bv_base)(~slush_bits)]);
             } /* end if */
       } /* end if */
     else
diff --git a/hdf/src/hfile.h b/hdf/src/hfile.h
index 1cb7c3a..fb9146e 100644
--- a/hdf/src/hfile.h
+++ b/hdf/src/hfile.h
@@ -11,7 +11,7 @@
  * access to either file, you may request a copy from help at hdfgroup.org.     *
  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
 
-/* $Id: hfile.h 6079 2014-02-08 00:29:03Z bmribler $ */
+/* $Id: hfile.h 6194 2015-02-05 14:17:12Z bmribler $ */
 
 /*+ hfile.h
    *** Header for hfile.c, routines for low level data element I/O
@@ -51,10 +51,10 @@
 
 #define LIBVER_MAJOR    4
 #define LIBVER_MINOR    2 
-#define LIBVER_RELEASE  10 
+#define LIBVER_RELEASE  11 
 #define LIBVER_SUBRELEASE ""   /* For pre-releases like snap0       */
                                 /* Empty string for real releases.           */
-#define LIBVER_STRING   "HDF Version 4.2 Release 10, February 7, 2014"
+#define LIBVER_STRING   "HDF Version 4.2 Release 11, February 5, 2015"
 #define LIBVSTR_LEN    80   /* length of version string  */
 #define LIBVER_LEN  92      /* 4+4+4+80 = 92 */
 /* end of version tags */
diff --git a/hdf/src/mfgr.c b/hdf/src/mfgr.c
index 369e164..4b9b052 100644
--- a/hdf/src/mfgr.c
+++ b/hdf/src/mfgr.c
@@ -12,10 +12,10 @@
  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
 
 #ifdef RCSID
-static char RcsId[] = "$Revision: 5831 $";
+static char RcsId[] = "$Revision: 6135 $";
 #endif
 
-/* $Id: mfgr.c 5831 2012-07-20 07:03:42Z bmribler $ */
+/* $Id: mfgr.c 6135 2014-09-12 00:13:35Z acheng $ */
 
 /*
 FILE
@@ -2815,7 +2815,7 @@ intn GRwriteimage(int32 riid,int32 start[2],int32 in_stride[2],int32 count[2],vo
     {
         /* Check that the compression encoder is available */
         HCget_config_info(comp_type, &comp_config);
-        if ((comp_config & COMP_DECODER_ENABLED|COMP_ENCODER_ENABLED) == 0) {
+        if ((comp_config & (COMP_DECODER_ENABLED|COMP_ENCODER_ENABLED)) == 0) {
             /* coder not present?? */
              HGOTO_ERROR(DFE_BADCODER,FAIL); 
         }
@@ -3294,7 +3294,7 @@ intn GRreadimage(int32 riid,int32 start[2],int32 in_stride[2],int32 count[2],voi
     {   /* This is reading, why do we need encoder? -BMR */
 	/* Check that the compression encoder is available */
 	HCget_config_info(comp_type, &comp_config);
-	if ((comp_config & COMP_DECODER_ENABLED|COMP_ENCODER_ENABLED) == 0)
+	if ((comp_config & (COMP_DECODER_ENABLED|COMP_ENCODER_ENABLED)) == 0)
 	{ /* coder not present?? */
 	    HGOTO_ERROR(DFE_BADCODER,FAIL); 
 	}
@@ -3546,7 +3546,7 @@ intn GRendaccess(int32 riid)
 
     /* Double check on setting the GR modified flag */
     /* Maybe this should be flagged as as error? -QAK */
-    if(ri_ptr->meta_modified==TRUE &&& ri_ptr->gr_ptr->gr_modified==FALSE)
+    if(ri_ptr->meta_modified==TRUE && ri_ptr->gr_ptr->gr_modified==FALSE)
         ri_ptr->gr_ptr->gr_modified=TRUE;
 
     /* Delete the atom for the RI ID */
@@ -4408,7 +4408,7 @@ intn GRsetcompress(int32 riid,comp_coder_t comp_type,comp_info *cinfo)
 
     /* Check that the compression method is enabled */
     HCget_config_info(comp_type, &comp_config);
-    if ((comp_config & COMP_DECODER_ENABLED|COMP_ENCODER_ENABLED) == 0) {
+    if ((comp_config & (COMP_DECODER_ENABLED|COMP_ENCODER_ENABLED)) == 0) {
   /* coder not present?? */
       HGOTO_ERROR(DFE_BADCODER, FAIL);
     }
@@ -5658,7 +5658,7 @@ GRsetchunk(int32 riid,              /* IN: raster access id */
 
     /* Check that the compression encoder is available */
     HCget_config_info((comp_coder_t )(cdef->comp.comp_type), &comp_config);
-    if ((comp_config & COMP_DECODER_ENABLED|COMP_ENCODER_ENABLED) == 0) {
+    if ((comp_config & (COMP_DECODER_ENABLED|COMP_ENCODER_ENABLED)) == 0) {
     /* coder not present?? */
               HGOTO_ERROR(DFE_BADCODER,FAIL); 
     }
@@ -6082,7 +6082,7 @@ GRwritechunk(int32 riid,       /* IN: access aid to GR */
     {
         /* Check that the compression encoder is available */
         HCget_config_info(comp_type, &comp_config);
-        if ((comp_config & COMP_DECODER_ENABLED|COMP_ENCODER_ENABLED) == 0) {
+        if ((comp_config & (COMP_DECODER_ENABLED|COMP_ENCODER_ENABLED)) == 0) {
             /* coder not present?? */
              HGOTO_ERROR(DFE_BADCODER,FAIL); 
         }
@@ -6308,7 +6308,7 @@ GRreadchunk(int32 riid,    /* IN: access aid to GR */
     {   /* BMR: this is reading, why do we need encoder? */
 	/* Check that the compression encoder is available */
 	HCget_config_info(comp_type, &comp_config);
-	if ((comp_config & COMP_DECODER_ENABLED|COMP_ENCODER_ENABLED) == 0) {
+	if ((comp_config & (COMP_DECODER_ENABLED|COMP_ENCODER_ENABLED)) == 0) {
     /* coder not present?? */
          HGOTO_ERROR(DFE_BADCODER,FAIL); 
       }
diff --git a/hdf/src/vgint.h b/hdf/src/vgint.h
index 9950776..06ce972 100644
--- a/hdf/src/vgint.h
+++ b/hdf/src/vgint.h
@@ -11,7 +11,7 @@
  * access to either file, you may request a copy from help at hdfgroup.org.     *
  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
 
-/* $Id: vgint.h 5584 2011-04-13 18:25:06Z bmribler $ */
+/* $Id: vgint.h 6111 2014-06-02 20:52:09Z bmribler $ */
 
 /*****************************************************************************
 *
@@ -253,6 +253,9 @@ extern      "C"
 
     void VSIrelease_vdata_node(VDATA *v);
 
+    intn VSIgetvdatas(int32 id, const char *vsclass, const uintn start_vd,
+	const uintn n_vds, uint16 *refarray);
+
     HDFLIBAPI vsinstance_t *VSIget_vsinstance_node(void);
 
     HDFLIBAPI void VSIrelease_vsinstance_node(vsinstance_t *vs);
diff --git a/hdf/test/CMakeLists.txt b/hdf/test/CMakeLists.txt
index 0358ac2..81d2bbf 100644
--- a/hdf/test/CMakeLists.txt
+++ b/hdf/test/CMakeLists.txt
@@ -15,7 +15,7 @@ LINK_DIRECTORIES (
     ${CMAKE_LIBRARY_OUTPUT_DIRECTORY}
 )
 
-SET (testhdf_SRCS
+set (testhdf_SRCS
     ${HDF4_HDF_TEST_SOURCE_DIR}/testhdf.c 
     ${HDF4_HDF_TEST_SOURCE_DIR}/an.c 
     ${HDF4_HDF_TEST_SOURCE_DIR}/anfile.c
@@ -55,23 +55,23 @@ SET (testhdf_SRCS
     ${HDF4_HDF_TEST_SOURCE_DIR}/vers.c
   )
 
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS)
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  add_definitions (-DDOS_FS)
+endif (WIN32)
 
 #-- Adding test for testhdf
 ADD_EXECUTABLE (testhdf ${testhdf_SRCS})
 TARGET_NAMING (testhdf ${LIB_TYPE})
 TARGET_C_PROPERTIES (testhdf " " " ")
-TARGET_LINK_LIBRARIES (testhdf ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+target_link_libraries (testhdf ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
 #-- Adding test for buffer
-IF (NOT WIN32)
+if (NOT WIN32)
   ADD_EXECUTABLE (buffer ${HDF4_HDF_TEST_SOURCE_DIR}/buffer.c)
   TARGET_NAMING (buffer ${LIB_TYPE})
   TARGET_C_PROPERTIES (buffer " " " ")
-  TARGET_LINK_LIBRARIES (buffer ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDIF (NOT WIN32)
+  target_link_libraries (buffer ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endif (NOT WIN32)
 
 ##############################################################################
 ##############################################################################
@@ -79,5 +79,5 @@ ENDIF (NOT WIN32)
 ##############################################################################
 ##############################################################################
 
-INCLUDE (CMakeTests.cmake)
+include (CMakeTests.cmake)
 
diff --git a/hdf/test/CMakeTests.cmake b/hdf/test/CMakeTests.cmake
index 831b88f..aae0932 100644
--- a/hdf/test/CMakeTests.cmake
+++ b/hdf/test/CMakeTests.cmake
@@ -8,7 +8,7 @@
 FILE (MAKE_DIRECTORY ${PROJECT_BINARY_DIR}/testdir)
 
 #-- Copy all the dat files from the test directory into the source directory
-SET (HDF4_REFERENCE_TEST_FILES
+set (HDF4_REFERENCE_TEST_FILES
     8bit.dat
     bitio.dat
     gr_r24.dat
@@ -21,8 +21,8 @@ SET (HDF4_REFERENCE_TEST_FILES
     grtdfui83.hdf
 )
 
-FOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
-   SET (dest "${PROJECT_BINARY_DIR}/test_files/${h4_file}")
+foreach (h4_file ${HDF4_REFERENCE_TEST_FILES})
+   set (dest "${PROJECT_BINARY_DIR}/test_files/${h4_file}")
    #MESSAGE(STATUS " Copying ${h4_file}")
    ADD_CUSTOM_COMMAND (
        TARGET     testhdf 
@@ -30,10 +30,10 @@ FOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
        COMMAND    ${CMAKE_COMMAND}
        ARGS       -E copy_if_different ${HDF4_HDF_TEST_SOURCE_DIR}/test_files/${h4_file} ${dest}
    )
-ENDFOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
+endforeach (h4_file ${HDF4_REFERENCE_TEST_FILES})
 
 # Remove any output file left over from previous test run
-ADD_TEST (
+add_test (
     NAME testhdf-clearall-objects
     COMMAND    ${CMAKE_COMMAND}
         -E remove 
@@ -108,14 +108,14 @@ ADD_TEST (
         tx.hdf
         Tables_External_File
 )
-IF (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (testhdf-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-ELSE (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (testhdf-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
-ENDIF (NOT "${last_test}" STREQUAL "")
-SET (last_test "testhdf-clearall-objects")
+if (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (testhdf-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+else (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (testhdf-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
+endif (NOT "${last_test}" STREQUAL "")
+set (last_test "testhdf-clearall-objects")
 
-ADD_TEST (
+add_test (
     NAME testhdf_thf0-clearall-objects
     COMMAND    ${CMAKE_COMMAND}
         -E remove 
@@ -130,14 +130,14 @@ ADD_TEST (
         thf8.hdf
         thf9.hdf
 )
-IF (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (testhdf_thf0-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-ELSE (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (testhdf_thf0-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
-ENDIF (NOT "${last_test}" STREQUAL "")
-SET (last_test "testhdf_thf0-clearall-objects")
+if (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (testhdf_thf0-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+else (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (testhdf_thf0-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
+endif (NOT "${last_test}" STREQUAL "")
+set (last_test "testhdf_thf0-clearall-objects")
 
-SET (thf_decade
+set (thf_decade
     1 2 3 4 5 6 7 8 9 10
     11 12 13 14 15 16 17 18 19 20
     21 22 23 24 25 26 27 28 29 30
@@ -145,8 +145,8 @@ SET (thf_decade
     41 42 43 44 45 46 47 48 49 50
     51 52 53 54 55 56 57 58 59 60
 )
-FOREACH (decade ${thf_decade}) 
-  ADD_TEST (
+foreach (decade ${thf_decade}) 
+  add_test (
       NAME testhdf_thf${decade}-clearall-objects
       COMMAND    ${CMAKE_COMMAND}
           -E remove 
@@ -161,33 +161,33 @@ FOREACH (decade ${thf_decade})
           thf${decade}8.hdf
           thf${decade}9.hdf
   )
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (testhdf_thf${decade}-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (testhdf_thf${decade}-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "testhdf_thf${decade}-clearall-objects")
-ENDFOREACH (decade ${thf_decade}) 
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (testhdf_thf${decade}-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (testhdf_thf${decade}-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "testhdf_thf${decade}-clearall-objects")
+endforeach (decade ${thf_decade}) 
 
-ADD_TEST (NAME testhdf COMMAND $<TARGET_FILE:testhdf>)
-SET (passRegex "All tests were successful")
+add_test (NAME testhdf COMMAND $<TARGET_FILE:testhdf>)
+set (passRegex "All tests were successful")
 SET_PROPERTY (TEST testhdf PROPERTY PASS_REGULAR_EXPRESSION "${passRegex}")
-IF (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (testhdf PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-ELSE (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (testhdf PROPERTIES LABELS ${PROJECT_NAME})
-ENDIF (NOT "${last_test}" STREQUAL "")
-SET (last_test "testhdf")
+if (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (testhdf PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+else (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (testhdf PROPERTIES LABELS ${PROJECT_NAME})
+endif (NOT "${last_test}" STREQUAL "")
+set (last_test "testhdf")
 
 #-- Adding test for buffer
-IF (NOT WIN32)
-  ADD_TEST (NAME buffer COMMAND $<TARGET_FILE:buffer>)
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (buffer PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (buffer PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "buffer")
-ENDIF (NOT WIN32)
+if (NOT WIN32)
+  add_test (NAME buffer COMMAND $<TARGET_FILE:buffer>)
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (buffer PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (buffer PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "buffer")
+endif (NOT WIN32)
 
 
diff --git a/hdf/test/Makefile.in b/hdf/test/Makefile.in
index c499e24..addade0 100644
--- a/hdf/test/Makefile.in
+++ b/hdf/test/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -17,23 +17,51 @@
 #############################################################################
 #############################################################################
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -52,10 +80,10 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
-	$(top_srcdir)/bin/depcomp $(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
+	$(top_srcdir)/bin/depcomp $(top_srcdir)/bin/test-driver README
 @HDF_BUILD_FORTRAN_FALSE at check_PROGRAMS = testhdf$(EXEEXT) \
 @HDF_BUILD_FORTRAN_FALSE@	buffer$(EXEEXT)
 @HDF_BUILD_FORTRAN_TRUE at check_PROGRAMS = testhdf$(EXEEXT) \
@@ -73,6 +101,10 @@ CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
 buffer_SOURCES = buffer.c
 buffer_OBJECTS = buffer.$(OBJEXT)
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
 am__fortest_SOURCES_DIST = fortest.c
 @HDF_BUILD_FORTRAN_TRUE at am_fortest_OBJECTS = fortest.$(OBJEXT)
 fortest_OBJECTS = $(am_fortest_OBJECTS)
@@ -104,26 +136,55 @@ am_testhdf_OBJECTS = an.$(OBJEXT) anfile.$(OBJEXT) bitio.$(OBJEXT) \
 	tvnameclass.$(OBJEXT) tvset.$(OBJEXT) tvsfpack.$(OBJEXT) \
 	vers.$(OBJEXT)
 testhdf_OBJECTS = $(am_testhdf_OBJECTS)
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 F77COMPILE = $(F77) $(AM_FFLAGS) $(FFLAGS)
-LTF77COMPILE = $(LIBTOOL) --tag=F77 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(F77) $(AM_FFLAGS) $(FFLAGS)
+LTF77COMPILE = $(LIBTOOL) $(AM_V_lt) --tag=F77 $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(F77) $(AM_FFLAGS) $(FFLAGS)
+AM_V_F77 = $(am__v_F77_ at AM_V@)
+am__v_F77_ = $(am__v_F77_ at AM_DEFAULT_V@)
+am__v_F77_0 = @echo "  F77     " $@;
+am__v_F77_1 = 
 F77LD = $(F77)
-F77LINK = $(LIBTOOL) --tag=F77 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(F77LD) $(AM_FFLAGS) $(FFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+F77LINK = $(LIBTOOL) $(AM_V_lt) --tag=F77 $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(F77LD) $(AM_FFLAGS) $(FFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_F77LD = $(am__v_F77LD_ at AM_V@)
+am__v_F77LD_ = $(am__v_F77LD_ at AM_DEFAULT_V@)
+am__v_F77LD_0 = @echo "  F77LD   " $@;
+am__v_F77LD_1 = 
 SOURCES = buffer.c $(fortest_SOURCES) $(fortestF_SOURCES) \
 	$(testhdf_SOURCES)
 DIST_SOURCES = buffer.c $(am__fortest_SOURCES_DIST) \
@@ -133,19 +194,235 @@ am__can_run_installinfo = \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+  test -z "$$files" \
+    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+         $(am__cd) "$$dir" && rm -f $$files; }; \
+  }
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
 @HDF_BUILD_FORTRAN_FALSE at am__EXEEXT_1 = testhdf$(EXEEXT) \
 @HDF_BUILD_FORTRAN_FALSE@	buffer$(EXEEXT)
 @HDF_BUILD_FORTRAN_TRUE at am__EXEEXT_1 = testhdf$(EXEEXT) \
 @HDF_BUILD_FORTRAN_TRUE@	buffer$(EXEEXT) fortest$(EXEEXT)
+TEST_SUITE_LOG = test-suite.log
+LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -230,6 +507,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -363,7 +641,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
-.SUFFIXES: .c .f .lo .o .obj
+.SUFFIXES: .c .f .lo .log .o .obj .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -404,18 +682,22 @@ clean-checkPROGRAMS:
 	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
 	echo " rm -f" $$list; \
 	rm -f $$list
+
 buffer$(EXEEXT): $(buffer_OBJECTS) $(buffer_DEPENDENCIES) $(EXTRA_buffer_DEPENDENCIES) 
 	@rm -f buffer$(EXEEXT)
-	$(LINK) $(buffer_OBJECTS) $(buffer_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(buffer_OBJECTS) $(buffer_LDADD) $(LIBS)
+
 fortest$(EXEEXT): $(fortest_OBJECTS) $(fortest_DEPENDENCIES) $(EXTRA_fortest_DEPENDENCIES) 
 	@rm -f fortest$(EXEEXT)
-	$(LINK) $(fortest_OBJECTS) $(fortest_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(fortest_OBJECTS) $(fortest_LDADD) $(LIBS)
+
 fortestF$(EXEEXT): $(fortestF_OBJECTS) $(fortestF_DEPENDENCIES) $(EXTRA_fortestF_DEPENDENCIES) 
 	@rm -f fortestF$(EXEEXT)
-	$(F77LINK) $(fortestF_OBJECTS) $(fortestF_LDADD) $(LIBS)
+	$(AM_V_F77LD)$(F77LINK) $(fortestF_OBJECTS) $(fortestF_LDADD) $(LIBS)
+
 testhdf$(EXEEXT): $(testhdf_OBJECTS) $(testhdf_DEPENDENCIES) $(EXTRA_testhdf_DEPENDENCIES) 
 	@rm -f testhdf$(EXEEXT)
-	$(LINK) $(testhdf_OBJECTS) $(testhdf_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(testhdf_OBJECTS) $(testhdf_LDADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -465,34 +747,34 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/vers.Po at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 .f.o:
-	$(F77COMPILE) -c -o $@ $<
+	$(AM_V_F77)$(F77COMPILE) -c -o $@ $<
 
 .f.obj:
-	$(F77COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
+	$(AM_V_F77)$(F77COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f.lo:
-	$(LTF77COMPILE) -c -o $@ $<
+	$(AM_V_F77)$(LTF77COMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -500,26 +782,15 @@ mostlyclean-libtool:
 clean-libtool:
 	-rm -rf .libs _libs
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -531,15 +802,11 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -548,9 +815,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -566,6 +834,172 @@ cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all $(check_PROGRAMS)
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+testhdf.log: testhdf$(EXEEXT)
+	@p='testhdf$(EXEEXT)'; \
+	b='testhdf'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+buffer.log: buffer$(EXEEXT)
+	@p='buffer$(EXEEXT)'; \
+	b='buffer'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+fortest.log: fortest$(EXEEXT)
+	@p='fortest$(EXEEXT)'; \
+	b='fortest'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -622,6 +1056,9 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 
@@ -706,19 +1143,20 @@ uninstall-am:
 
 .MAKE: check-am install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am all-local check check-TESTS check-am \
-	clean clean-checkPROGRAMS clean-generic clean-libtool \
-	cscopelist ctags distclean distclean-compile distclean-generic \
-	distclean-libtool distclean-local distclean-tags distdir dvi \
-	dvi-am html html-am info info-am install install-am \
-	install-data install-data-am install-dvi install-dvi-am \
-	install-exec install-exec-am install-html install-html-am \
-	install-info install-info-am install-man install-pdf \
-	install-pdf-am install-ps install-ps-am install-strip \
-	installcheck installcheck-am installdirs maintainer-clean \
-	maintainer-clean-generic mostlyclean mostlyclean-compile \
-	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
-	pdf-am ps ps-am tags uninstall uninstall-am
+.PHONY: CTAGS GTAGS TAGS all all-am all-local check check-TESTS \
+	check-am clean clean-checkPROGRAMS clean-generic clean-libtool \
+	cscopelist-am ctags ctags-am distclean distclean-compile \
+	distclean-generic distclean-libtool distclean-local \
+	distclean-tags distdir dvi dvi-am html html-am info info-am \
+	install install-am install-data install-data-am install-dvi \
+	install-dvi-am install-exec install-exec-am install-html \
+	install-html-am install-info install-info-am install-man \
+	install-pdf install-pdf-am install-ps install-ps-am \
+	install-strip installcheck installcheck-am installdirs \
+	maintainer-clean maintainer-clean-generic mostlyclean \
+	mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
+	mostlyclean-local pdf pdf-am ps ps-am recheck tags tags-am \
+	uninstall uninstall-am
 
 
 testdir:
diff --git a/hdf/test/tvsetf.f b/hdf/test/tvsetf.f
index 0a47975..64b377c 100644
--- a/hdf/test/tvsetf.f
+++ b/hdf/test/tvsetf.f
@@ -12,7 +12,7 @@ C* access to either file, you may request a copy from help at hdfgroup.org.     *
 C* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
 C*
 C*********************************************************************
-C $Id: tvsetf.f 5753 2012-01-18 17:44:10Z epourmal $
+C $Id: tvsetf.f 6083 2014-02-11 20:31:37Z epourmal $
 C*********************************************************************
 C      test vset Fortran data types
 C
@@ -947,9 +947,9 @@ C       Detach it
       call VRFY(status,'vfinsrt vdata2_id -> vgroup0_id',number_failed)
 
       status = vfdtch(vgroup0_id)
-      call VRFY(status,'vfdtch vgroup0_id')
+      call VRFY(status,'vfdtch vgroup0_id', number_failed)
       status = vfdtch(vgroup1_id)
-      call VRFY(status,'vfdtch vgroup1_id')
+      call VRFY(status,'vfdtch vgroup1_id', number_failed)
 
 C     Test getting all vdatas: fid, start_vd=0, n_vds=0
 
@@ -1018,16 +1018,16 @@ C     of user-created vgroups, should fail
 C     Terminate access
       
       status = vfdtch(vgroup0_id)
-      call VRFY(status,'vfdtch vgroup0_id')
+      call VRFY(status,'vfdtch vgroup0_id',number_failed)
       status = vsfdtch(vdata1_id)
-      call VRFY(status,'vsfdtch vdata1_id')
+      call VRFY(status,'vsfdtch vdata1_id',number_failed)
       status = vsfdtch(vdata2_id)
-      call VRFY(status,'vsfdtch vdata2_id')
+      call VRFY(status,'vsfdtch vdata2_id',number_failed)
 
 C     Terminate access to the V interface and close the HDF file.
       status = vfend(fid)
       call VRFY(status,'vfend',number_failed)
       status = hclose(fid)
-      call VRFY(status,'vclose',number_failed)
+      call VRFY(status,'hclose',number_failed)
 
       end
diff --git a/hdf/util/CMakeLists.txt b/hdf/util/CMakeLists.txt
index b157e85..fa1e5fc 100644
--- a/hdf/util/CMakeLists.txt
+++ b/hdf/util/CMakeLists.txt
@@ -3,19 +3,19 @@ PROJECT (HDF4_HDF_UTIL C CXX)
 
 INCLUDE_DIRECTORIES (${HDF4_HDFSOURCE_DIR})
 
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS)
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  add_definitions (-DDOS_FS)
+endif (WIN32)
 
-IF (HDF4_BUILD_TOOLS)
+if (HDF4_BUILD_TOOLS)
   #-- Adding tool hdfls
   ADD_EXECUTABLE (hdfls ${HDF4_HDF_UTIL_SOURCE_DIR}/hdfls.c)
   TARGET_NAMING (hdfls ${LIB_TYPE})
   TARGET_C_PROPERTIES (hdfls " " " ")
-  TARGET_LINK_LIBRARIES (hdfls ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (hdfls ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility hdfed
-  SET (hdfed_SRCS
+  set (hdfed_SRCS
       ${HDF4_HDF_UTIL_SOURCE_DIR}/he_cntrl.c
       ${HDF4_HDF_UTIL_SOURCE_DIR}/he_disp.c
       ${HDF4_HDF_UTIL_SOURCE_DIR}/he_file.c
@@ -25,12 +25,12 @@ IF (HDF4_BUILD_TOOLS)
   ADD_EXECUTABLE (hdfed ${hdfed_SRCS})
   TARGET_NAMING (hdfed ${LIB_TYPE})
   TARGET_C_PROPERTIES (hdfed " " " ")
-  TARGET_LINK_LIBRARIES (hdfed ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDIF (HDF4_BUILD_TOOLS)
+  target_link_libraries (hdfed ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endif (HDF4_BUILD_TOOLS)
 
-IF (HDF4_BUILD_UTILS)
+if (HDF4_BUILD_UTILS)
   #-- Adding utility hdf2gif
-  SET (hdf2gif_SRCS
+  set (hdf2gif_SRCS
       ${HDF4_HDF_UTIL_SOURCE_DIR}/hdf2gif.c
       ${HDF4_HDF_UTIL_SOURCE_DIR}/hdfgifwr.c
   )
@@ -38,10 +38,10 @@ IF (HDF4_BUILD_UTILS)
   ADD_EXECUTABLE (hdf2gif ${hdf2gif_SRCS})
   TARGET_NAMING (hdf2gif ${LIB_TYPE})
   TARGET_C_PROPERTIES (hdf2gif " " " ")
-  TARGET_LINK_LIBRARIES (hdf2gif ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (hdf2gif ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility gif2hdf
-  SET (gif2hdf_SRCS
+  set (gif2hdf_SRCS
       ${HDF4_HDF_UTIL_SOURCE_DIR}/gif2hdf.c
       ${HDF4_HDF_UTIL_SOURCE_DIR}/gif2mem.c
       ${HDF4_HDF_UTIL_SOURCE_DIR}/gifread.c
@@ -52,96 +52,96 @@ IF (HDF4_BUILD_UTILS)
   ADD_EXECUTABLE (gif2hdf ${gif2hdf_SRCS})
   TARGET_NAMING (gif2hdf ${LIB_TYPE})
   TARGET_C_PROPERTIES (gif2hdf " " " ")
-  TARGET_LINK_LIBRARIES (gif2hdf ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (gif2hdf ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility hdf24to8
   ADD_EXECUTABLE (hdf24to8 ${HDF4_HDF_UTIL_SOURCE_DIR}/hdf24to8.c)
   TARGET_NAMING (hdf24to8 ${LIB_TYPE})
   TARGET_C_PROPERTIES (hdf24to8 " " " ")
-  TARGET_LINK_LIBRARIES (hdf24to8 ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (hdf24to8 ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility hdftor8
   ADD_EXECUTABLE (hdftor8 ${HDF4_HDF_UTIL_SOURCE_DIR}/hdftor8.c)
   TARGET_NAMING (hdftor8 ${LIB_TYPE})
   TARGET_C_PROPERTIES (hdftor8 " " " ")
-  TARGET_LINK_LIBRARIES (hdftor8 ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (hdftor8 ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility ristosds
   ADD_EXECUTABLE (ristosds ${HDF4_HDF_UTIL_SOURCE_DIR}/ristosds.c)
   TARGET_NAMING (ristosds ${LIB_TYPE})
   TARGET_C_PROPERTIES (ristosds " " " ")
-  TARGET_LINK_LIBRARIES (ristosds ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (ristosds ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility hdfpack
   ADD_EXECUTABLE (hdfpack ${HDF4_HDF_UTIL_SOURCE_DIR}/hdfpack.c)
   TARGET_NAMING (hdfpack ${LIB_TYPE})
   TARGET_C_PROPERTIES (hdfpack " " " ")
-  TARGET_LINK_LIBRARIES (hdfpack ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (hdfpack ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility paltohdf
   ADD_EXECUTABLE (paltohdf ${HDF4_HDF_UTIL_SOURCE_DIR}/paltohdf.c)
   TARGET_NAMING (paltohdf ${LIB_TYPE})
   TARGET_C_PROPERTIES (paltohdf " " " ")
-  TARGET_LINK_LIBRARIES (paltohdf ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (paltohdf ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility hdftopal
   ADD_EXECUTABLE (hdftopal ${HDF4_HDF_UTIL_SOURCE_DIR}/hdftopal.c)
   TARGET_NAMING (hdftopal ${LIB_TYPE})
   TARGET_C_PROPERTIES (hdftopal " " " ")
-  TARGET_LINK_LIBRARIES (hdftopal ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (hdftopal ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility r8tohdf
   ADD_EXECUTABLE (r8tohdf ${HDF4_HDF_UTIL_SOURCE_DIR}/r8tohdf.c)
   TARGET_NAMING (r8tohdf ${LIB_TYPE})
   TARGET_C_PROPERTIES (r8tohdf " " " ")
-  TARGET_LINK_LIBRARIES (r8tohdf ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (r8tohdf ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility hdfcomp
   ADD_EXECUTABLE (hdfcomp ${HDF4_HDF_UTIL_SOURCE_DIR}/hdfcomp.c)
   TARGET_NAMING (hdfcomp ${LIB_TYPE})
   TARGET_C_PROPERTIES (hdfcomp " " " ")
-  TARGET_LINK_LIBRARIES (hdfcomp ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (hdfcomp ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility jpeg2hdf
   ADD_EXECUTABLE (jpeg2hdf ${HDF4_HDF_UTIL_SOURCE_DIR}/jpeg2hdf.c)
   TARGET_NAMING (jpeg2hdf ${LIB_TYPE})
   TARGET_C_PROPERTIES (jpeg2hdf " " " ")
-  TARGET_LINK_LIBRARIES (jpeg2hdf ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (jpeg2hdf ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility hdf2jpeg
   ADD_EXECUTABLE (hdf2jpeg ${HDF4_HDF_UTIL_SOURCE_DIR}/hdf2jpeg.c)
   TARGET_NAMING (hdf2jpeg ${LIB_TYPE})
   TARGET_C_PROPERTIES (hdf2jpeg " " " ")
-  TARGET_LINK_LIBRARIES (hdf2jpeg ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (hdf2jpeg ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility hdf8to24
   ADD_EXECUTABLE (hdf8to24 ${HDF4_HDF_UTIL_SOURCE_DIR}/hdf8to24.c)
   TARGET_NAMING (hdf8to24 ${LIB_TYPE})
   TARGET_C_PROPERTIES (hdf8to24 " " " ")
-  TARGET_LINK_LIBRARIES (hdf8to24 ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (hdf8to24 ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility hdfunpac
   ADD_EXECUTABLE (hdfunpac ${HDF4_HDF_UTIL_SOURCE_DIR}/hdfunpac.c)
   TARGET_NAMING (hdfunpac ${LIB_TYPE})
   TARGET_C_PROPERTIES (hdfunpac " " " ")
-  TARGET_LINK_LIBRARIES (hdfunpac ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (hdfunpac ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility vmake
   ADD_EXECUTABLE (vmake ${HDF4_HDF_UTIL_SOURCE_DIR}/vmake.c)
   TARGET_NAMING (vmake ${LIB_TYPE})
   TARGET_C_PROPERTIES (vmake " " " ")
-  TARGET_LINK_LIBRARIES (vmake ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  target_link_libraries (vmake ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 
   #-- Adding utility vshow
   ADD_EXECUTABLE (vshow ${HDF4_HDF_UTIL_SOURCE_DIR}/vshow.c)
   TARGET_NAMING (vshow ${LIB_TYPE})
   TARGET_C_PROPERTIES (vshow " " " ")
-  TARGET_LINK_LIBRARIES (vshow ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDIF (HDF4_BUILD_UTILS)
+  target_link_libraries (vshow ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endif (HDF4_BUILD_UTILS)
 
-IF (BUILD_TESTING AND HDF4_BUILD_UTILS)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING AND HDF4_BUILD_UTILS)
+if (BUILD_TESTING AND HDF4_BUILD_UTILS)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING AND HDF4_BUILD_UTILS)
 
 ##############################################################################
 ##############################################################################
@@ -152,7 +152,7 @@ ENDIF (BUILD_TESTING AND HDF4_BUILD_UTILS)
 #-----------------------------------------------------------------------------
 # Add file(s) to CMake Install
 #-----------------------------------------------------------------------------
-IF (HDF4_BUILD_TOOLS)
+if (HDF4_BUILD_TOOLS)
   INSTALL_PROGRAM_PDB (hdfls ${HDF4_INSTALL_TOOLS_BIN_DIR} toolsapplications)
   INSTALL_PROGRAM_PDB (hdfed ${HDF4_INSTALL_TOOLS_BIN_DIR} toolsapplications)
 
@@ -165,9 +165,9 @@ IF (HDF4_BUILD_TOOLS)
       COMPONENT
           toolsapplications
   )
-ENDIF (HDF4_BUILD_TOOLS)
+endif (HDF4_BUILD_TOOLS)
 
-IF (HDF4_BUILD_UTILS)
+if (HDF4_BUILD_UTILS)
   INSTALL_PROGRAM_PDB (gif2hdf ${HDF4_INSTALL_UTILS_BIN_DIR} utilsapplications)
   INSTALL_PROGRAM_PDB (hdf2gif ${HDF4_INSTALL_UTILS_BIN_DIR} utilsapplications)
   INSTALL_PROGRAM_PDB (hdf2jpeg ${HDF4_INSTALL_UTILS_BIN_DIR} utilsapplications)
@@ -208,4 +208,4 @@ IF (HDF4_BUILD_UTILS)
       COMPONENT
           utilsapplications
   )
-ENDIF (HDF4_BUILD_UTILS)
+endif (HDF4_BUILD_UTILS)
diff --git a/hdf/util/CMakeTests.cmake b/hdf/util/CMakeTests.cmake
index fa30f4d..5a4fc70 100644
--- a/hdf/util/CMakeTests.cmake
+++ b/hdf/util/CMakeTests.cmake
@@ -11,9 +11,9 @@
 # --------------------------------------------------------------------
 ##############################################################################
 
-IF (HDF4_BUILD_TOOLS)
+if (HDF4_BUILD_TOOLS)
   #-- Copy all the hdfls data files from the source directory into the test directory
-  SET (HDF4_LS_TEST_FILES
+  set (HDF4_LS_TEST_FILES
       hdfcomp.out1.1
       hdfcomp.out1.2
       hdfed.input1
@@ -26,193 +26,193 @@ IF (HDF4_BUILD_TOOLS)
       ristosds.out1
   )
   
-  FOREACH (h4_file ${HDF4_LS_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_LS_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
         TARGET     hdfls
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_LS_TEST_FILES})
+  endforeach (h4_file ${HDF4_LS_TEST_FILES})
   
-  IF (WIN32 AND NOT CYGWIN)
+  if (WIN32)
     ADD_CUSTOM_COMMAND (
         TARGET     hdfls
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/hdfed-w.out1 ${PROJECT_BINARY_DIR}/hdfed.out1
     )
-  ELSE (WIN32 AND NOT CYGWIN)
+  else (WIN32)
     ADD_CUSTOM_COMMAND (
         TARGET     hdfls
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/hdfed.out1 ${PROJECT_BINARY_DIR}/hdfed.out1
     )
-  ENDIF (WIN32 AND NOT CYGWIN)
+  endif (WIN32)
 
   #-- Copy all the hdfed data files from the source directory into the test directory
-  SET (HDF4_HDFED_TEST_FILES
+  set (HDF4_HDFED_TEST_FILES
       storm110.hdf
       ntcheck.hdf
   )
-  FOREACH (h4_file ${HDF4_HDFED_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_HDFED_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
         TARGET     hdfed
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_HDFED_TEST_FILES})
-ENDIF (HDF4_BUILD_TOOLS)
+  endforeach (h4_file ${HDF4_HDFED_TEST_FILES})
+endif (HDF4_BUILD_TOOLS)
 
   #-- Copy all the hdf2gif data files from the source directory into the test directory
-  SET (HDF4_HDF2GIF_TEST_FILES
+  set (HDF4_HDF2GIF_TEST_FILES
       skull.hdf
   )
-  FOREACH (h4_file ${HDF4_HDF2GIF_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_HDF2GIF_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
         TARGET     hdf2gif
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_HDF2GIF_TEST_FILES})
+  endforeach (h4_file ${HDF4_HDF2GIF_TEST_FILES})
 
   #-- Copy all the gif2hdf data files from the source directory into the test directory
-  SET (HDF4_GIF2HDF_TEST_FILES
+  set (HDF4_GIF2HDF_TEST_FILES
       SunWheel.gif
       bttrfly.gif
   )
-  FOREACH (h4_file ${HDF4_GIF2HDF_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_GIF2HDF_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
         TARGET     gif2hdf
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_GIF2HDF_TEST_FILES})
+  endforeach (h4_file ${HDF4_GIF2HDF_TEST_FILES})
 
   #-- Copy all the hdftor8 data files from the source directory into the test directory
-  SET (HDF4_HDFTOR8_TEST_FILES
+  set (HDF4_HDFTOR8_TEST_FILES
       head.r24
       head.r8
   )
-  FOREACH (h4_file ${HDF4_HDFTOR8_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_HDFTOR8_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
         TARGET     hdftor8
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_HDFTOR8_TEST_FILES})
+  endforeach (h4_file ${HDF4_HDFTOR8_TEST_FILES})
 
   #-- Copy all the ristosds data files from the source directory into the test directory
-  SET (HDF4_RISTOSDS_TEST_FILES
+  set (HDF4_RISTOSDS_TEST_FILES
       storm110.hdf
       storm120.hdf
       storm130.hdf
   )
-  FOREACH (h4_file ${HDF4_RISTOSDS_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_RISTOSDS_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
         TARGET     ristosds
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_RISTOSDS_TEST_FILES})
+  endforeach (h4_file ${HDF4_RISTOSDS_TEST_FILES})
 
   #-- Copy all the hdfpack data files from the source directory into the test directory
-  SET (HDF4_HDFPACK_TEST_FILES
+  set (HDF4_HDFPACK_TEST_FILES
       test.hdf
   )
-  FOREACH (h4_file ${HDF4_HDFPACK_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_HDFPACK_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
         TARGET     hdfpack
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_HDFPACK_TEST_FILES})
+  endforeach (h4_file ${HDF4_HDFPACK_TEST_FILES})
 
   #-- Copy all the paltohdf data files from the source directory into the test directory
-  SET (HDF4_PALTOHDF_TEST_FILES
+  set (HDF4_PALTOHDF_TEST_FILES
       palette.raw
   )
-  FOREACH (h4_file ${HDF4_PALTOHDF_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_PALTOHDF_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
         TARGET     paltohdf
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_PALTOHDF_TEST_FILES})
+  endforeach (h4_file ${HDF4_PALTOHDF_TEST_FILES})
 
   #-- Copy all the r8tohdf data files from the source directory into the test directory
-  SET (HDF4_R8TOHDF_TEST_FILES
+  set (HDF4_R8TOHDF_TEST_FILES
       storm110.raw
       storm120.raw
       storm130.raw
       storm140.raw
   )
-  FOREACH (h4_file ${HDF4_R8TOHDF_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_R8TOHDF_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
         TARGET     r8tohdf
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_R8TOHDF_TEST_FILES})
+  endforeach (h4_file ${HDF4_R8TOHDF_TEST_FILES})
 
   #-- Copy all the hdfcomp data files from the source directory into the test directory
-  SET (HDF4_HDFCOMP_TEST_FILES
+  set (HDF4_HDFCOMP_TEST_FILES
       storm110.hdf
       storm120.hdf
       storm130.hdf
   )
-  FOREACH (h4_file ${HDF4_HDFCOMP_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_HDFCOMP_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
         TARGET     hdfcomp
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_HDFCOMP_TEST_FILES})
+  endforeach (h4_file ${HDF4_HDFCOMP_TEST_FILES})
 
   #-- Copy all the jpeg2hdf data files from the source directory into the test directory
-  SET (HDF4_JPEG2HDF_TEST_FILES
+  set (HDF4_JPEG2HDF_TEST_FILES
       jpeg_img.jpg
   )
-  FOREACH (h4_file ${HDF4_JPEG2HDF_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_JPEG2HDF_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
         TARGET     jpeg2hdf
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_HDF_UTIL_SOURCE_DIR}/testfiles/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_JPEG2HDF_TEST_FILES})
+  endforeach (h4_file ${HDF4_JPEG2HDF_TEST_FILES})
   
 ##############################################################################
 ##############################################################################
@@ -220,12 +220,12 @@ ENDIF (HDF4_BUILD_TOOLS)
 ##############################################################################
 ##############################################################################
 
-IF (HDF4_BUILD_TOOLS)
+if (HDF4_BUILD_TOOLS)
   MACRO (ADD_LS_TEST_NOL testfile resultfile resultcode)
-    IF (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (NAME HDFLS_NOL-${testfile} COMMAND $<TARGET_FILE:hdfls> ${testfile})
-    ELSE (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (
+    if (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (NAME HDFLS_NOL-${testfile} COMMAND $<TARGET_FILE:hdfls> ${testfile})
+    else (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (
           NAME HDFLS_NOL-${testfile}
           COMMAND "${CMAKE_COMMAND}"
               -D "TEST_PROGRAM=$<TARGET_FILE:hdfls>"
@@ -235,22 +235,22 @@ IF (HDF4_BUILD_TOOLS)
               -D "TEST_EXPECT=${resultcode}"
               -D "TEST_FILTER:STRING=(File library|String)[^\n]+\n"
               -D "TEST_REFERENCE=${resultfile}"
-              -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+              -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
       )
-    ENDIF (HDF4_ENABLE_USING_MEMCHECKER)
-    IF (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HDFLS_NOL-${testfile} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-    ELSE (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HDFLS_NOL-${testfile} PROPERTIES LABELS ${PROJECT_NAME})
-    ENDIF (NOT "${last_test}" STREQUAL "")
-    SET (last_test "HDFLS_NOL-${testfile}")
+    endif (HDF4_ENABLE_USING_MEMCHECKER)
+    if (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HDFLS_NOL-${testfile} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+    else (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HDFLS_NOL-${testfile} PROPERTIES LABELS ${PROJECT_NAME})
+    endif (NOT "${last_test}" STREQUAL "")
+    set (last_test "HDFLS_NOL-${testfile}")
   ENDMACRO (ADD_LS_TEST_NOL)
 
   MACRO (ADD_LS_TEST testfile resultfile resultcode)
-    IF (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (NAME HDFLS-${testfile} COMMAND $<TARGET_FILE:hdfls> -l ${testfile})
-    ELSE (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (
+    if (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (NAME HDFLS-${testfile} COMMAND $<TARGET_FILE:hdfls> -l ${testfile})
+    else (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (
           NAME HDFLS-${testfile}
           COMMAND "${CMAKE_COMMAND}"
               -D "TEST_PROGRAM=$<TARGET_FILE:hdfls>"
@@ -260,22 +260,22 @@ IF (HDF4_BUILD_TOOLS)
               -D "TEST_EXPECT=${resultcode}"
               -D "TEST_FILTER:STRING=(File library|String)[^\n]+\n"
               -D "TEST_REFERENCE=${resultfile}"
-              -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+              -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
       )
-    ENDIF (HDF4_ENABLE_USING_MEMCHECKER)
-    IF (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HDFLS-${testfile} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-    ELSE (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HDFLS-${testfile} PROPERTIES LABELS ${PROJECT_NAME})
-    ENDIF (NOT "${last_test}" STREQUAL "")
-    SET (last_test "HDFLS-${testfile}")
+    endif (HDF4_ENABLE_USING_MEMCHECKER)
+    if (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HDFLS-${testfile} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+    else (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HDFLS-${testfile} PROPERTIES LABELS ${PROJECT_NAME})
+    endif (NOT "${last_test}" STREQUAL "")
+    set (last_test "HDFLS-${testfile}")
   ENDMACRO (ADD_LS_TEST)
 
   MACRO (ADD_H4_TEST_ED testfile resultfile resultcode)
-    IF (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (NAME HEDIT-${testfile} COMMAND $<TARGET_FILE:hdfed> -batch)
-    ELSE (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (
+    if (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (NAME HEDIT-${testfile} COMMAND $<TARGET_FILE:hdfed> -batch)
+    else (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (
           NAME HEDIT-${testfile}
           COMMAND "${CMAKE_COMMAND}"
               -D "TEST_PROGRAM=$<TARGET_FILE:hdfed>"
@@ -285,46 +285,46 @@ IF (HDF4_BUILD_TOOLS)
               -D "TEST_OUTPUT=${testfile}.tmp"
               -D "TEST_EXPECT=${resultcode}"
               -D "TEST_REFERENCE=${resultfile}"
-              -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+              -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
       )
-    ENDIF (HDF4_ENABLE_USING_MEMCHECKER)
-    IF (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HEDIT-${testfile} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-    ELSE (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HEDIT-${testfile} PROPERTIES LABELS ${PROJECT_NAME})
-    ENDIF (NOT "${last_test}" STREQUAL "")
-    SET (last_test "HEDIT-${testfile}")
+    endif (HDF4_ENABLE_USING_MEMCHECKER)
+    if (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HEDIT-${testfile} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+    else (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HEDIT-${testfile} PROPERTIES LABELS ${PROJECT_NAME})
+    endif (NOT "${last_test}" STREQUAL "")
+    set (last_test "HEDIT-${testfile}")
   ENDMACRO (ADD_H4_TEST_ED)
-ENDIF (HDF4_BUILD_TOOLS)
+endif (HDF4_BUILD_TOOLS)
 
   MACRO (ADD_H4_TEST testname testfile)
-    ADD_TEST (NAME ${testname} COMMAND $<TARGET_FILE:${testfile}> ${ARGN})
-    IF (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (${testname} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-    ELSE (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (${testname} PROPERTIES LABELS ${PROJECT_NAME})
-    ENDIF (NOT "${last_test}" STREQUAL "")
-    SET (last_test "${testname}")
+    add_test (NAME ${testname} COMMAND $<TARGET_FILE:${testfile}> ${ARGN})
+    if (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (${testname} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+    else (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (${testname} PROPERTIES LABELS ${PROJECT_NAME})
+    endif (NOT "${last_test}" STREQUAL "")
+    set (last_test "${testname}")
   ENDMACRO (ADD_H4_TEST)
 
   MACRO (ADD_CMP_TEST testname reffile testfile)
-    ADD_TEST (NAME ${testname} COMMAND ${CMAKE_COMMAND} -E compare_files ${reffile} ${testfile})
-    IF (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (${testname} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-    ELSE (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (${testname} PROPERTIES LABELS ${PROJECT_NAME})
-    ENDIF (NOT "${last_test}" STREQUAL "")
-    SET (last_test "${testname}")
+    add_test (NAME ${testname} COMMAND ${CMAKE_COMMAND} -E compare_files ${reffile} ${testfile})
+    if (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (${testname} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+    else (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (${testname} PROPERTIES LABELS ${PROJECT_NAME})
+    endif (NOT "${last_test}" STREQUAL "")
+    set (last_test "${testname}")
   ENDMACRO (ADD_CMP_TEST)
 
   MACRO (ADD_H4Q_TEST testname testfile)
-    ADD_TEST (NAME ${testname} COMMAND $<TARGET_FILE:${testfile}> ${ARGN} > /dev/null 2>&1)
-    IF (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (${testname} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-    ELSE (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (${testname} PROPERTIES LABELS ${PROJECT_NAME})
-    ENDIF (NOT "${last_test}" STREQUAL "")
-    SET (last_test "${testname}")
+    add_test (NAME ${testname} COMMAND $<TARGET_FILE:${testfile}> ${ARGN} > /dev/null 2>&1)
+    if (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (${testname} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+    else (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (${testname} PROPERTIES LABELS ${PROJECT_NAME})
+    endif (NOT "${last_test}" STREQUAL "")
+    set (last_test "${testname}")
   ENDMACRO (ADD_H4Q_TEST)
 
 ##############################################################################
@@ -334,7 +334,7 @@ ENDIF (HDF4_BUILD_TOOLS)
 ##############################################################################
 
   # Remove any output file left over from previous test run
-  ADD_TEST (
+  add_test (
       NAME hdfgif-clear-refs
       COMMAND    ${CMAKE_COMMAND}
           -E remove 
@@ -349,12 +349,12 @@ ENDIF (HDF4_BUILD_TOOLS)
           ristosds.input1.tmp
           ristosds.input1.tmp.err
   )
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (hdfgif-clear-refs PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (hdfgif-clear-refs PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "hdfgif-clear-refs")
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (hdfgif-clear-refs PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (hdfgif-clear-refs PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "hdfgif-clear-refs")
 
   ADD_H4_TEST (testhdf2gif hdf2gif skull.hdf skull.gif)
   ADD_H4_TEST (testgif2hdf-sunwheel gif2hdf SunWheel.gif SunWheel.hdf)
@@ -364,17 +364,17 @@ ENDIF (HDF4_BUILD_TOOLS)
   ADD_H4_TEST (testhdftor8 hdftor8 head8.hdf)
   ADD_CMP_TEST (hdfr8comp img001-263.328 head.r8)
 
-  IF (HDF4_BUILD_TOOLS)
+  if (HDF4_BUILD_TOOLS)
     ADD_H4_TEST_ED (hdfed.input1 hdfed.out1 0)
-  ENDIF (HDF4_BUILD_TOOLS)
+  endif (HDF4_BUILD_TOOLS)
 
   ADD_H4Q_TEST (testristosds ristosds storm110.hdf storm120.hdf storm130.hdf -o storm.hdf)
-  IF (HDF4_BUILD_TOOLS)
+  if (HDF4_BUILD_TOOLS)
     ADD_H4_TEST_ED (ristosds.input1 ristosds.out1 0)
-  ENDIF (HDF4_BUILD_TOOLS)
+  endif (HDF4_BUILD_TOOLS)
 
   # Remove any output file left over from previous test run
-  ADD_TEST (
+  add_test (
       NAME hdfpack-clear-refs
       COMMAND    ${CMAKE_COMMAND}
           -E remove 
@@ -385,22 +385,22 @@ ENDIF (HDF4_BUILD_TOOLS)
           test.pck.tmp
           test.pck.tmp.err
   )
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (hdfpack-clear-refs PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (hdfpack-clear-refs PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "hdfpack-clear-refs")
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (hdfpack-clear-refs PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (hdfpack-clear-refs PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "hdfpack-clear-refs")
 
   ADD_H4_TEST (testhdfpack hdfpack test.hdf test.pck)
   ADD_H4_TEST (testhdfpack-block hdfpack -b test.hdf test.blk)
-  IF (HDF4_BUILD_TOOLS)
+  if (HDF4_BUILD_TOOLS)
     ADD_LS_TEST_NOL (test.hdf hdfpack.out1.1 0)
     ADD_LS_TEST_NOL (test.pck hdfpack.out1.2 0)
-  ENDIF (HDF4_BUILD_TOOLS)
+  endif (HDF4_BUILD_TOOLS)
 
   # Remove any output file left over from previous test run
-  ADD_TEST (
+  add_test (
       NAME hdfpalette-clear-refs
       COMMAND    ${CMAKE_COMMAND}
           -E remove 
@@ -423,12 +423,12 @@ ENDIF (HDF4_BUILD_TOOLS)
           allcomp.hdf.tmp
           allcomp.hdf.tmp.err
   )
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (hdfpalette-clear-refs PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (hdfpalette-clear-refs PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "hdfpalette-clear-refs")
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (hdfpalette-clear-refs PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (hdfpalette-clear-refs PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "hdfpalette-clear-refs")
 
   ADD_H4_TEST (testpaltohdf paltohdf palette.raw palette.hdf)
   ADD_H4_TEST (testhdftopal hdftopal palette.hdf palette.raw.new)
@@ -437,9 +437,9 @@ ENDIF (HDF4_BUILD_TOOLS)
   ADD_H4_TEST (testr8tohdf-storm r8tohdf 57 57 storm.hdf storm110.raw storm120.raw storm130.raw storm140.raw)
   ADD_H4_TEST (testr8tohdf-palette r8tohdf 57 57 storm.hdf -p palette.raw -i storm110.raw)
   ADD_H4_TEST (testhdftor8-storm hdftor8 storm.hdf)
-  IF (HDF4_BUILD_TOOLS)
+  if (HDF4_BUILD_TOOLS)
     ADD_LS_TEST (storm.hdf hdftor8.out1 0)
-  ENDIF (HDF4_BUILD_TOOLS)
+  endif (HDF4_BUILD_TOOLS)
 
   ADD_CMP_TEST (storm110comp img001-057.057  storm110.raw)
   ADD_CMP_TEST (storm120comp img002-057.057  storm120.raw)
@@ -448,13 +448,13 @@ ENDIF (HDF4_BUILD_TOOLS)
 
   ADD_H4_TEST (testhdfcomp-storms hdfcomp allstorms.hdf storm110.hdf storm120.hdf storm130.hdf)
   ADD_H4_TEST (testhdfcomp hdfcomp allcomp.hdf -c storm110.hdf storm120.hdf storm130.hdf)
-  IF (HDF4_BUILD_TOOLS)
+  if (HDF4_BUILD_TOOLS)
     ADD_LS_TEST (allstorms.hdf hdfcomp.out1.1 0)
     ADD_LS_TEST (allcomp.hdf hdfcomp.out1.2 0)
-  ENDIF (HDF4_BUILD_TOOLS)
+  endif (HDF4_BUILD_TOOLS)
 
   # Remove any output file left over from previous test run
-  ADD_TEST (
+  add_test (
       NAME hdfjpeg-clear-refs
       COMMAND    ${CMAKE_COMMAND}
           -E remove 
@@ -463,18 +463,18 @@ ENDIF (HDF4_BUILD_TOOLS)
           jpeg.hdf.tmp.err
           jpeg2.jpg
   )
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (hdfjpeg-clear-refs PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (hdfjpeg-clear-refs PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "hdfjpeg-clear-refs")
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (hdfjpeg-clear-refs PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (hdfjpeg-clear-refs PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "hdfjpeg-clear-refs")
 
   ADD_H4_TEST (testjpeg2hdf jpeg2hdf jpeg_img.jpg jpeg.hdf)
   ADD_H4_TEST (testhdf2jpeg hdf2jpeg jpeg.hdf jpeg2.jpg)
-  IF (HDF4_BUILD_TOOLS)
+  if (HDF4_BUILD_TOOLS)
     ADD_LS_TEST (jpeg.hdf jpeg2hdf.out1 0)
-  ENDIF (HDF4_BUILD_TOOLS)
+  endif (HDF4_BUILD_TOOLS)
   ADD_CMP_TEST (jpeg2comp jpeg_img.jpg jpeg2.jpg)
 
 #  ADD_H4_TEST (hdf8to24 hdf8to24)
diff --git a/hdf/util/Makefile.in b/hdf/util/Makefile.in
index eac4969..39fac97 100644
--- a/hdf/util/Makefile.in
+++ b/hdf/util/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -19,23 +19,51 @@
 
 
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -54,12 +82,12 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
 	$(srcdir)/h4cc.in $(srcdir)/h4fc.in $(srcdir)/h4redeploy.in \
 	$(srcdir)/testutil.sh.in $(top_srcdir)/bin/depcomp \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am
+	$(top_srcdir)/bin/test-driver README
 bin_PROGRAMS = gif2hdf$(EXEEXT) hdf2gif$(EXEEXT) hdf2jpeg$(EXEEXT) \
 	hdf24to8$(EXEEXT) hdf8to24$(EXEEXT) hdfcomp$(EXEEXT) \
 	hdfed$(EXEEXT) hdfls$(EXEEXT) hdfpack$(EXEEXT) \
@@ -81,95 +109,99 @@ PROGRAMS = $(bin_PROGRAMS)
 am_gif2hdf_OBJECTS = gif2hdf.$(OBJEXT) gif2mem.$(OBJEXT) \
 	gifread.$(OBJEXT) decompress.$(OBJEXT) writehdf.$(OBJEXT)
 gif2hdf_OBJECTS = $(am_gif2hdf_OBJECTS)
-gif2hdf_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(gif2hdf_LDFLAGS) \
-	$(LDFLAGS) -o $@
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
+gif2hdf_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(gif2hdf_LDFLAGS) $(LDFLAGS) -o $@
 am_hdf24to8_OBJECTS = hdf24to8.$(OBJEXT)
 hdf24to8_OBJECTS = $(am_hdf24to8_OBJECTS)
-hdf24to8_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdf24to8_LDFLAGS) \
-	$(LDFLAGS) -o $@
+hdf24to8_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdf24to8_LDFLAGS) $(LDFLAGS) -o $@
 am_hdf2gif_OBJECTS = hdf2gif.$(OBJEXT) hdfgifwr.$(OBJEXT)
 hdf2gif_OBJECTS = $(am_hdf2gif_OBJECTS)
-hdf2gif_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdf2gif_LDFLAGS) \
-	$(LDFLAGS) -o $@
+hdf2gif_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdf2gif_LDFLAGS) $(LDFLAGS) -o $@
 am_hdf2jpeg_OBJECTS = hdf2jpeg.$(OBJEXT)
 hdf2jpeg_OBJECTS = $(am_hdf2jpeg_OBJECTS)
-hdf2jpeg_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdf2jpeg_LDFLAGS) \
-	$(LDFLAGS) -o $@
+hdf2jpeg_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdf2jpeg_LDFLAGS) $(LDFLAGS) -o $@
 am_hdf8to24_OBJECTS = hdf8to24.$(OBJEXT)
 hdf8to24_OBJECTS = $(am_hdf8to24_OBJECTS)
-hdf8to24_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdf8to24_LDFLAGS) \
-	$(LDFLAGS) -o $@
+hdf8to24_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdf8to24_LDFLAGS) $(LDFLAGS) -o $@
 am_hdfcomp_OBJECTS = hdfcomp.$(OBJEXT)
 hdfcomp_OBJECTS = $(am_hdfcomp_OBJECTS)
-hdfcomp_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdfcomp_LDFLAGS) \
-	$(LDFLAGS) -o $@
+hdfcomp_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdfcomp_LDFLAGS) $(LDFLAGS) -o $@
 am_hdfed_OBJECTS = he_cntrl.$(OBJEXT) he_disp.$(OBJEXT) \
 	he_file.$(OBJEXT) he_main.$(OBJEXT)
 hdfed_OBJECTS = $(am_hdfed_OBJECTS)
-hdfed_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdfed_LDFLAGS) \
-	$(LDFLAGS) -o $@
+hdfed_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdfed_LDFLAGS) $(LDFLAGS) -o $@
 am_hdfls_OBJECTS = hdfls.$(OBJEXT)
 hdfls_OBJECTS = $(am_hdfls_OBJECTS)
-hdfls_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdfls_LDFLAGS) \
-	$(LDFLAGS) -o $@
+hdfls_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdfls_LDFLAGS) $(LDFLAGS) -o $@
 am_hdfpack_OBJECTS = hdfpack.$(OBJEXT)
 hdfpack_OBJECTS = $(am_hdfpack_OBJECTS)
-hdfpack_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdfpack_LDFLAGS) \
-	$(LDFLAGS) -o $@
+hdfpack_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdfpack_LDFLAGS) $(LDFLAGS) -o $@
 am_hdftopal_OBJECTS = hdftopal.$(OBJEXT)
 hdftopal_OBJECTS = $(am_hdftopal_OBJECTS)
-hdftopal_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdftopal_LDFLAGS) \
-	$(LDFLAGS) -o $@
+hdftopal_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdftopal_LDFLAGS) $(LDFLAGS) -o $@
 am_hdftor8_OBJECTS = hdftor8.$(OBJEXT)
 hdftor8_OBJECTS = $(am_hdftor8_OBJECTS)
-hdftor8_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdftor8_LDFLAGS) \
-	$(LDFLAGS) -o $@
+hdftor8_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdftor8_LDFLAGS) $(LDFLAGS) -o $@
 am_hdfunpac_OBJECTS = hdfunpac.$(OBJEXT)
 hdfunpac_OBJECTS = $(am_hdfunpac_OBJECTS)
-hdfunpac_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdfunpac_LDFLAGS) \
-	$(LDFLAGS) -o $@
+hdfunpac_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdfunpac_LDFLAGS) $(LDFLAGS) -o $@
 am_jpeg2hdf_OBJECTS = jpeg2hdf.$(OBJEXT)
 jpeg2hdf_OBJECTS = $(am_jpeg2hdf_OBJECTS)
-jpeg2hdf_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(jpeg2hdf_LDFLAGS) \
-	$(LDFLAGS) -o $@
+jpeg2hdf_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(jpeg2hdf_LDFLAGS) $(LDFLAGS) -o $@
 am_paltohdf_OBJECTS = paltohdf.$(OBJEXT)
 paltohdf_OBJECTS = $(am_paltohdf_OBJECTS)
-paltohdf_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(paltohdf_LDFLAGS) \
-	$(LDFLAGS) -o $@
+paltohdf_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(paltohdf_LDFLAGS) $(LDFLAGS) -o $@
 am_r8tohdf_OBJECTS = r8tohdf.$(OBJEXT)
 r8tohdf_OBJECTS = $(am_r8tohdf_OBJECTS)
-r8tohdf_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(r8tohdf_LDFLAGS) \
-	$(LDFLAGS) -o $@
+r8tohdf_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(r8tohdf_LDFLAGS) $(LDFLAGS) -o $@
 am_ristosds_OBJECTS = ristosds.$(OBJEXT)
 ristosds_OBJECTS = $(am_ristosds_OBJECTS)
-ristosds_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(ristosds_LDFLAGS) \
-	$(LDFLAGS) -o $@
+ristosds_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(ristosds_LDFLAGS) $(LDFLAGS) -o $@
 am_vmake_OBJECTS = vmake.$(OBJEXT)
 vmake_OBJECTS = $(am_vmake_OBJECTS)
-vmake_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(vmake_LDFLAGS) \
-	$(LDFLAGS) -o $@
+vmake_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(vmake_LDFLAGS) $(LDFLAGS) -o $@
 am_vshow_OBJECTS = vshow.$(OBJEXT)
 vshow_OBJECTS = $(am_vshow_OBJECTS)
-vshow_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(vshow_LDFLAGS) \
-	$(LDFLAGS) -o $@
+vshow_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(vshow_LDFLAGS) $(LDFLAGS) -o $@
 am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
 am__vpath_adj = case $$p in \
     $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
@@ -198,19 +230,40 @@ am__uninstall_files_from_dir = { \
          $(am__cd) "$$dir" && rm -f $$files; }; \
   }
 SCRIPTS = $(bin_SCRIPTS)
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 SOURCES = $(gif2hdf_SOURCES) $(hdf24to8_SOURCES) $(hdf2gif_SOURCES) \
 	$(hdf2jpeg_SOURCES) $(hdf8to24_SOURCES) $(hdfcomp_SOURCES) \
 	$(hdfed_SOURCES) $(hdfls_SOURCES) $(hdfpack_SOURCES) \
@@ -229,15 +282,202 @@ am__can_run_installinfo = \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
+TEST_SUITE_LOG = test-suite.log
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -322,6 +562,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -509,7 +750,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
-.SUFFIXES: .c .lo .o .obj
+.SUFFIXES: .c .lo .log .o .obj .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -558,10 +799,12 @@ install-binPROGRAMS: $(bin_PROGRAMS)
 	fi; \
 	for p in $$list; do echo "$$p $$p"; done | \
 	sed 's/$(EXEEXT)$$//' | \
-	while read p p1; do if test -f $$p || test -f $$p1; \
-	  then echo "$$p"; echo "$$p"; else :; fi; \
+	while read p p1; do if test -f $$p \
+	 || test -f $$p1 \
+	  ; then echo "$$p"; echo "$$p"; else :; fi; \
 	done | \
-	sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \
+	sed -e 'p;s,.*/,,;n;h' \
+	    -e 's|.*|.|' \
 	    -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
 	sed 'N;N;N;s,\n, ,g' | \
 	$(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
@@ -582,7 +825,8 @@ uninstall-binPROGRAMS:
 	@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
 	files=`for p in $$list; do echo "$$p"; done | \
 	  sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
-	      -e 's/$$/$(EXEEXT)/' `; \
+	      -e 's/$$/$(EXEEXT)/' \
+	`; \
 	test -n "$$list" || exit 0; \
 	echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
 	cd "$(DESTDIR)$(bindir)" && rm -f $$files
@@ -604,60 +848,78 @@ clean-checkPROGRAMS:
 	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
 	echo " rm -f" $$list; \
 	rm -f $$list
+
 gif2hdf$(EXEEXT): $(gif2hdf_OBJECTS) $(gif2hdf_DEPENDENCIES) $(EXTRA_gif2hdf_DEPENDENCIES) 
 	@rm -f gif2hdf$(EXEEXT)
-	$(gif2hdf_LINK) $(gif2hdf_OBJECTS) $(gif2hdf_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(gif2hdf_LINK) $(gif2hdf_OBJECTS) $(gif2hdf_LDADD) $(LIBS)
+
 hdf24to8$(EXEEXT): $(hdf24to8_OBJECTS) $(hdf24to8_DEPENDENCIES) $(EXTRA_hdf24to8_DEPENDENCIES) 
 	@rm -f hdf24to8$(EXEEXT)
-	$(hdf24to8_LINK) $(hdf24to8_OBJECTS) $(hdf24to8_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdf24to8_LINK) $(hdf24to8_OBJECTS) $(hdf24to8_LDADD) $(LIBS)
+
 hdf2gif$(EXEEXT): $(hdf2gif_OBJECTS) $(hdf2gif_DEPENDENCIES) $(EXTRA_hdf2gif_DEPENDENCIES) 
 	@rm -f hdf2gif$(EXEEXT)
-	$(hdf2gif_LINK) $(hdf2gif_OBJECTS) $(hdf2gif_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdf2gif_LINK) $(hdf2gif_OBJECTS) $(hdf2gif_LDADD) $(LIBS)
+
 hdf2jpeg$(EXEEXT): $(hdf2jpeg_OBJECTS) $(hdf2jpeg_DEPENDENCIES) $(EXTRA_hdf2jpeg_DEPENDENCIES) 
 	@rm -f hdf2jpeg$(EXEEXT)
-	$(hdf2jpeg_LINK) $(hdf2jpeg_OBJECTS) $(hdf2jpeg_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdf2jpeg_LINK) $(hdf2jpeg_OBJECTS) $(hdf2jpeg_LDADD) $(LIBS)
+
 hdf8to24$(EXEEXT): $(hdf8to24_OBJECTS) $(hdf8to24_DEPENDENCIES) $(EXTRA_hdf8to24_DEPENDENCIES) 
 	@rm -f hdf8to24$(EXEEXT)
-	$(hdf8to24_LINK) $(hdf8to24_OBJECTS) $(hdf8to24_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdf8to24_LINK) $(hdf8to24_OBJECTS) $(hdf8to24_LDADD) $(LIBS)
+
 hdfcomp$(EXEEXT): $(hdfcomp_OBJECTS) $(hdfcomp_DEPENDENCIES) $(EXTRA_hdfcomp_DEPENDENCIES) 
 	@rm -f hdfcomp$(EXEEXT)
-	$(hdfcomp_LINK) $(hdfcomp_OBJECTS) $(hdfcomp_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdfcomp_LINK) $(hdfcomp_OBJECTS) $(hdfcomp_LDADD) $(LIBS)
+
 hdfed$(EXEEXT): $(hdfed_OBJECTS) $(hdfed_DEPENDENCIES) $(EXTRA_hdfed_DEPENDENCIES) 
 	@rm -f hdfed$(EXEEXT)
-	$(hdfed_LINK) $(hdfed_OBJECTS) $(hdfed_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdfed_LINK) $(hdfed_OBJECTS) $(hdfed_LDADD) $(LIBS)
+
 hdfls$(EXEEXT): $(hdfls_OBJECTS) $(hdfls_DEPENDENCIES) $(EXTRA_hdfls_DEPENDENCIES) 
 	@rm -f hdfls$(EXEEXT)
-	$(hdfls_LINK) $(hdfls_OBJECTS) $(hdfls_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdfls_LINK) $(hdfls_OBJECTS) $(hdfls_LDADD) $(LIBS)
+
 hdfpack$(EXEEXT): $(hdfpack_OBJECTS) $(hdfpack_DEPENDENCIES) $(EXTRA_hdfpack_DEPENDENCIES) 
 	@rm -f hdfpack$(EXEEXT)
-	$(hdfpack_LINK) $(hdfpack_OBJECTS) $(hdfpack_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdfpack_LINK) $(hdfpack_OBJECTS) $(hdfpack_LDADD) $(LIBS)
+
 hdftopal$(EXEEXT): $(hdftopal_OBJECTS) $(hdftopal_DEPENDENCIES) $(EXTRA_hdftopal_DEPENDENCIES) 
 	@rm -f hdftopal$(EXEEXT)
-	$(hdftopal_LINK) $(hdftopal_OBJECTS) $(hdftopal_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdftopal_LINK) $(hdftopal_OBJECTS) $(hdftopal_LDADD) $(LIBS)
+
 hdftor8$(EXEEXT): $(hdftor8_OBJECTS) $(hdftor8_DEPENDENCIES) $(EXTRA_hdftor8_DEPENDENCIES) 
 	@rm -f hdftor8$(EXEEXT)
-	$(hdftor8_LINK) $(hdftor8_OBJECTS) $(hdftor8_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdftor8_LINK) $(hdftor8_OBJECTS) $(hdftor8_LDADD) $(LIBS)
+
 hdfunpac$(EXEEXT): $(hdfunpac_OBJECTS) $(hdfunpac_DEPENDENCIES) $(EXTRA_hdfunpac_DEPENDENCIES) 
 	@rm -f hdfunpac$(EXEEXT)
-	$(hdfunpac_LINK) $(hdfunpac_OBJECTS) $(hdfunpac_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdfunpac_LINK) $(hdfunpac_OBJECTS) $(hdfunpac_LDADD) $(LIBS)
+
 jpeg2hdf$(EXEEXT): $(jpeg2hdf_OBJECTS) $(jpeg2hdf_DEPENDENCIES) $(EXTRA_jpeg2hdf_DEPENDENCIES) 
 	@rm -f jpeg2hdf$(EXEEXT)
-	$(jpeg2hdf_LINK) $(jpeg2hdf_OBJECTS) $(jpeg2hdf_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(jpeg2hdf_LINK) $(jpeg2hdf_OBJECTS) $(jpeg2hdf_LDADD) $(LIBS)
+
 paltohdf$(EXEEXT): $(paltohdf_OBJECTS) $(paltohdf_DEPENDENCIES) $(EXTRA_paltohdf_DEPENDENCIES) 
 	@rm -f paltohdf$(EXEEXT)
-	$(paltohdf_LINK) $(paltohdf_OBJECTS) $(paltohdf_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(paltohdf_LINK) $(paltohdf_OBJECTS) $(paltohdf_LDADD) $(LIBS)
+
 r8tohdf$(EXEEXT): $(r8tohdf_OBJECTS) $(r8tohdf_DEPENDENCIES) $(EXTRA_r8tohdf_DEPENDENCIES) 
 	@rm -f r8tohdf$(EXEEXT)
-	$(r8tohdf_LINK) $(r8tohdf_OBJECTS) $(r8tohdf_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(r8tohdf_LINK) $(r8tohdf_OBJECTS) $(r8tohdf_LDADD) $(LIBS)
+
 ristosds$(EXEEXT): $(ristosds_OBJECTS) $(ristosds_DEPENDENCIES) $(EXTRA_ristosds_DEPENDENCIES) 
 	@rm -f ristosds$(EXEEXT)
-	$(ristosds_LINK) $(ristosds_OBJECTS) $(ristosds_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(ristosds_LINK) $(ristosds_OBJECTS) $(ristosds_LDADD) $(LIBS)
+
 vmake$(EXEEXT): $(vmake_OBJECTS) $(vmake_DEPENDENCIES) $(EXTRA_vmake_DEPENDENCIES) 
 	@rm -f vmake$(EXEEXT)
-	$(vmake_LINK) $(vmake_OBJECTS) $(vmake_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(vmake_LINK) $(vmake_OBJECTS) $(vmake_LDADD) $(LIBS)
+
 vshow$(EXEEXT): $(vshow_OBJECTS) $(vshow_DEPENDENCIES) $(EXTRA_vshow_DEPENDENCIES) 
 	@rm -f vshow$(EXEEXT)
-	$(vshow_LINK) $(vshow_OBJECTS) $(vshow_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(vshow_LINK) $(vshow_OBJECTS) $(vshow_LDADD) $(LIBS)
 install-binSCRIPTS: $(bin_SCRIPTS)
 	@$(NORMAL_INSTALL)
 	@list='$(bin_SCRIPTS)'; test -n "$(bindir)" || list=; \
@@ -728,25 +990,25 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/writehdf.Po at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -754,26 +1016,15 @@ mostlyclean-libtool:
 clean-libtool:
 	-rm -rf .libs _libs
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -785,15 +1036,11 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -802,9 +1049,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -820,6 +1068,151 @@ cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all $(check_PROGRAMS) $(check_SCRIPTS)
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -879,6 +1272,9 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 
@@ -963,20 +1359,21 @@ uninstall-am: uninstall-binPROGRAMS uninstall-binSCRIPTS
 
 .MAKE: check-am install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am all-local check check-TESTS check-am \
-	clean clean-binPROGRAMS clean-checkPROGRAMS clean-generic \
-	clean-libtool cscopelist ctags distclean distclean-compile \
-	distclean-generic distclean-libtool distclean-local \
-	distclean-tags distdir dvi dvi-am html html-am info info-am \
-	install install-am install-binPROGRAMS install-binSCRIPTS \
-	install-data install-data-am install-dvi install-dvi-am \
-	install-exec install-exec-am install-html install-html-am \
-	install-info install-info-am install-man install-pdf \
-	install-pdf-am install-ps install-ps-am install-strip \
-	installcheck installcheck-am installdirs maintainer-clean \
+.PHONY: CTAGS GTAGS TAGS all all-am all-local check check-TESTS \
+	check-am clean clean-binPROGRAMS clean-checkPROGRAMS \
+	clean-generic clean-libtool cscopelist-am ctags ctags-am \
+	distclean distclean-compile distclean-generic \
+	distclean-libtool distclean-local distclean-tags distdir dvi \
+	dvi-am html html-am info info-am install install-am \
+	install-binPROGRAMS install-binSCRIPTS install-data \
+	install-data-am install-dvi install-dvi-am install-exec \
+	install-exec-am install-html install-html-am install-info \
+	install-info-am install-man install-pdf install-pdf-am \
+	install-ps install-ps-am install-strip installcheck \
+	installcheck-am installdirs maintainer-clean \
 	maintainer-clean-generic mostlyclean mostlyclean-compile \
 	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
-	pdf-am ps ps-am tags uninstall uninstall-am \
+	pdf-am ps ps-am recheck tags tags-am uninstall uninstall-am \
 	uninstall-binPROGRAMS uninstall-binSCRIPTS
 
 
diff --git a/hdf/util/fp2hdf.c b/hdf/util/fp2hdf.c
index d35308e..4e1866d 100644
--- a/hdf/util/fp2hdf.c
+++ b/hdf/util/fp2hdf.c
@@ -472,7 +472,7 @@ main(int argc, char *argv[])
                     break;
                 case ERR:   /* command syntax error */
                 default:
-                    (void) fprintf(stderr, err2);
+                    (void) fprintf(stderr, "%s", err2);
                     usage(argv[0]);
                     goto err;
             }
@@ -483,7 +483,7 @@ main(int argc, char *argv[])
      */
     if (!outfile_named)
       {
-          (void) fprintf(stderr, err3);
+          (void) fprintf(stderr, "%s", err3);
           usage(argv[0]);
           goto err;
       }
@@ -501,7 +501,7 @@ main(int argc, char *argv[])
     return(0);
 
   err:
-    (void) fprintf(stderr, err4);
+    (void) fprintf(stderr, "%s", err4);
     return(1);
 }
 
@@ -1361,7 +1361,7 @@ indexes(float32 *scale, int dim, int *idx, int res)
      */
     if ((midpt = (float32 *) HDmalloc((size_t) dim * sizeof(float32))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
     for (i = 0; i < dim - 1; i++)
@@ -1463,13 +1463,13 @@ interp(struct Input *in, struct Raster *im)
      */
     if ((hratio = (float32 *) HDmalloc((size_t) im->hres * sizeof(float32))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
     if ((vratio = (float32 *) HDmalloc((unsigned int) im->vres *
                                          sizeof(float32))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
     if (in->rank == 3)
@@ -1477,7 +1477,7 @@ interp(struct Input *in, struct Raster *im)
           if ((dratio = (float32 *) HDmalloc((unsigned int) im->dres *
                                                sizeof(float32))) == NULL)
             {
-                (void) fprintf(stderr, err1);
+                (void) fprintf(stderr, "%s", err1);
                 goto err;
             }
       }
@@ -1489,13 +1489,13 @@ interp(struct Input *in, struct Raster *im)
     if ((hinc = (int *) HDmalloc((unsigned int) im->hres *
                                    sizeof(int))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
     if ((voff = (int *) HDmalloc((unsigned int) (im->vres + 1) *
                                    sizeof(int))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
     if (in->rank == 3)
@@ -1503,7 +1503,7 @@ interp(struct Input *in, struct Raster *im)
           if ((doff = (int *) HDmalloc((unsigned int) (im->dres + 1) *
                                          sizeof(int))) == NULL)
             {
-                (void) fprintf(stderr, err1);
+                (void) fprintf(stderr, "%s", err1);
                 goto err;
             }
       }
@@ -1774,7 +1774,7 @@ palette(char *palfile)
      */
     if (DFR8setpalette(pal))
       {
-          (void) fprintf(stderr, err3);
+          (void) fprintf(stderr, "%s", err3);
           goto err;
       }
 
@@ -1816,7 +1816,7 @@ pixrep(struct Input *in, struct Raster *im)
      */
     if ((hidx = (int *) HDmalloc((unsigned int) (im->hres + 1) * sizeof(int))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
 
@@ -1829,7 +1829,7 @@ pixrep(struct Input *in, struct Raster *im)
     if ((vidx = (int *) HDmalloc((unsigned int) (im->vres + 1) *
                                    sizeof(int))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
 
@@ -1846,7 +1846,7 @@ pixrep(struct Input *in, struct Raster *im)
           if ((didx = (int *) HDmalloc((unsigned int) (im->dres + 1) *
                                          sizeof(int))) == NULL)
             {
-                (void) fprintf(stderr, err1);
+                (void) fprintf(stderr, "%s", err1);
                 goto err;
             }
 
@@ -1860,7 +1860,7 @@ pixrep(struct Input *in, struct Raster *im)
     if ((pix = (unsigned char *) HDmalloc((unsigned int) (in->dims[0] + 1))) ==
         NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
     for (k = 0, odidx = didx[0] - 1; k < im->dres; k++)
@@ -2004,13 +2004,13 @@ process(struct Options *opt)
           if ((in.hscale = (float32 *) HDmalloc((size_t)
                              (in.dims[0] + 1) * sizeof(float32))) == NULL)
             {
-                (void) fprintf(stderr, err2);
+                (void) fprintf(stderr, "%s", err2);
                 goto err;
             }
           if ((in.vscale = (float32 *) HDmalloc((size_t)
                              (in.dims[1] + 1) * sizeof(float32))) == NULL)
             {
-                (void) fprintf(stderr, err2);
+                (void) fprintf(stderr, "%s", err2);
                 goto err;
             }
           if (in.rank == 3)
@@ -2018,7 +2018,7 @@ process(struct Options *opt)
                 if ((in.dscale = (float32 *) HDmalloc((size_t)
                              (in.dims[2] + 1) * sizeof(float32))) == NULL)
                   {
-                      (void) fprintf(stderr, err2);
+                      (void) fprintf(stderr, "%s", err2);
                       goto err;
                   }
             }
@@ -2032,7 +2032,7 @@ process(struct Options *opt)
           if ((in.data = (VOIDP) HDmalloc((size_t) len *
                                                  sizeof(float32))) == NULL)
             {
-                (void) fprintf(stderr, err2);
+                (void) fprintf(stderr, "%s", err2);
                 goto err;
             }
           if (gdata(opt->infiles[i], &in, strm, &is_maxmin))
@@ -2061,19 +2061,19 @@ process(struct Options *opt)
 
                 if (DFSDsetNT(DFNT_FLOAT32))
                   {
-                      (void) fprintf(stderr, err5);
+                      (void) fprintf(stderr, "%s", err5);
                       goto err;
                   }
                 if (is_scale == TRUE)
                   {
                       if (DFSDsetdims(in.rank, hdfdims))
                         {
-                            (void) fprintf(stderr, err5);
+                            (void) fprintf(stderr, "%s", err5);
                             goto err;
                         }
                       if (DFSDsetrange(&in.max, &in.min))
                         {
-                            (void) fprintf(stderr, err5);
+                            (void) fprintf(stderr, "%s", err5);
                             goto err;
                         }
                       if (in.rank == 2)
@@ -2081,13 +2081,13 @@ process(struct Options *opt)
                             if (DFSDsetdimscale(1, hdfdims[0],
                                                 in.vscale))
                               {
-                                  (void) fprintf(stderr, err5);
+                                  (void) fprintf(stderr, "%s", err5);
                                   goto err;
                               }
                             if (DFSDsetdimscale(2, hdfdims[1],
                                                 in.hscale))
                               {
-                                  (void) fprintf(stderr, err5);
+                                  (void) fprintf(stderr, "%s", err5);
                                   goto err;
                               }
                         }
@@ -2096,26 +2096,26 @@ process(struct Options *opt)
                             if (DFSDsetdimscale(1, hdfdims[0],
                                                 in.dscale))
                               {
-                                  (void) fprintf(stderr, err5);
+                                  (void) fprintf(stderr, "%s", err5);
                                   goto err;
                               }
                             if (DFSDsetdimscale(2, hdfdims[1],
                                                 in.vscale))
                               {
-                                  (void) fprintf(stderr, err5);
+                                  (void) fprintf(stderr, "%s", err5);
                                   goto err;
                               }
                             if (DFSDsetdimscale(3, hdfdims[2],
                                                 in.hscale))
                               {
-                                  (void) fprintf(stderr, err5);
+                                  (void) fprintf(stderr, "%s", err5);
                                   goto err;
                               }
                         }
                   }
                 if (DFSDadddata(opt->outfile, in.rank, hdfdims, in.data))
                   {
-                      (void) fprintf(stderr, err5);
+                      (void) fprintf(stderr, "%s", err5);
                       goto err;
                   }
             }
@@ -2131,7 +2131,7 @@ process(struct Options *opt)
                 im.hres = (opt->hres == 0) ? in.dims[0] : opt->hres;
                 if ((im.hres < in.dims[0]) && (opt->ctm == EXPAND))
                   {
-                      (void) fprintf(stderr, err3a);
+                      (void) fprintf(stderr, "%s", err3a);
                       (void) fprintf(stderr, err3b, "Horiz.");
                       (void) fprintf(stderr, err3c, "horiz.");
                       (void) fprintf(stderr, err3d, in.dims[0]);
@@ -2141,7 +2141,7 @@ process(struct Options *opt)
                 im.vres = (opt->vres == 0) ? in.dims[1] : opt->vres;
                 if ((im.vres < in.dims[1]) && (opt->ctm == EXPAND))
                   {
-                      (void) fprintf(stderr, err3a);
+                      (void) fprintf(stderr, "%s", err3a);
                       (void) fprintf(stderr, err3b, "Vert.");
                       (void) fprintf(stderr, err3c, "vert.");
                       (void) fprintf(stderr, err3d, in.dims[1]);
@@ -2156,7 +2156,7 @@ process(struct Options *opt)
                       if ((im.dres < in.dims[2]) &&
                           (opt->ctm == EXPAND))
                         {
-                            (void) fprintf(stderr, err3a);
+                            (void) fprintf(stderr, "%s", err3a);
                             (void) fprintf(stderr, err3b, "Depth");
                             (void) fprintf(stderr, err3c, "depth");
                             (void) fprintf(stderr, err3d,
@@ -2169,7 +2169,7 @@ process(struct Options *opt)
                 if ((im.image = (unsigned char *) HDmalloc((unsigned
                                                          int) len)) == NULL)
                   {
-                      (void) fprintf(stderr, err2);
+                      (void) fprintf(stderr, "%s", err2);
                       goto err;
                   }
 
@@ -2199,7 +2199,7 @@ process(struct Options *opt)
                       if (DFR8addimage(opt->outfile, ip, im.hres,
                                        im.vres, DFTAG_RLE))
                         {
-                            (void) fprintf(stderr, err4);
+                            (void) fprintf(stderr, "%s", err4);
                             goto err;
                         }
                   }
diff --git a/hdf/util/h4cc.in b/hdf/util/h4cc.in
old mode 100755
new mode 100644
index e445f4a..4864234
--- a/hdf/util/h4cc.in
+++ b/hdf/util/h4cc.in
@@ -52,7 +52,16 @@ LIBS="@LIBS@"
 CC="${HDF4_CC:-$CCBASE}"
 CLINKER="${HDF4_CLINKER:-$CLINKERBASE}"
 
-USE_SHARED_LIB="${HDF4_USE_SHLIB:-no}"
+# If a static library is available, the default will be to use it.  If the only
+# available library is shared, it will be used by default.  The user can
+# override either default, although choosing an unavailable library will result
+# in link errors.
+STATIC_AVAILABLE="@enable_static@"
+if test "${STATIC_AVAILABLE}" = "yes"; then
+  USE_SHARED_LIB="${HDF4_USE_SHLIB:-no}"
+else
+  USE_SHARED_LIB="${HDF4_USE_SHLIB:-yes}"
+fi
 
 usage() {
   # A wonderfully informative "usage" message.
@@ -63,8 +72,10 @@ usage() {
   echo "    -prefix=DIR  Prefix directory to find HDF4 lib/ and include/"
   echo "                   subdirectories [default: $prefix]"
   echo "    -show        Show the commands without executing them"
-  echo "    -shlib       Compile with shared HDF4 libraries."
-  echo "    -noshlib     Compile with static HDF4 libraries [default]"
+  echo "    -shlib       Compile with shared HDF4 libraries [default for hdf4 built"
+  echo "                                                     without static libraries]"
+  echo "    -noshlib     Compile with static HDF4 libraries [default for hdf4 built]"
+  echo "                                                     with static libraries]"
   echo " "
   echo "  <compile line>  - the normal compile line options for your compiler."
   echo "                    $prog_name uses the same compiler you used to compile"
diff --git a/hdf/util/h4fc.in b/hdf/util/h4fc.in
old mode 100755
new mode 100644
diff --git a/hdf/util/h4redeploy.in b/hdf/util/h4redeploy.in
old mode 100755
new mode 100644
diff --git a/hdf/util/hdf2gif.c b/hdf/util/hdf2gif.c
index fb4670c..4006d4e 100644
--- a/hdf/util/hdf2gif.c
+++ b/hdf/util/hdf2gif.c
@@ -143,7 +143,7 @@ int main(int argc , char **argv) {
 	if(file_id == -1) {
 		printf("Unable to open HDF file");
 		status = HEvalue(1);
-		printf(HEstring(status));
+		printf("%s\n", HEstring(status));
 		exit(0);
 	}
 	
@@ -162,7 +162,7 @@ int main(int argc , char **argv) {
 	
 	if ((status = GRfileinfo(gr_id , &n_images , &n_fileattributes)) == -1) {
 		status = HEvalue(1);
-		printf(HEstring(status));
+		printf("%s\n", HEstring(status));
 		exit(0);
 	}
 	
diff --git a/hdf/util/hdfrseq.c b/hdf/util/hdfrseq.c
deleted file mode 100644
index 1685ea3..0000000
--- a/hdf/util/hdfrseq.c
+++ /dev/null
@@ -1,706 +0,0 @@
-/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
- * Copyright by The HDF Group.                                               *
- * Copyright by the Board of Trustees of the University of Illinois.         *
- * All rights reserved.                                                      *
- *                                                                           *
- * This file is part of HDF.  The full HDF 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      *
- * http://hdfgroup.org/products/hdf4/doc/Copyright.html.  If you do not have *
- * access to either file, you may request a copy from help at hdfgroup.org.     *
- * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-
-#ifdef RCSID
-static char RcsId[] = "@(#)$Revision: 6013 $";
-#endif
-
-/* $Id: hdfrseq.c 6013 2014-01-10 21:19:02Z acheng $ */
-
-/*    hdfrseq
-   *  Sequencer for NCSA Hierarchical Data Format files
-   *
-   *  Display images on a remote ICR terminal
-   *  in sequence, suitable for onscreen animation.  Can expand the image size
-   *  on the fly.
-   *
-   *  This version now supports displaying an image in a window on a Silicon
-   *  Graphics Iris 4D workstation.  There are bugs in this code (possibly due
-   *  to evolving system software combined with old code).
-   *
-   *  National Center for Supercomputing Applications
-   *  University of Illinois, Urbana-Champaign
-   *
-   *  by Tim Krauskopf
-   *  first version of seq 7/11/86
-   *  modifications        2/20/87
-   *  re-write             6/21/88
-   *  Iris 4D support      6/24/89  Mike Krogh
-   *  Line padding              9/25/89  Chin-Chau Low
-   *  In-between versions re-written by Gaige B. Paulsen and Swami Natarajan
-   *  ANSI-fication & relegation to remote-only use
-   *                    6/9/92   Doug Ilg
-   *
-   *  This program is in the public domain
-   *
- */
-#include "hdf.h"    /* HDF includes */
-
-#ifdef IRIS4
-#include <gl.h>
-#include <device.h>
-#endif
-
-#ifndef IRIS4
-#define  SCRX    1152
-#define  SCRY    900
-#endif
-
-#ifdef IRIS4
-#define  SCRX    1280
-#define  SCRY    1024
-#endif
-
-#define  LUSAGE   printf("\nUsage: %s [-s] [-l] [-e exp] [-p xwhere ywhere] file1 file2 . . .\n",argv[0])
-#define  RUSAGE   printf("\nUsage: %s [-s] [-l] [-e exp] file1 file2 . . .\n",argv[0])
-#define USAGE   if (remote) { RUSAGE; } else { LUSAGE; }
-
-int
-            oldcf = 0,          /* old value of compression flag */
-            oldx = 0, oldy = 0, /* old values of xdim and ydim */
-            coldx = 0, coldy = 0,   /* old values of xdim and ydim for CI8s */
-            xwhere = 0, ywhere = 0,     /* where to put it on the screen */
-            step = 0,           /* single step? */
-            remote = 0,         /* should use ICR for remote display */
-            large = 0,          /* should make images as large as possible */
-            center = 1,         /* should center the images */
-            startpic = 1,       /* for parameter counts */
-            oldxs = 0, oldys = 0,   /* old sizes */
-            xsize = 0, ysize = 0,   /* what final size on screen, after blow-up */
-            xfact = 1, yfact = 1;   /* what factor for blowing up the picture */
-
-int32       xdim = 0, ydim = 0; /* size of image on disk */
-
-#ifdef NEEDPAD
-int         xpad;
-#endif
-
-#ifdef IRIS4
-int         GID;
-unsigned short *img = NULL;
-int         WINDOW_OPEN = 0;
-int16       idev, qvalue;
-int         attached = 1;
-#endif
-
-char
-            rgb[768],           /* storage for a palette */
-           *wherebig = NULL,    /* where to store small image */
-           *wheresmall = NULL;  /* where to store image-related stuff */
-
-int         main(int, char *a[]);
-int         getspace(void);
-int         getpix(void);
-int         largeset(void);
-int         showpic(char *);
-int         piximage(int);
-int         rimage(int);
-int         bigimg(unsigned char *, unsigned char *);
-int         rleit(char *, char *, int);
-
-/*************************************************************************/
-/*  hdfseq
-   *   Load the images from the specified files.
-   *   Create the internal storage if needed.
-   *
-   *   Search pattern for files:
-   *       RIG images in file
-   *       RI8 and CI8 images in file
- */
-int
-main(int argc, char *argv[])
-{
-    int         i, filearg;
-
-/*
-   *  Check to see if we are displaying on a local console or on a
-   *  remote ICR.  This program does double duty.
- */
-    i = HDstrlen(argv[0]);
-    if (HDstrncmp("hdfseq", argv[0] + i - 6, 6))
-        remote = 1;
-
-/*
-   *  Are there enough parameters?  Give user information on calling.
- */
-    if (argc < 2)
-      {
-          printf("%s,  version: 1.0   date: December 1, 1988\n", argv[0]);
-          if (remote)
-            {
-                printf(" This utility displays sequences of raster-8 images\n");
-                printf(" from HDF files on a remote device using NCSA's\n");
-                printf(" Interactive Color Raster protocol.\n\n");
-            }
-          if (!remote)
-            {
-#ifdef SUN
-                printf(" This utility displays sequences of raster-8 images\n");
-                printf(" from HDF files on the Sun console running Sunview.\n");
-#endif
-#ifdef IRIS4
-                printf(" This utility displays sequences of raster-8 images\n");
-                printf(" from HDF files on the Iris console running 4Sight.\n");
-#endif
-                printf("\n");
-            }
-          USAGE;
-          puts(" -l              make image as large as possible");
-          puts(" -e expansion    expand image by a certain factor");
-          if (!remote)
-              puts(" -p xloc yloc    position on screen");
-          puts(" -s              step through images");
-          exit(1);
-      }
-
-/*
-   *  work on parms
- */
-    for (i = 1; i < argc; i++)
-      {     /* look at each parm */
-          if (*argv[i] == '-')
-              switch (*(argv[i] + 1))
-                {
-                    case 'p':   /* special position on screen */
-                        center = 0;     /* don't center */
-                        xwhere = atoi(argv[++i]);
-                        ywhere = atoi(argv[++i]);
-                        if (xwhere > SCRX || ywhere > SCRY)
-                          {
-                              puts("\n Invalid position ");
-                              USAGE;
-                              exit(1);
-                          }
-                        startpic += 3;
-                        break;
-                    case 'e':
-                        xfact = yfact = atoi(argv[++i]);
-                        if (xfact < 1)
-                          {
-                              xfact = 1;
-                              yfact = 1;
-                          }
-                        startpic += 2;
-                        break;
-                    case 'l':   /* large pic */
-                        large = 1;
-                        startpic++;
-                        break;
-                    case 's':   /* step through pics */
-                        step = 1;
-                        startpic++;
-                        break;
-                    default:
-                        USAGE;
-                        exit(1);
-                }
-      }
-
-/*
-   *  Process each of the files in the command string.
-   *
- */
-    for (filearg = startpic; filearg < argc; filearg++)
-        showpic(argv[filearg]);
-
-#ifdef IRIS4
-    if ((!remote) && (img))     /* make sure we have an image */
-        while (1)
-          {
-              idev = qread(&qvalue);
-              if (idev == REDRAW)
-                {
-                    reshapeviewport();
-                    if (img != NULL)
-                      {
-                          rectwrite(0, 0, (xdim - 1), (ydim - 1), img);
-                          swapbuffers();
-                      }
-                }
-          }
-#endif
-
-    exit(0);
-}
-
-/*************************************************************************/
-/*  getspace
-   *  Provide enough space in the space pointers for the operations
-   *  to all work.
- */
-int
-getspace(void)
-{
-
-/*
-   *  Don't allocate anything if the image is the same size as before.
- */
-    if (oldx != xdim || oldy != ydim)
-      {
-          oldx = xdim;
-          oldy = ydim;
-
-          if (wheresmall)
-              HDfree(wheresmall);
-
-          if (NULL == (wheresmall = (char *) HDmalloc(xdim * ydim)))
-            {
-                puts(" Cannot allocate memory, fatal error");
-                exit(1);
-            }
-
-      }
-    return (0);
-}
-
-#ifdef IRIS4
-/*
-   *  Allocate the space for the image if displaying locally
- */
-getpix(void)
-{
-/*
-   *  Allocation will take place because xsize and ysize will
-   *  be set before calling this routine.
-   *
- */
-    if (!remote && (oldxs != xsize || oldys != ysize))
-      {
-          oldxs = xsize;
-          oldys = ysize;
-          if (img)
-              HDfree(img);
-          if ((img = (unsigned short *) HDmalloc(xdim * ydim * sizeof(short))) == NULL)
-            {
-                puts(" Cannot allocate memory, fatal error");
-                exit(1);
-            }
-
-      }
-    return (0);
-}
-#endif
-
-/*************************************************************************/
-/*  largeset
-   *  Set up the xfact, yfact, xsize and ysize for expanding the image
-   *  locally.
-   *
- */
-int
-largeset(void)
-{
-
-    if (large)
-      {
-          xfact = SCRX / xdim;  /* how much blow-up can we do? */
-          yfact = SCRY / ydim;  /* calculate expansion factor  */
-          if (xfact > yfact)
-              xfact = yfact;
-          else
-              yfact = xfact;
-      }
-
-    xsize = xfact * xdim;   /* re-calculate actual pixel dimensions */
-    ysize = yfact * ydim;
-
-#ifdef NEEDPAD  /* add padding for byte boundary */
-    xpad = BYTEBOUND - xsize % BYTEBOUND;
-    if (xpad == BYTEBOUND)
-        xpad = 0;
-    else
-        xsize += xpad;
-#ifdef DEBUG
-    printf("xpad %d\n", xpad);
-#endif /*DEBUG */
-    return (xfact > 1 || yfact > 1 || xpad > 0);    /* is expansion necessary? */
-#endif /*NEEDPAD */
-
-#ifndef NEEDPAD     /* make sure there is only 1 return stmt */
-    return (xfact > 1 || yfact > 1);    /* is expansion necessary? */
-#endif /*NEEDPAD */
-}
-
-/*************************************************************************/
-/*  showpic
-   *  For each file, search for the components that we can display.
-   *  Display them according to the remote flag on or off.
-   *
- */
-int
-showpic(char *filename)
-{
-    int         ispal, r8_exists;
-
-    oldx = xdim;
-    oldy = ydim;    /* save old values */
-
-    if (-1 == Hishdf(filename))
-      {
-          printf("\'%s\' is not an HDF Format Data File.\n", filename);
-          return (0);
-      }
-/*
-   *  Search for all RIGs in this file.
-   *  Process each RIG and display.
- */
-    r8_exists = FALSE;
-    while (1)
-      {
-          if (DFR8getdims(filename, &xdim, &ydim, &ispal) < 0)
-            {
-                if (!r8_exists)
-                    printf("There are no 8-bit images in the file %s\n", filename);
-                break;  /* all RIGs processed */
-            }
-          r8_exists = TRUE;     /* at least one 8-bit image found */
-
-#ifdef DEBUG
-          printf("xdim %d ydim %d\n", xdim, ydim);
-#endif /*DEBUG */
-#ifdef IRIS4
-          if (!remote)
-            {
-                largeset();     /* set expansion needs */
-                getspace();     /* get local space for pre-expansion */
-                getpix();   /* allocate memory */
-            }
-#endif
-
-          if (remote)
-              getspace();   /* get space for image in mem */
-
-/*
-   *  Try to successfully load the palette and image from the file
- */
-          if (!DFR8getimage(filename, (uint8 *) wheresmall, xdim, ydim, (uint8 *) rgb))
-            {
-                if (remote)
-                    rimage(ispal);  /* display remote image with [palette] */
-#ifdef IRIS4
-                else
-                    piximage(ispal);    /* display image on Iris with [palette] */
-#endif
-            }
-          else
-              puts(" Error loading image");
-
-      }
-
-    return (0);
-
-}
-
-#ifdef IRIS4
-/***********************************************************************/
-/*  piximage
-   *  On the Iris console, display the image as the parameters specify.
-   *  Handles centering (center)
-   *  Uses xwhere and ywhere, xsize and ysize.
-   *  Performs expansion if xfact or yfact > 1
-   *  Takes the palette from the rgb[] if asked to.
-   *  Will pause if step=1.
- */
-piximage(int usepal)
-{
-    char       *pp;
-    int         r, g, b;
-    int         j, j1, j2, k;
-
-/*
-   *  compute centering values, based on new size
- */
-    if (center)
-      {
-          xwhere = (SCRX - xsize) / 2;
-          ywhere = (SCRY - ysize) / 2;
-          if (xwhere < 0)
-              xwhere = 0;
-          if (ywhere < 0)
-              ywhere = 0;
-      }
-
-    if (!WINDOW_OPEN)
-      {
-          WINDOW_OPEN = 1;
-          if (step)
-            {
-                printf("Press <enter> to step through images or");
-                printf(" 'Q' to quit.\n");
-            }
-          prefposition(xwhere, (xwhere + xsize), ywhere, (ywhere + ysize));
-          GID = winopen("hdfseq");  /* open the window */
-          shademodel(FLAT);     /* don't worry about shading */
-          doublebuffer();
-          multimap();
-          gconfig();
-          setmap(4);
-          color(BLACK);
-          clear();
-          qdevice(REDRAW);
-          if (step)
-            {
-                qdevice(QKEY);
-                qdevice(RETKEY);
-                qdevice(INPUTCHANGE);
-            }
-      }
-
-/*
-   * Process window movement events.
- */
-    while (qtest())
-      {
-          idev = qread(&qvalue);
-          if (idev == REDRAW)
-            {
-                reshapeviewport();
-                if (img != NULL)
-                  {
-                      rectwrite(0, 0, (xdim - 1), (ydim - 1), img);
-                      swapbuffers();
-                  }
-            }
-          if (idev == INPUTCHANGE)
-              attached = qvalue;
-      }
-
-/*
-   *  Do the image expansion, if called for.
- */
-    if (xfact > 1 || yfact > 1)
-        rectzoom((float32) xfact, (float) yfact);   /* let the iris scale it */
-
-/*
-   *  Set the display palette to the new palette.
- */
-
-    if (usepal)
-      {
-          pp = rgb;
-          for (j = 0; j < 256; j++)
-            {
-                r = (int) (*pp++);
-                g = (int) (*pp++);
-                b = (int) (*pp++);
-                mapcolor(j, r, g, b);   /* change the system palette */
-            }
-      }
-
-/*
-   * Convert image data to iris pixel format
-   * flip it upside down and convert to short integers.
- */
-
-    for (j = 0; j < ydim; j++)
-      {
-          j1 = (ydim - j - 1) * xdim;
-          j2 = j * xdim;
-          for (k = 0; k < xdim; k++)
-              *(img + j1 + k) = (short) (*(wheresmall + j2 + k));
-      }
-
-    rectwrite(0, 0, (xdim - 1), (ydim - 1), img);
-    swapbuffers();
-
-    if (step)
-      {
-          while (1)
-            {
-                idev = qread(&qvalue);
-                if (idev == REDRAW)
-                  {
-                      reshapeviewport();
-                      if (img != NULL)
-                        {
-                            rectwrite(0, 0, (xdim - 1), (ydim - 1), img);
-                            swapbuffers();
-                        }
-                  }
-                if (idev == QKEY)
-                    exit(0);
-                if (idev == RETKEY)
-                    break;
-                if (idev == INPUTCHANGE)
-                    attached = qvalue;
-            }
-      }
-
-}
-#endif
-
-/*****************************************************************************/
-/*  rimage
-   *  Remote display of the image using the ICR.
-   *  Just print the codes to stdout using the protocol.
- */
-int
-rimage(int usepal)
-{
-    int         i, j, newxsize;
-    char       *space, *thisline, *thischar;
-    unsigned char c;
-
-/*
-   *  Open the window with the W command
- */
-
-    (void) printf("\033^W;%d;%d;%ld;%ld;0;rseq^", xwhere, ywhere, (long) (xdim * xfact), (long) (ydim * yfact));
-
-/*
-   *  If a palette should be used, send it with the M command.
- */
-    if (usepal)
-      {
-          (void) printf("\033^M;0;256;768;rseq^");  /* start map */
-
-          thischar = rgb;
-          for (j = 0; j < 768; j++)
-            {
-                c = *thischar++;
-                if (c > 31 && c < 123)
-                  {
-                      putchar(c);
-                  }
-                else
-                  {
-                      putchar((c >> 6) + 123);
-                      putchar((c & 0x3f) + 32);
-                  }
-            }
-      }
-
-/*
-   *  Send the data for the image with RLE encoding for efficiency.
-   *  Encode each line and send it.
- */
-    space = (char *) HDmalloc(ydim + 100);
-    thisline = wheresmall;
-
-    for (i = 0; i < ydim; i++)
-      {
-          newxsize = rleit(thisline, space, xdim);
-          thisline += xdim;     /* increment to next line */
-
-          (void) printf("\033^R;0;%d;%d;%d;rseq^", i * xfact, xfact, newxsize);
-
-          thischar = space;
-          for (j = 0; j < newxsize; j++)
-            {
-
-/***********************************************************************/
-/*  Encoding of bytes:
-   *
-   *  123 precedes #'s 0-63
-   *  124 precedes #'s 64-127
-   *  125 precedes #'s 128-191
-   *  126 precedes #'s 192-255
-   *  overall:  realchar = (specialchar - 123)*64 + (char-32)
-   *            specialchar = r div 64 + 123
-   *            char = r mod 64 + 32
- */
-/***********************************************************************/
-
-                c = *thischar++;    /* get byte to send */
-
-                if (c > 31 && c < 123)
-                  {
-                      putchar(c);
-                  }
-                else
-                  {
-                      putchar((c >> 6) + 123);
-                      putchar((c & 0x3f) + 32);
-                  }
-            }
-      }
-
-/*
-   *  pause for the user
- */
-    if (step)
-      {
-          printf("Press return to continue, 'q' return to quit");
-          if ('q' == getchar())
-              exit(0);
-      }
-
-    HDfree(space);
-    return (0);
-}
-
-/********************************************************************/
-/*  rleit
-   *  compress the data to go out with a simple run-length encoded scheme.
-   *
- */
-int
-rleit(char *buf, char *bufto, int len)
-{
-    char *p, *q, *cfoll, *clead;
-    char       *begp;
-    int         i;
-
-    p = buf;
-    cfoll = bufto;  /* place to copy to */
-    clead = cfoll + 1;
-
-    begp = p;
-    while (len > 0)
-      {     /* encode stuff until gone */
-
-          q = p + 1;
-          i = len - 1;
-          while (*p == *q && i + 120 > len && i)
-            {
-                q++;
-                i--;
-            }
-
-          if (q > p + 2)
-            {   /* three in a row */
-                if (p > begp)
-                  {
-                      *cfoll = p - begp;
-                      cfoll = clead;
-                  }
-                *cfoll++ = 128 | (q - p);   /* len of seq */
-                *cfoll++ = *p;  /* char of seq */
-                len -= q - p;   /* subtract len of seq */
-                p = q;
-                clead = cfoll + 1;
-                begp = p;
-            }
-          else
-            {
-                *clead++ = *p++;    /* copy one char */
-                len--;
-                if (p > begp + 120)
-                  {
-                      *cfoll = p - begp;
-                      cfoll = clead++;
-                      begp = p;
-                  }
-            }
-
-      }
-/*
-   *  fill in last bytecount
- */
-    if (p > begp)
-        *cfoll = (p - begp);
-    else
-        clead--;    /* don't need count position */
-
-    return ((int) (clead - bufto));     /* how many stored as encoded */
-}
diff --git a/hdf/util/testutil.sh.in b/hdf/util/testutil.sh.in
old mode 100755
new mode 100644
diff --git a/hdf/util/vcompat.c b/hdf/util/vcompat.c
deleted file mode 100644
index ffeed97..0000000
--- a/hdf/util/vcompat.c
+++ /dev/null
@@ -1,43 +0,0 @@
-/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
- * Copyright by The HDF Group.                                               *
- * Copyright by the Board of Trustees of the University of Illinois.         *
- * All rights reserved.                                                      *
- *                                                                           *
- * This file is part of HDF.  The full HDF 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      *
- * http://hdfgroup.org/products/hdf4/doc/Copyright.html.  If you do not have *
- * access to either file, you may request a copy from help at hdfgroup.org.     *
- * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-
-#ifdef RCSID
-static char RcsId[] = "@(#)$Revision: 6013 $";
-#endif
-
-/* $Id: vcompat.c 6013 2014-01-10 21:19:02Z acheng $ */
-#include <stdio.h>
-#include "hdf.h"
-
-int
-main(int argc, char *argv[])
-{
-    if (argc != 2)
-      {
-          fprintf(stderr, "%s: converts HDF vset v1.0 files to v2.0\n", argv[0]);
-          fprintf(stderr, "Usage: %s hdf-file\n", argv[0]);
-          exit(0);
-      }
-
-    if (0 == vcheckcompat(argv[1]))
-      {
-          vmakecompat(argv[1]);
-          fprintf(stderr, "file [%s] is now compatible\n", argv[1]);
-      }
-    else
-        fprintf(stderr, "file [%s] already compatible with r2.0\n", argv[1]);
-
-    return (0);
-}   /* main */
-
-/* ------------------------------------------------------------------ */
diff --git a/hdf/util/writehdf.c b/hdf/util/writehdf.c
index 42ebc4c..82b58e1 100644
--- a/hdf/util/writehdf.c
+++ b/hdf/util/writehdf.c
@@ -77,13 +77,13 @@ char     *GIFFileName;
 	if(file_id == -1) {
 		printf("Unable to create HDF file");
 		status = HEvalue(1);
-		printf(HEstring(status));
+		printf("%s\n", HEstring(status));
 		exit(0);
 	}
 
 	if ((status = Vstart(file_id)) == -1) {
 		printf("Could not start VGroup interface\n");
-		printf(HEstring(HEvalue(1)));
+		printf("%s\n", HEstring(HEvalue(1)));
 		exit(-1);
 	}
 
@@ -99,7 +99,7 @@ char     *GIFFileName;
 		status = Vsetattr (vgroup_id, "Global Palette" , DFNT_UINT8, 3 * gifHead.TableSize , (VOIDP)gifHead.HDFPalette);
 		if (status) {
 			printf("Could not add global palette.\n");
-			printf(HEstring(HEvalue(1)));
+			printf("%s\n", HEstring(HEvalue(1)));
 		}
 	}
 	for (i = 0 ; i < CommentCount ; i++) {
@@ -144,14 +144,14 @@ char     *GIFFileName;
 		/* GRSetCompress */
 		if ((status = GRsetcompress(ri_id, comp_type, &c_info)) == -1) {
 			printf("Error occured while setting compression\n");
-			printf(HEstring(HEvalue(1)));
+			printf("%s\n", HEstring(HEvalue(1)));
 			exit(-1);
 		}
 
 		/* Write the GR Image */
 		if ((status = GRwriteimage(ri_id, start, NULL, edges, (VOIDP)gifImageDesc.Image)) == -1) {
 			printf("Error occured while trying to write GR image\n");
-			printf(HEstring(HEvalue(1)));
+			printf("%s\n", HEstring(HEvalue(1)));
 			exit(-1);
 		}
 
@@ -160,7 +160,7 @@ char     *GIFFileName;
 
 		if ((status = GRwritelut (pal_id , 3, DFNT_UINT8, interlace_mode, 256, (VOIDP)gifImageDesc.HDFPalette)) == -1) {
 			printf("Could not write palette\n");
-			printf(HEstring(HEvalue(1)));
+			printf("%s\n", HEstring(HEvalue(1)));
 			exit(-1);
 		}
 		
@@ -169,7 +169,7 @@ char     *GIFFileName;
 		
 		if ((status = GRendaccess(ri_id)) == -1) {
 			printf("Could not terminate GR access\n");
-			printf(HEstring(HEvalue(1)));
+			printf("%s\n", HEstring(HEvalue(1)));
 			exit(-1);
 		}
 
@@ -178,7 +178,7 @@ char     *GIFFileName;
 		/* Adding GR to vgroup */
 		if((status = Vaddtagref(vgroup_id,(int32)1965,gr_ref))==-1) {
 			printf("Could not add tag to Vgroup");
-			printf(HEstring(HEvalue(1)));
+			printf("%s\n", HEstring(HEvalue(1)));
 		}
 
 		
@@ -187,28 +187,28 @@ char     *GIFFileName;
 	/* Terminate GR access */
 	if ((status = GRend (gr_id))==-1) {
 		printf("Could not end GR access\n");
-		printf(HEstring(HEvalue(1)));
+		printf("%s\n", HEstring(HEvalue(1)));
 		printf("Trying to continue (file may be corrupt)...\n");
 	}
 	
 	/* Terminate access to the VGroup */
 	if ((status = Vdetach(vgroup_id))==-1) {
 		printf("Could not detach Vgroup\n");
-		printf(HEstring(HEvalue(1)));
+		printf("%s\n", HEstring(HEvalue(1)));
 		printf("Trying to continure (file may be corrupt)...\n");
 	}
 
 	/* Terminate access to the V interface */
 	if ((status = Vend(file_id))==-1) {
 		printf("Could not end VGroup access\n");
-		printf(HEstring(HEvalue(1)));
+		printf("%s\n", HEstring(HEvalue(1)));
 		printf("Trying to continure (file may be corrupt)... \n");
 	}
 
 	/* Close the HDF file */
 	if ((status = Hclose (file_id))==-1) {
 		printf("Could not close HDF file. Fatal Error");
-		printf(HEstring(HEvalue(1)));
+		printf("%s\n", HEstring(HEvalue(1)));
 		return(-1);
 	}
 	return(0);
diff --git a/man/Makefile.in b/man/Makefile.in
index 4e89bc5..710519e 100644
--- a/man/Makefile.in
+++ b/man/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -14,23 +14,51 @@
 
 @SET_MAKE@
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -49,9 +77,8 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am
+DIST_COMMON = $(top_srcdir)/config/commence.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs
 subdir = man
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 am__aclocal_m4_deps = $(top_srcdir)/configure.ac
@@ -61,6 +88,18 @@ mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs
 CONFIG_HEADER = $(top_builddir)/hdf/src/h4config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 SOURCES =
 DIST_SOURCES =
 am__can_run_installinfo = \
@@ -99,9 +138,11 @@ man1dir = $(mandir)/man1
 am__installdirs = "$(DESTDIR)$(man1dir)"
 NROFF = nroff
 MANS = $(man1_MANS)
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -186,6 +227,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -348,29 +390,14 @@ uninstall-man1:
 	} | sed -e 's,.*/,,;h;s,.*\.,,;s,^[^1][0-9a-z]*$$,1,;x' \
 	      -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \
 	dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir)
-tags: TAGS
-TAGS:
+tags TAGS:
 
-ctags: CTAGS
-CTAGS:
+ctags CTAGS:
 
 cscope cscopelist:
 
 
 distdir: $(DISTFILES)
-	@list='$(MANS)'; if test -n "$$list"; then \
-	  list=`for p in $$list; do \
-	    if test -f $$p; then d=; else d="$(srcdir)/"; fi; \
-	    if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \
-	  if test -n "$$list" && \
-	    grep 'ab help2man is required to generate this page' $$list >/dev/null; then \
-	    echo "error: found man pages containing the 'missing help2man' replacement text:" >&2; \
-	    grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/         /' >&2; \
-	    echo "       to fix them, install help2man, remove and regenerate the man pages;" >&2; \
-	    echo "       typically 'make maintainer-clean' will remove them" >&2; \
-	    exit 1; \
-	  else :; fi; \
-	else :; fi
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	list='$(DISTFILES)'; \
@@ -508,16 +535,17 @@ uninstall-man: uninstall-man1
 .MAKE: install-am install-strip
 
 .PHONY: all all-am check check-am clean clean-generic clean-libtool \
-	distclean distclean-generic distclean-libtool distdir dvi \
-	dvi-am html html-am info info-am install install-am \
-	install-data install-data-am install-dvi install-dvi-am \
-	install-exec install-exec-am install-html install-html-am \
-	install-info install-info-am install-man install-man1 \
-	install-pdf install-pdf-am install-ps install-ps-am \
-	install-strip installcheck installcheck-am installdirs \
-	maintainer-clean maintainer-clean-generic mostlyclean \
-	mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
-	uninstall uninstall-am uninstall-man uninstall-man1
+	cscopelist-am ctags-am distclean distclean-generic \
+	distclean-libtool distdir dvi dvi-am html html-am info info-am \
+	install install-am install-data install-data-am install-dvi \
+	install-dvi-am install-exec install-exec-am install-html \
+	install-html-am install-info install-info-am install-man \
+	install-man1 install-pdf install-pdf-am install-ps \
+	install-ps-am install-strip installcheck installcheck-am \
+	installdirs maintainer-clean maintainer-clean-generic \
+	mostlyclean mostlyclean-generic mostlyclean-libtool pdf pdf-am \
+	ps ps-am tags-am uninstall uninstall-am uninstall-man \
+	uninstall-man1
 
 
 # Tell versions [3.59,3.63) of GNU make to not export all variables.
diff --git a/man/hdf.1 b/man/hdf.1
index c4fd3bd..42a58d0 100644
--- a/man/hdf.1
+++ b/man/hdf.1
@@ -1,5 +1,5 @@
-.\" $Id: hdf.1 6079 2014-02-08 00:29:03Z bmribler $
-.TH HDF 1 "February 2014" "THG HDF 4.2.10"
+.\" $Id: hdf.1 6194 2015-02-05 14:17:12Z bmribler $
+.TH HDF 1 "February 2015" "THG HDF 4.2.11"
 .SH NAME
 hdf \- Hierarchical Data Format library
 .SH SYNOPSIS
@@ -135,7 +135,7 @@ USA
 www.hdfgroup.org
 
 .SH VERSION
-4.2.10 
+4.2.11 
 .SH LICENSE & SOURCE AVAILABILITY
 Copyright by The HDF Group.
 .sp 0
diff --git a/mfhdf/CMakeLists.txt b/mfhdf/CMakeLists.txt
index 111e126..c04d80a 100644
--- a/mfhdf/CMakeLists.txt
+++ b/mfhdf/CMakeLists.txt
@@ -1,21 +1,27 @@
 cmake_minimum_required (VERSION 2.8.10)
 PROJECT (HDF4_MFHDF)
 
+if (CYGWIN)
+  INCLUDE_DIRECTORIES (/usr/include/tirpc)
+else (CYGWIN)
+  INCLUDE_DIRECTORIES (/usr/include/rpc)
+endif (CYGWIN)
+
 #-----------------------------------------------------------------------------
 # Option to build HDF4 Tools
 #-----------------------------------------------------------------------------
-IF (EXISTS "${HDF4_MFHDF_SOURCE_DIR}/dumper" AND IS_DIRECTORY "${HDF4_MFHDF_SOURCE_DIR}/dumper")
-  OPTION (HDF4_BUILD_TOOLS  "Build HDF4 Tools" OFF)
-  IF (HDF4_BUILD_TOOLS)
-    SET (NCGEN_UTILITY 0)
-    ADD_SUBDIRECTORY (${HDF4_MFHDF_SOURCE_DIR}/dumper      ${HDF4_MFHDF_BINARY_DIR}/dumper)
-    ADD_SUBDIRECTORY (${HDF4_MFHDF_SOURCE_DIR}/hdfimport   ${HDF4_MFHDF_BINARY_DIR}/hdfimport)
-    ADD_SUBDIRECTORY (${HDF4_MFHDF_SOURCE_DIR}/hdiff       ${HDF4_MFHDF_BINARY_DIR}/hdiff)
-    ADD_SUBDIRECTORY (${HDF4_MFHDF_SOURCE_DIR}/hrepack     ${HDF4_MFHDF_BINARY_DIR}/hrepack)
-    ADD_SUBDIRECTORY (${HDF4_MFHDF_SOURCE_DIR}/ncgen       ${HDF4_MFHDF_BINARY_DIR}/ncgen)
-    ADD_SUBDIRECTORY (${HDF4_MFHDF_SOURCE_DIR}/ncdump      ${HDF4_MFHDF_BINARY_DIR}/ncdump)
-    IF (BUILD_TESTING)
-      ADD_SUBDIRECTORY (${HDF4_MFHDF_SOURCE_DIR}/nctest    ${HDF4_MFHDF_BINARY_DIR}/nctest)
-    ENDIF (BUILD_TESTING )
-  ENDIF (HDF4_BUILD_TOOLS)
-ENDIF (EXISTS "${HDF4_MFHDF_SOURCE_DIR}/dumper" AND IS_DIRECTORY "${HDF4_MFHDF_SOURCE_DIR}/dumper")
+if (EXISTS "${HDF4_MFHDF_SOURCE_DIR}/dumper" AND IS_DIRECTORY "${HDF4_MFHDF_SOURCE_DIR}/dumper")
+  option (HDF4_BUILD_TOOLS  "Build HDF4 Tools" OFF)
+  if (HDF4_BUILD_TOOLS)
+    set (NCGEN_UTILITY 0)
+    add_subdirectory (${HDF4_MFHDF_SOURCE_DIR}/dumper      ${HDF4_MFHDF_BINARY_DIR}/dumper)
+    add_subdirectory (${HDF4_MFHDF_SOURCE_DIR}/hdfimport   ${HDF4_MFHDF_BINARY_DIR}/hdfimport)
+    add_subdirectory (${HDF4_MFHDF_SOURCE_DIR}/hdiff       ${HDF4_MFHDF_BINARY_DIR}/hdiff)
+    add_subdirectory (${HDF4_MFHDF_SOURCE_DIR}/hrepack     ${HDF4_MFHDF_BINARY_DIR}/hrepack)
+    add_subdirectory (${HDF4_MFHDF_SOURCE_DIR}/ncgen       ${HDF4_MFHDF_BINARY_DIR}/ncgen)
+    add_subdirectory (${HDF4_MFHDF_SOURCE_DIR}/ncdump      ${HDF4_MFHDF_BINARY_DIR}/ncdump)
+    if (BUILD_TESTING)
+      add_subdirectory (${HDF4_MFHDF_SOURCE_DIR}/nctest    ${HDF4_MFHDF_BINARY_DIR}/nctest)
+    endif (BUILD_TESTING )
+  endif (HDF4_BUILD_TOOLS)
+endif (EXISTS "${HDF4_MFHDF_SOURCE_DIR}/dumper" AND IS_DIRECTORY "${HDF4_MFHDF_SOURCE_DIR}/dumper")
diff --git a/mfhdf/Makefile.in b/mfhdf/Makefile.in
index 9c8844e..9357b62 100644
--- a/mfhdf/Makefile.in
+++ b/mfhdf/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -14,23 +14,51 @@
 
 @SET_MAKE@
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
+    esac; \
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -49,9 +77,9 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am THANKS
+DIST_COMMON = $(top_srcdir)/config/commence.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs README \
+	THANKS
 subdir = mfhdf
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 am__aclocal_m4_deps = $(top_srcdir)/configure.ac
@@ -61,15 +89,28 @@ mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs
 CONFIG_HEADER = $(top_builddir)/hdf/src/h4config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 SOURCES =
 DIST_SOURCES =
-RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
-	html-recursive info-recursive install-data-recursive \
-	install-dvi-recursive install-exec-recursive \
-	install-html-recursive install-info-recursive \
-	install-pdf-recursive install-ps-recursive install-recursive \
-	installcheck-recursive installdirs-recursive pdf-recursive \
-	ps-recursive uninstall-recursive
+RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
+	ctags-recursive dvi-recursive html-recursive info-recursive \
+	install-data-recursive install-dvi-recursive \
+	install-exec-recursive install-html-recursive \
+	install-info-recursive install-pdf-recursive \
+	install-ps-recursive install-recursive installcheck-recursive \
+	installdirs-recursive pdf-recursive ps-recursive \
+	tags-recursive uninstall-recursive
 am__can_run_installinfo = \
   case $$AM_UPDATE_INFO_DIR in \
     n|no|NO) false;; \
@@ -77,9 +118,29 @@ am__can_run_installinfo = \
   esac
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
   distclean-recursive maintainer-clean-recursive
-AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
-	$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
+am__recursive_targets = \
+  $(RECURSIVE_TARGETS) \
+  $(RECURSIVE_CLEAN_TARGETS) \
+  $(am__extra_recursive_targets)
+AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
 	distdir
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
@@ -110,6 +171,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -194,6 +256,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -329,14 +392,13 @@ clean-libtool:
 # (1) if the variable is set in 'config.status', edit 'config.status'
 #     (which will cause the Makefiles to be regenerated when you run 'make');
 # (2) otherwise, pass the desired values on the 'make' command line.
-$(RECURSIVE_TARGETS) $(RECURSIVE_CLEAN_TARGETS):
-	@fail= failcom='exit 1'; \
-	for f in x $$MAKEFLAGS; do \
-	  case $$f in \
-	    *=* | --[!k]*);; \
-	    *k*) failcom='fail=yes';; \
-	  esac; \
-	done; \
+$(am__recursive_targets):
+	@fail=; \
+	if $(am__make_keepgoing); then \
+	  failcom='fail=yes'; \
+	else \
+	  failcom='exit 1'; \
+	fi; \
 	dot_seen=no; \
 	target=`echo $@ | sed s/-recursive//`; \
 	case "$@" in \
@@ -357,31 +419,13 @@ $(RECURSIVE_TARGETS) $(RECURSIVE_CLEAN_TARGETS):
 	if test "$$dot_seen" = "no"; then \
 	  $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
 	fi; test -z "$$fail"
-tags-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
-	done
-ctags-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
-	done
-cscopelist-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) cscopelist); \
-	done
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-recursive
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
@@ -397,12 +441,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
 	  fi; \
 	done; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -414,15 +453,11 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-recursive
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -431,9 +466,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-recursive
 
-cscopelist: cscopelist-recursive $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -605,24 +641,21 @@ ps-am:
 
 uninstall-am:
 
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) \
-	cscopelist-recursive ctags-recursive install-am install-strip \
-	tags-recursive
+.MAKE: $(am__recursive_targets) install-am install-strip
 
-.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
-	all all-am check check-am clean clean-generic clean-libtool \
-	cscopelist cscopelist-recursive ctags ctags-recursive \
-	distclean distclean-generic distclean-libtool distclean-tags \
-	distdir dvi dvi-am html html-am info info-am install \
-	install-am install-data install-data-am install-dvi \
+.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am check \
+	check-am clean clean-generic clean-libtool cscopelist-am ctags \
+	ctags-am distclean distclean-generic distclean-libtool \
+	distclean-tags distdir dvi dvi-am html html-am info info-am \
+	install install-am install-data install-data-am install-dvi \
 	install-dvi-am install-exec install-exec-am install-html \
 	install-html-am install-info install-info-am install-man \
 	install-pdf install-pdf-am install-ps install-ps-am \
 	install-strip installcheck installcheck-am installcheck-local \
 	installdirs installdirs-am maintainer-clean \
 	maintainer-clean-generic mostlyclean mostlyclean-generic \
-	mostlyclean-libtool pdf pdf-am ps ps-am tags tags-recursive \
-	uninstall uninstall-am
+	mostlyclean-libtool pdf pdf-am ps ps-am tags tags-am uninstall \
+	uninstall-am
 
 
 installcheck-local:
diff --git a/mfhdf/dumper/CMakeLists.txt b/mfhdf/dumper/CMakeLists.txt
index f4afcad..57448ac 100644
--- a/mfhdf/dumper/CMakeLists.txt
+++ b/mfhdf/dumper/CMakeLists.txt
@@ -4,9 +4,9 @@ PROJECT (HDF4_MFHDF_DUMPER)
 INCLUDE_DIRECTORIES (${HDF4_HDFSOURCE_DIR})
 INCLUDE_DIRECTORIES (${HDF4_MFHDFSOURCE_DIR})
 
-ADD_DEFINITIONS (-DHDF)
+add_definitions (-DHDF)
 
-SET (hdp_SRCS
+set (hdp_SRCS
     ${HDF4_MFHDF_DUMPER_SOURCE_DIR}/hdp.c
     ${HDF4_MFHDF_DUMPER_SOURCE_DIR}/hdp_dump.c
     ${HDF4_MFHDF_DUMPER_SOURCE_DIR}/hdp_gr.c
@@ -20,26 +20,26 @@ SET (hdp_SRCS
 )
   
 ADD_EXECUTABLE (hdp ${hdp_SRCS})
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS)
-ENDIF (WIN32 AND NOT CYGWIN)
-IF (HDF4_BUILD_XDR_LIB)
-  IF (WIN32 AND NOT CYGWIN)
-    ADD_DEFINITIONS (-DNO_SYS_XDR_INC)
-  ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  add_definitions (-DDOS_FS)
+endif (WIN32)
+if (HDF4_BUILD_XDR_LIB)
+  if (WIN32)
+    add_definitions (-DNO_SYS_XDR_INC)
+  endif (WIN32)
   INCLUDE_DIRECTORIES (${HDF4_MFHDF_XDR_DIR})
-  TARGET_LINK_LIBRARIES (hdp ${HDF4_MF_XDR_LIB_TARGET})
-ENDIF (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (hdp ${HDF4_MF_XDR_LIB_TARGET})
+endif (HDF4_BUILD_XDR_LIB)
 TARGET_C_PROPERTIES (hdp " " " ")
-TARGET_LINK_LIBRARIES (hdp ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+target_link_libraries (hdp ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
 TARGET_NAMING (hdp ${LIB_TYPE})
-IF (WIN32)
-  SET_TARGET_PROPERTIES (hdp PROPERTIES LINK_FLAGS "/STACK:10000000")
-ENDIF (WIN32)
+if (WIN32)
+  set_target_properties (hdp PROPERTIES LINK_FLAGS "/STACK:10000000")
+endif (WIN32)
 
-IF (BUILD_TESTING)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING)
+if (BUILD_TESTING)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING)
 
 ##############################################################################
 ##############################################################################
diff --git a/mfhdf/dumper/CMakeTests.cmake b/mfhdf/dumper/CMakeTests.cmake
index 71aa2ab..c4bb661 100644
--- a/mfhdf/dumper/CMakeTests.cmake
+++ b/mfhdf/dumper/CMakeTests.cmake
@@ -6,7 +6,7 @@
 ##############################################################################
   
   #-- Copy all the data files from the test directory into the source directory
-  SET (HDF4_REFERENCE_TEST_FILES
+  set (HDF4_REFERENCE_TEST_FILES
       ctxtr2r.hdf
       Example6.hdf
       grtdfi322.hdf
@@ -40,7 +40,7 @@
       Roy.nc
   )
   
-  SET (HDF4_REFERENCE_FILES
+  set (HDF4_REFERENCE_FILES
       dumpgr-1.out
       dumpgr-10.out
       dumpgr-11.out
@@ -129,27 +129,27 @@
       list-9.out
   )
  
-  FOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_MFHDF_DUMPER_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_REFERENCE_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_MFHDF_DUMPER_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
         TARGET     hdp 
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_MFHDF_DUMPER_SOURCE_DIR}/testfiles/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
+  endforeach (h4_file ${HDF4_REFERENCE_TEST_FILES})
 
-  FOREACH (out_file ${HDF4_REFERENCE_FILES})
-    SET (outdest "${PROJECT_BINARY_DIR}/${out_file}")
-    #MESSAGE (STATUS " Translating ${out_file}")
+  foreach (out_file ${HDF4_REFERENCE_FILES})
+    set (outdest "${PROJECT_BINARY_DIR}/${out_file}")
+    #message (STATUS " Translating ${out_file}")
     ADD_CUSTOM_COMMAND (
         TARGET     hdp
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_MFHDF_DUMPER_SOURCE_DIR}/testfiles/${out_file} ${outdest}
     )
-  ENDFOREACH (out_file ${HDF4_REFERENCE_FILES})
+  endforeach (out_file ${HDF4_REFERENCE_FILES})
   
 ##############################################################################
 ##############################################################################
@@ -159,21 +159,21 @@
 
   MACRO (ADD_H4_TEST resultfile resultcode)
     # Remove any output file left over from previous test run
-    ADD_TEST (
+    add_test (
         NAME HDP-${resultfile}-clearall-objects
         COMMAND ${CMAKE_COMMAND}
             -E remove ${resultfile}.tst ${resultfile}.tst.err
     )
-    IF (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HDP-${resultfile}-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-    ELSE (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HDP-${resultfile}-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
-    ENDIF (NOT "${last_test}" STREQUAL "")
-
-    IF (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (NAME HDP-${resultfile} COMMAND $<TARGET_FILE:hdp> ${ARGN})
-    ELSE (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (
+    if (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HDP-${resultfile}-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+    else (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HDP-${resultfile}-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
+    endif (NOT "${last_test}" STREQUAL "")
+
+    if (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (NAME HDP-${resultfile} COMMAND $<TARGET_FILE:hdp> ${ARGN})
+    else (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (
           NAME HDP-${resultfile}
           COMMAND "${CMAKE_COMMAND}"
               -D "TEST_PROGRAM=$<TARGET_FILE:hdp>"
@@ -182,11 +182,11 @@
               -D "TEST_OUTPUT=${resultfile}.tst"
               -D "TEST_EXPECT=${resultcode}"
               -D "TEST_REFERENCE=${resultfile}.out"
-              -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+              -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
       )
-    ENDIF (HDF4_ENABLE_USING_MEMCHECKER)
-    SET_TESTS_PROPERTIES (HDP-${resultfile} PROPERTIES DEPENDS HDP-${resultfile}-clearall-objects LABELS ${PROJECT_NAME})
-    SET (last_test "HDP-${resultfile}")
+    endif (HDF4_ENABLE_USING_MEMCHECKER)
+    set_tests_properties (HDP-${resultfile} PROPERTIES DEPENDS HDP-${resultfile}-clearall-objects LABELS ${PROJECT_NAME})
+    set (last_test "HDP-${resultfile}")
   ENDMACRO (ADD_H4_TEST file)
 
 ##############################################################################
@@ -250,11 +250,11 @@
   # Test 15 prints headers of all data sets with various compression method to
   # test displaying compression information
 
-  IF (HDF4_ENABLE_SZIP_SUPPORT)
+  if (HDF4_ENABLE_SZIP_SUPPORT)
     ADD_H4_TEST (dumpsds-15szip 0 dumpsds sds_compressed.hdf)
-  ELSE (HDF4_ENABLE_SZIP_SUPPORT)
+  else (HDF4_ENABLE_SZIP_SUPPORT)
     ADD_H4_TEST (dumpsds-15 0 dumpsds sds_compressed.hdf)
-  ENDIF (HDF4_ENABLE_SZIP_SUPPORT)
+  endif (HDF4_ENABLE_SZIP_SUPPORT)
 
   # Test 16 prints SDSs in index order, by default
   ADD_H4_TEST (dumpsds-16 0 dumpsds -h -i 39,36 -n data34,data27 -r 36,37 -i 0,1 -n data6,data9,data4,data3 -r 16,17,15 -i 23,22,21 sds_empty_many.hdf)
@@ -346,31 +346,31 @@
   ADD_H4_TEST (dumpgr-5 0 dumpgr -r 6,2,3 grtdfui82.hdf)
   ADD_H4_TEST (dumpgr-6 0 dumpgr -r 6 -d  grtdfui82.hdf)
   ADD_H4_TEST (dumpgr-7 0 dumpgr -o my.dat grtdfui82.hdf)
-  ADD_TEST (
+  add_test (
       NAME HDP-clear-my.dat
       COMMAND    ${CMAKE_COMMAND}
       -E remove 
       my.dat
   )
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (HDP-clear-my.dat PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (HDP-clear-my.dat PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "HDP-clear-my.dat")
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (HDP-clear-my.dat PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (HDP-clear-my.dat PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "HDP-clear-my.dat")
   ADD_H4_TEST (dumpgr-8 0 dumpgr -o mybin.dat  -b grtdfui82.hdf)
-  ADD_TEST (
+  add_test (
       NAME HDP-clear-mybin.dat
       COMMAND    ${CMAKE_COMMAND}
       -E remove 
       mybin.dat
   )
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (HDP-clear-mybin.dat PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (HDP-clear-mybin.dat PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "HDP-clear-mybin.dat")
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (HDP-clear-mybin.dat PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (HDP-clear-mybin.dat PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "HDP-clear-mybin.dat")
   ADD_H4_TEST (dumpgr-9 0 dumpgr grtdfui83.hdf)
   ADD_H4_TEST (dumpgr-10 0 dumpgr grtdfui84.hdf)
   ADD_H4_TEST (dumpgr-11 0 dumpgr grtdfui162.hdf)
diff --git a/mfhdf/dumper/Makefile.am b/mfhdf/dumper/Makefile.am
index b5e774d..9ea63d9 100644
--- a/mfhdf/dumper/Makefile.am
+++ b/mfhdf/dumper/Makefile.am
@@ -4,11 +4,11 @@
 
 include $(top_srcdir)/config/commence.am
 
-INCLUDES=-I$(top_srcdir)/hdf/src        \
+hdp_INCLUDES=-I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 DEFINES=-DNDEBUG -DHDF
-AM_CPPFLAGS=$(INCLUDES) $(DEFINES)
+AM_CPPFLAGS=$(hdp_INCLUDES) $(DEFINES)
 
 ## Add hdp specific linker flags here
 hdp_LDFLAGS = $(LT_STATIC_EXEC) $(AM_LDFLAGS)
diff --git a/mfhdf/dumper/Makefile.in b/mfhdf/dumper/Makefile.in
index dadb7f5..05f5018 100644
--- a/mfhdf/dumper/Makefile.in
+++ b/mfhdf/dumper/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -18,23 +18,51 @@
 #############################################################################
 
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -53,11 +81,11 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
 	$(srcdir)/testhdp.sh.in $(top_srcdir)/bin/depcomp \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am
+	$(top_srcdir)/bin/test-driver README
 bin_PROGRAMS = hdp$(EXEEXT)
 TESTS = $(TEST_SCRIPT)
 subdir = mfhdf/dumper
@@ -76,22 +104,47 @@ am_hdp_OBJECTS = hdp.$(OBJEXT) hdp_dump.$(OBJEXT) hdp_gr.$(OBJEXT) \
 	hdp_util.$(OBJEXT) hdp_vd.$(OBJEXT) hdp_vg.$(OBJEXT) \
 	show.$(OBJEXT)
 hdp_OBJECTS = $(am_hdp_OBJECTS)
-hdp_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdp_LDFLAGS) \
-	$(LDFLAGS) -o $@
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
+hdp_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdp_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 SOURCES = $(hdp_SOURCES)
 DIST_SOURCES = $(hdp_SOURCES)
 am__can_run_installinfo = \
@@ -99,15 +152,229 @@ am__can_run_installinfo = \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+  test -z "$$files" \
+    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+         $(am__cd) "$$dir" && rm -f $$files; }; \
+  }
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
+TEST_SUITE_LOG = test-suite.log
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -192,6 +459,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -272,12 +540,12 @@ ACLOCAL_AMFLAGS = "-I m4"
 # .chkexe files are used to mark tests that have run successfully.
 # .chklog files are output from those tests.
 CHECK_CLEANFILES = *.chkexe *.chklog
-INCLUDES = -I$(top_srcdir)/hdf/src        \
+hdp_INCLUDES = -I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 
 DEFINES = -DNDEBUG -DHDF
-AM_CPPFLAGS = $(INCLUDES) $(DEFINES)
+AM_CPPFLAGS = $(hdp_INCLUDES) $(DEFINES)
 hdp_LDFLAGS = $(LT_STATIC_EXEC) $(AM_LDFLAGS)
 hdp_SOURCES = hdp.c hdp_dump.c hdp_gr.c hdp_list.c hdp_rig.c hdp_sds.c      \
               hdp_util.c hdp_vd.c hdp_vg.c show.c
@@ -310,7 +578,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
-.SUFFIXES: .c .lo .o .obj
+.SUFFIXES: .c .lo .log .o .obj .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -353,10 +621,12 @@ install-binPROGRAMS: $(bin_PROGRAMS)
 	fi; \
 	for p in $$list; do echo "$$p $$p"; done | \
 	sed 's/$(EXEEXT)$$//' | \
-	while read p p1; do if test -f $$p || test -f $$p1; \
-	  then echo "$$p"; echo "$$p"; else :; fi; \
+	while read p p1; do if test -f $$p \
+	 || test -f $$p1 \
+	  ; then echo "$$p"; echo "$$p"; else :; fi; \
 	done | \
-	sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \
+	sed -e 'p;s,.*/,,;n;h' \
+	    -e 's|.*|.|' \
 	    -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
 	sed 'N;N;N;s,\n, ,g' | \
 	$(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
@@ -377,7 +647,8 @@ uninstall-binPROGRAMS:
 	@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
 	files=`for p in $$list; do echo "$$p"; done | \
 	  sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
-	      -e 's/$$/$(EXEEXT)/' `; \
+	      -e 's/$$/$(EXEEXT)/' \
+	`; \
 	test -n "$$list" || exit 0; \
 	echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
 	cd "$(DESTDIR)$(bindir)" && rm -f $$files
@@ -390,9 +661,10 @@ clean-binPROGRAMS:
 	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
 	echo " rm -f" $$list; \
 	rm -f $$list
+
 hdp$(EXEEXT): $(hdp_OBJECTS) $(hdp_DEPENDENCIES) $(EXTRA_hdp_DEPENDENCIES) 
 	@rm -f hdp$(EXEEXT)
-	$(hdp_LINK) $(hdp_OBJECTS) $(hdp_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdp_LINK) $(hdp_OBJECTS) $(hdp_LDADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -412,25 +684,25 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/show.Po at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -438,26 +710,15 @@ mostlyclean-libtool:
 clean-libtool:
 	-rm -rf .libs _libs
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -469,15 +730,11 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -486,9 +743,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -504,6 +762,151 @@ cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all $(check_SCRIPTS)
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -563,6 +966,9 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 
@@ -645,20 +1051,20 @@ uninstall-am: uninstall-binPROGRAMS
 
 .MAKE: check-am install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am all-local check check-TESTS check-am \
-	clean clean-binPROGRAMS clean-generic clean-libtool cscopelist \
-	ctags distclean distclean-compile distclean-generic \
-	distclean-libtool distclean-tags distdir dvi dvi-am html \
-	html-am info info-am install install-am install-binPROGRAMS \
-	install-data install-data-am install-dvi install-dvi-am \
-	install-exec install-exec-am install-html install-html-am \
-	install-info install-info-am install-man install-pdf \
-	install-pdf-am install-ps install-ps-am install-strip \
-	installcheck installcheck-am installdirs maintainer-clean \
-	maintainer-clean-generic mostlyclean mostlyclean-compile \
-	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
-	pdf-am ps ps-am tags uninstall uninstall-am \
-	uninstall-binPROGRAMS
+.PHONY: CTAGS GTAGS TAGS all all-am all-local check check-TESTS \
+	check-am clean clean-binPROGRAMS clean-generic clean-libtool \
+	cscopelist-am ctags ctags-am distclean distclean-compile \
+	distclean-generic distclean-libtool distclean-tags distdir dvi \
+	dvi-am html html-am info info-am install install-am \
+	install-binPROGRAMS install-data install-data-am install-dvi \
+	install-dvi-am install-exec install-exec-am install-html \
+	install-html-am install-info install-info-am install-man \
+	install-pdf install-pdf-am install-ps install-ps-am \
+	install-strip installcheck installcheck-am installdirs \
+	maintainer-clean maintainer-clean-generic mostlyclean \
+	mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
+	mostlyclean-local pdf pdf-am ps ps-am recheck tags tags-am \
+	uninstall uninstall-am uninstall-binPROGRAMS
 
 
 # lib/progs/tests targets recurse into subdirectories. build-* targets
diff --git a/mfhdf/dumper/hdp.c b/mfhdf/dumper/hdp.c
index 06740e0..0730754 100644
--- a/mfhdf/dumper/hdp.c
+++ b/mfhdf/dumper/hdp.c
@@ -12,10 +12,10 @@
  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
 
 #ifdef RCSID
-static char RcsId[] = "@(#)$Revision: 6013 $";
+static char RcsId[] = "@(#)$Revision: 6157 $";
 #endif
 
-/* $Id: hdp.c 6013 2014-01-10 21:19:02Z acheng $ */
+/* $Id: hdp.c 6157 2014-12-08 05:25:17Z bmribler $ */
 #define HDP_MASTER
 #define VSET_INTERFACE
 #include "hdp.h"
@@ -334,12 +334,20 @@ intn VSattrhdfsize(int32 vsid, int32 findex, intn attrindex, int32 *size)
         HGOTO_ERROR(DFE_CANTATTACH, FAIL);
     if (NULL == (attr_inst = (vsinstance_t *)HAatom_object(attr_vsid)))
         HGOTO_ERROR(DFE_NOVS, FAIL);
-    if (NULL == (attr_vs = attr_inst->vs) ||
-          HDstrcmp(attr_vs->vsclass,  _HDF_ATTRIBUTE) != 0)
+    if (NULL == (attr_vs = attr_inst->vs))
         HGOTO_ERROR(DFE_BADATTR, FAIL);
+
+    /* If this vdata is not storing an attribute, it shouldn't have been passed
+       to this function */
+    if (HDstrcmp(attr_vs->vsclass, _HDF_ATTRIBUTE) != 0)
+        HGOTO_ERROR(DFE_BADATTR, FAIL);
+
     w = &(attr_vs->wlist);
-    /* this vdata has 1 field */
-    if (w->n != 1 || HDstrcmp(w->name[0], ATTR_FIELD_NAME))
+    /* This vdata should have only 1 field */
+     /* if (w->n != 1 || HDstrcmp(w->name[0], ATTR_FIELD_NAME)) <- commented out
+	Note: ATTR_FIELD_NAME cannot be used here because hdfeos sets fieldname
+	to "AttrValues", not ATTR_FIELD_NAME. -BMR, 2014/12/01 */ 
+    if (w->n != 1)
         HGOTO_ERROR(DFE_BADATTR, FAIL);
     if (size)
         *size = w->order[0] * (DFKNTsize(w->type[0]));
@@ -352,7 +360,6 @@ done:
     } /* end if */
 
   /* Normal function cleanup */
-
   return ret_value;
 }  /* VSattrhdfsize */
 
@@ -431,14 +438,20 @@ intn Vattrhdfsize(int32 vgid, intn attrindex, int32 *size)
         HGOTO_ERROR(DFE_ARGS, FAIL);
     if (NULL == (vs_inst = (vsinstance_t *)HAatom_object(vsid)))
         HGOTO_ERROR(DFE_NOVS, FAIL);
-    if (NULL == (vs = vs_inst->vs) ||
-          HDstrcmp(vs->vsclass,  _HDF_ATTRIBUTE) != 0)
+    if (NULL == (vs = vs_inst->vs))
+        HGOTO_ERROR(DFE_BADATTR, FAIL);
+
+    /* If this vdata is not storing an attribute, it shouldn't have been passed
+       to this function */
+    if (HDstrcmp(vs->vsclass, _HDF_ATTRIBUTE) != 0)
         HGOTO_ERROR(DFE_BADATTR, FAIL);
 
     w = &(vs->wlist);
-    /* this vdata has 1 field */
-    if (w->n != 1 || HDstrcmp(w->name[0], ATTR_FIELD_NAME))  
-/*    if (w->n != 1 )   */
+    /* This vdata should have only 1 field */
+     /* if (w->n != 1 || HDstrcmp(w->name[0], ATTR_FIELD_NAME)) <- commented out
+	Note: ATTR_FIELD_NAME cannot be used here because hdfeos sets fieldname
+	to "AttrValues", not ATTR_FIELD_NAME. -BMR, 2014/12/01 */ 
+    if (w->n != 1 )
         HGOTO_ERROR(DFE_BADATTR, FAIL);
     if (size)
        *size = w->order[0] * (DFKNTsize(w->type[0]));
diff --git a/mfhdf/dumper/hdp_util.c b/mfhdf/dumper/hdp_util.c
index 0f56489..37641f5 100644
--- a/mfhdf/dumper/hdp_util.c
+++ b/mfhdf/dumper/hdp_util.c
@@ -118,10 +118,8 @@ vg_info_t* free_node_vg_info_t(
          HDfree(aNode->vg_name);
 	 aNode->vg_name = NULL;
       }
-      HDfree(aNode);
-      aNode = NULL;
    }
-   return(NULL);
+   return(aNode);
 }  /* end of free_node_vg_info_t */
 
 /* free_struct_list use HDfree to free the list of vgroup info structs */
@@ -136,7 +134,11 @@ vg_info_t ** free_vginfo_list(
    {
       for (i = 0; i < num_items; i++)
          if (nodelist[i] != NULL)
+	 {
             nodelist[i] = free_node_vg_info_t(nodelist[i]);
+	    HDfree(nodelist[i]);
+	    nodelist[i] = NULL;
+	 }
       HDfree(nodelist);
    }
    return( NULL );
@@ -160,7 +162,7 @@ obj_chosen_t ** free_node_obj_chosen_t(
       HDfree(aNode);
    }
    return(NULL);
-}  /* end of free_vginfo_list */
+}  /* end of free_node_obj_chosen_t */
 
 /* free_struct_list use HDfree to free the list of vgroup info structs */
 void free_obj_chosen_t_list( 
@@ -186,7 +188,7 @@ void free_obj_chosen_t_list(
       HDfree((*nodelist));
       (*nodelist) = NULL;
    }
-}  /* end of free_vginfo_list */
+}  /* end of free_obj_chosen_t_list */
 
 /* free_str_list use HDfree to free the list of strings of characters */
 char** free_str_list( char **str_list,
diff --git a/mfhdf/dumper/hdp_vg.c b/mfhdf/dumper/hdp_vg.c
index 7f237d2..7067b45 100644
--- a/mfhdf/dumper/hdp_vg.c
+++ b/mfhdf/dumper/hdp_vg.c
@@ -12,10 +12,10 @@
  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
 
 #ifdef RCSID
-static char RcsId[] = "@(#)$Revision: 6043 $";
+static char RcsId[] = "@(#)$Revision: 6157 $";
 #endif
 
-/* $Id: hdp_vg.c 6043 2014-01-21 21:09:03Z acheng $ */
+/* $Id: hdp_vg.c 6157 2014-12-08 05:25:17Z bmribler $ */
 
 #include "hdp.h"
 #ifndef MIPSEL
@@ -1047,11 +1047,11 @@ if (num_entries != 0)
 done:
     if (ret_value == FAIL)
       { /* Failure cleanup */
-	aNode = free_node_vg_info_t(aNode);
       }
     /* Normal cleanup */
     SAFE_FREE(vgname);	/* free vg name and set it to NULL */
     SAFE_FREE(vgclass);	/* free vg class name and set it to NULL */
+
     return ret_value;
 }	/* vgBuildGraph */
 
@@ -1086,16 +1086,16 @@ intn vgdumpfull(int32        vg_id,
    aNode->n_entries = num_entries;
 if (num_entries != 0)
 {
-   /* allocate and init memory for storing children's and type's info */
-   aNode->children = alloc_list_of_strings( num_entries );
-   aNode->type = alloc_list_of_strings( num_entries );
-
    /* get the current vgroup's ref# for error message */
    vg_ref = VQueryref( vg_id );
    if( vg_ref == FAIL )
       ERROR_GOTO_2( "in %s: VQueryref failed for vgroup with id=%d",
 		"vgdumpfull", (int) vg_id );
 
+   /* allocate and init memory for storing children's and type's info */
+   aNode->children = alloc_list_of_strings( num_entries );
+   aNode->type = alloc_list_of_strings( num_entries );
+
    for (entry_num = 0; entry_num < num_entries; entry_num++)
    {
       status = Vgettagref(vg_id, entry_num, &elem_tag, &elem_ref);
@@ -1155,13 +1155,13 @@ if (num_entries != 0)
          /* dump attributes for vgroup */
          status = dumpattr(vgt, 0, 0, dumpvg_opts->file_format, fp);
          if( FAIL == status )
-            ERROR_CONT_3( "in %s: %s failed to dump attributes for vgroup with ref#=%d",
+            ERROR_NOTIFY_3( "in %s: %s failed to dump attributes for vgroup with ref#=%d",
 		"vgdumpfull", "dumpattr", (int) elem_ref );
 
          /* dump all of the annotations for this vgroup */
          status = print_data_annots( file_id, file_name, elem_tag, elem_ref );
          if( FAIL == status )
-            ERROR_CONT_3( "in %s: %s failed to dump annotations for vgroup with ref#=%d",
+            ERROR_NOTIFY_3( "in %s: %s failed to dump annotations for vgroup with ref#=%d",
 		"vgdumpfull", "print_data_annots", (int) elem_ref );
 
          resetVG( &vgt, file_name );
@@ -1172,18 +1172,18 @@ if (num_entries != 0)
 
          vs = VSattach(file_id, elem_ref, "r");
          if (vs == FAIL)
-            ERROR_CONT_2( "in %s: VSattach failed for vdata with ref#=%d", 
+            ERROR_NOTIFY_2( "in %s: VSattach failed for vdata with ref#=%d", 
                                  "vgdumpfull", (int) elem_ref );
 
          /* get and print vdata's information */
          status = VSinquire(vs, &nv, &interlace, fields, &vsize, vsname);
          if( FAIL == status )
-            ERROR_CONT_2( "in %s: VSinquire failed for vdata with ref#=%d", 
+            ERROR_NOTIFY_2( "in %s: VSinquire failed for vdata with ref#=%d", 
                                  "vgdumpfull", (int) elem_ref );
    
          vsize = VShdfsize(vs, fields);
          if (vsize == FAIL)
-            ERROR_CONT_2( "in %s: VShdfsize failed for vdata with ref#=%d", 
+            ERROR_NOTIFY_2( "in %s: VShdfsize failed for vdata with ref#=%d", 
                                  "vgdumpfull", (int) elem_ref );
 
 	 /* vdata has no name */
@@ -1191,7 +1191,7 @@ if (num_entries != 0)
                HDstrcat(vsname, "<Undefined>");
    
          if (FAIL == VSgetclass(vs, vsclass))
-               ERROR_CONT_2( "in %s: VSgetclass failed for vdata with ref#=%d", 
+               ERROR_NOTIFY_2( "in %s: VSgetclass failed for vdata with ref#=%d", 
                                  "vgdumpfull", (int) elem_ref );
 
          /* vdata has no class */
@@ -1218,7 +1218,7 @@ if (num_entries != 0)
 				VSnattrs(vs));
 
          if (FAIL == VSdetach(vs))
-               ERROR_CONT_2( "in %s: VSdetach failed for vdata with ref#=%d", 
+               ERROR_NOTIFY_2( "in %s: VSdetach failed for vdata with ref#=%d", 
                                  "vgdumpfull", (int) elem_ref );
 
          /* vdata has no name */
@@ -1257,7 +1257,6 @@ if (num_entries != 0)
 done:
     if (ret_value == FAIL)
       { /* Failure cleanup */
-	  aNode = free_node_vg_info_t(aNode);
       }
     /* Normal cleanup */
     SAFE_FREE(vgname);	/* free vg name and set it to NULL */
@@ -1499,6 +1498,9 @@ intn dvg(dump_info_t *dumpvg_opts,
                                   fp, list[curr_vg], &skipfile );
             if( FAIL == status )
             {
+	  /*       HDfree(list[curr_vg]);
+	       list[curr_vg] = NULL;
+ */ 
                ERROR_NOTIFY_3( "in dvg: %s failed for vgroup with ref#=%d in file %s", 
 			      "vgdumpfull", (int) vg_ref, file_name);
 
diff --git a/mfhdf/dumper/testhdp.sh.in b/mfhdf/dumper/testhdp.sh.in
old mode 100755
new mode 100644
index 67f8b5c..5e188ff
--- a/mfhdf/dumper/testhdp.sh.in
+++ b/mfhdf/dumper/testhdp.sh.in
@@ -1,5 +1,5 @@
 #! /bin/sh
-# $Id: testhdp.sh.in 6027 2014-01-16 19:28:25Z byrn $
+# $Id: testhdp.sh.in 6104 2014-04-25 19:39:26Z derobins $
 # Test scripts for hdp (dumper).
 # See the USAGE function for command usage.
 
diff --git a/mfhdf/examples/CMakeLists.txt b/mfhdf/examples/CMakeLists.txt
index df1c5f4..53184c1 100644
--- a/mfhdf/examples/CMakeLists.txt
+++ b/mfhdf/examples/CMakeLists.txt
@@ -4,7 +4,7 @@ PROJECT (HDF4_MFHDF_EXAMPLES)
 #-----------------------------------------------------------------------------
 # Define Sources
 #-----------------------------------------------------------------------------
-SET (examples
+set (examples
     SD_create_sds
     SD_write_to_sds
     SD_write_slab
@@ -23,17 +23,17 @@ SET (examples
     SD_chunking_example
 )
 
-FOREACH (example ${examples})
+foreach (example ${examples})
   ADD_EXECUTABLE (mf_${example} ${HDF4_MFHDF_EXAMPLES_SOURCE_DIR}/${example}.c)
   TARGET_NAMING (mf_${example} ${LIB_TYPE})
   TARGET_C_PROPERTIES (mf_${example} " " " ")
-  IF (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (mf_${example} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-  ELSE (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (mf_${example} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-  ENDIF (HDF4_BUILD_XDR_LIB)
-ENDFOREACH (example ${examples})
+  if (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (mf_${example} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+  else (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (mf_${example} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  endif (HDF4_BUILD_XDR_LIB)
+endforeach (example ${examples})
 
-IF (BUILD_TESTING)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING)
+if (BUILD_TESTING)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING)
diff --git a/mfhdf/examples/CMakeTests.cmake b/mfhdf/examples/CMakeTests.cmake
index 8a30920..0fe2ac4 100644
--- a/mfhdf/examples/CMakeTests.cmake
+++ b/mfhdf/examples/CMakeTests.cmake
@@ -6,7 +6,7 @@
 ##############################################################################
 
 # Remove any output file left over from previous test run
-ADD_TEST (
+add_test (
     NAME MFHDF_EXAMPLES-clearall-objects
     COMMAND    ${CMAKE_COMMAND}
         -E remove 
@@ -17,15 +17,15 @@ ADD_TEST (
         SLABS.hdf
         ExternalSDS
 )
-SET_TESTS_PROPERTIES (MFHDF_EXAMPLES-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
-SET (last_test "MFHDF_EXAMPLES-clearall-objects")
+set_tests_properties (MFHDF_EXAMPLES-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
+set (last_test "MFHDF_EXAMPLES-clearall-objects")
 
-FOREACH (example ${examples})
-  ADD_TEST (NAME mftest_${example} COMMAND $<TARGET_FILE:mf_${example}>)
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (mftest_${example} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (mftest_${example} PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "mftest_${example}")
-ENDFOREACH (example ${examples})
+foreach (example ${examples})
+  add_test (NAME mftest_${example} COMMAND $<TARGET_FILE:mf_${example}>)
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (mftest_${example} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (mftest_${example} PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "mftest_${example}")
+endforeach (example ${examples})
diff --git a/mfhdf/examples/Makefile.in b/mfhdf/examples/Makefile.in
index e331b60..2b0fe44 100644
--- a/mfhdf/examples/Makefile.in
+++ b/mfhdf/examples/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -21,23 +21,51 @@
 # built using h4cc (or h4fc, etc.) instead of the standard compilers.
 # This creates some extra work for us.
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -56,11 +84,11 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
-	$(srcdir)/testexamples.sh.in $(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am \
-	$(top_srcdir)/config/examples.am
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/examples.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
+	$(srcdir)/testexamples.sh.in $(top_srcdir)/bin/test-driver
 TESTS = $(TEST_PROG)
 subdir = mfhdf/examples
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -71,6 +99,18 @@ mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs
 CONFIG_HEADER = $(top_builddir)/hdf/src/h4config.h
 CONFIG_CLEAN_FILES = testexamples.sh
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 SOURCES =
 DIST_SOURCES =
 am__can_run_installinfo = \
@@ -78,13 +118,213 @@ am__can_run_installinfo = \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+  test -z "$$files" \
+    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+         $(am__cd) "$$dir" && rm -f $$files; }; \
+  }
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
+TEST_SUITE_LOG = test-suite.log
+LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -169,6 +409,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -298,6 +539,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
+.SUFFIXES: .log .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/examples.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -337,15 +579,270 @@ mostlyclean-libtool:
 
 clean-libtool:
 	-rm -rf .libs _libs
-tags: TAGS
-TAGS:
+tags TAGS:
 
-ctags: CTAGS
-CTAGS:
+ctags CTAGS:
 
 cscope cscopelist:
 
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all 
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+SD_create_sds.log: SD_create_sds
+	@p='SD_create_sds'; \
+	b='SD_create_sds'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_write_to_sds.log: SD_write_to_sds
+	@p='SD_write_to_sds'; \
+	b='SD_write_to_sds'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_write_slab.log: SD_write_slab
+	@p='SD_write_slab'; \
+	b='SD_write_slab'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_alter_sds_values.log: SD_alter_sds_values
+	@p='SD_alter_sds_values'; \
+	b='SD_alter_sds_values'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_unlimited_sds.log: SD_unlimited_sds
+	@p='SD_unlimited_sds'; \
+	b='SD_unlimited_sds'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_compress_sds.log: SD_compress_sds
+	@p='SD_compress_sds'; \
+	b='SD_compress_sds'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_mv_sds_to_external.log: SD_mv_sds_to_external
+	@p='SD_mv_sds_to_external'; \
+	b='SD_mv_sds_to_external'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_read_from_sds.log: SD_read_from_sds
+	@p='SD_read_from_sds'; \
+	b='SD_read_from_sds'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_read_subsets.log: SD_read_subsets
+	@p='SD_read_subsets'; \
+	b='SD_read_subsets'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_get_info.log: SD_get_info
+	@p='SD_get_info'; \
+	b='SD_get_info'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_find_sds_by_name.log: SD_find_sds_by_name
+	@p='SD_find_sds_by_name'; \
+	b='SD_find_sds_by_name'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_set_get_dim_info.log: SD_set_get_dim_info
+	@p='SD_set_get_dim_info'; \
+	b='SD_set_get_dim_info'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_dimscale_vs_sds.log: SD_dimscale_vs_sds
+	@p='SD_dimscale_vs_sds'; \
+	b='SD_dimscale_vs_sds'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_set_attr.log: SD_set_attr
+	@p='SD_set_attr'; \
+	b='SD_set_attr'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_get_attr.log: SD_get_attr
+	@p='SD_get_attr'; \
+	b='SD_get_attr'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_chunking_example.log: SD_chunking_example
+	@p='SD_chunking_example'; \
+	b='SD_chunking_example'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -402,6 +899,9 @@ install-strip:
 	fi
 mostlyclean-generic:
 	-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 	-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
@@ -484,17 +984,18 @@ uninstall-am: uninstall-local
 .MAKE: check-am install-am install-strip
 
 .PHONY: all all-am all-local check check-TESTS check-am clean \
-	clean-generic clean-libtool distclean distclean-generic \
-	distclean-libtool distdir dvi dvi-am html html-am info info-am \
-	install install-am install-data install-data-am \
-	install-data-local install-dvi install-dvi-am install-exec \
-	install-exec-am install-html install-html-am install-info \
-	install-info-am install-man install-pdf install-pdf-am \
-	install-ps install-ps-am install-strip installcheck \
-	installcheck-am installcheck-local installdirs \
+	clean-generic clean-libtool cscopelist-am ctags-am distclean \
+	distclean-generic distclean-libtool distdir dvi dvi-am html \
+	html-am info info-am install install-am install-data \
+	install-data-am install-data-local install-dvi install-dvi-am \
+	install-exec install-exec-am install-html install-html-am \
+	install-info install-info-am install-man install-pdf \
+	install-pdf-am install-ps install-ps-am install-strip \
+	installcheck installcheck-am installcheck-local installdirs \
 	maintainer-clean maintainer-clean-generic mostlyclean \
 	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
-	pdf-am ps ps-am uninstall uninstall-am uninstall-local
+	pdf-am ps ps-am recheck tags-am uninstall uninstall-am \
+	uninstall-local
 
 
 # How to build programs using h4cc
diff --git a/mfhdf/examples/testexamples.sh.in b/mfhdf/examples/testexamples.sh.in
old mode 100755
new mode 100644
diff --git a/mfhdf/fortran/CMakeLists.txt b/mfhdf/fortran/CMakeLists.txt
index bddfe01..39e6d2c 100644
--- a/mfhdf/fortran/CMakeLists.txt
+++ b/mfhdf/fortran/CMakeLists.txt
@@ -10,82 +10,88 @@ INCLUDE_DIRECTORIES (
     ${HDF4_HDF_TESTSOURCE_DIR}
 )
 
-ADD_DEFINITIONS (-DHDF)
+if (CYGWIN)
+  INCLUDE_DIRECTORIES (/usr/include/tirpc)
+else (CYGWIN)
+  INCLUDE_DIRECTORIES (/usr/include/rpc)
+endif (CYGWIN)
 
-IF (HDF4_ENABLE_NETCDF)
-  CONFIGURE_FILE (${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/ftest.f.in ${HDF4_BINARY_DIR}/ftest.f)
-  CONFIGURE_FILE (${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/jackets.c.in ${HDF4_BINARY_DIR}/jackets.c)
-ENDIF (HDF4_ENABLE_NETCDF)
-CONFIGURE_FILE (${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/netcdf.inc.in ${HDF4_BINARY_DIR}/netcdf.inc)
-SET (HDF4_MFHDF_FORTRAN_XFHDRS ${HDF4_BINARY_DIR}/netcdf.inc ${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/mffunc.inc)
+add_definitions (-DHDF)
 
-IF (HDF4_ENABLE_NETCDF)
-  SET (HDF4_MFHDF_LIBSRC_CSTUB_FSRCS ${HDF4_BINARY_DIR}/jackets.c ${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/mfsdf.c)
-ELSE (HDF4_ENABLE_NETCDF)
-  SET (HDF4_MFHDF_LIBSRC_CSTUB_FSRCS ${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/mfsdf.c)
-ENDIF (HDF4_ENABLE_NETCDF)
+if (HDF4_ENABLE_NETCDF)
+  configure_file (${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/ftest.f.in ${HDF4_BINARY_DIR}/ftest.f)
+  configure_file (${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/jackets.c.in ${HDF4_BINARY_DIR}/jackets.c)
+endif (HDF4_ENABLE_NETCDF)
+configure_file (${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/netcdf.inc.in ${HDF4_BINARY_DIR}/netcdf.inc)
+set (HDF4_MFHDF_FORTRAN_XFHDRS ${HDF4_BINARY_DIR}/netcdf.inc ${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/mffunc.inc)
 
-SET (HDF4_MFHDF_LIBSRC_CSTUB_FHDRS 
+if (HDF4_ENABLE_NETCDF)
+  set (HDF4_MFHDF_LIBSRC_CSTUB_FSRCS ${HDF4_BINARY_DIR}/jackets.c ${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/mfsdf.c)
+else (HDF4_ENABLE_NETCDF)
+  set (HDF4_MFHDF_LIBSRC_CSTUB_FSRCS ${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/mfsdf.c)
+endif (HDF4_ENABLE_NETCDF)
+
+set (HDF4_MFHDF_LIBSRC_CSTUB_FHDRS 
     ${HDF4_MFHDFSOURCE_DIR}/hdf2netcdf.h 
     ${HDF4_MFHDFSOURCE_DIR}/mfhdf.h 
     ${HDF4_MFHDFSOURCE_DIR}/mfhdfi.h
 )
-IF (HDF4_ENABLE_NETCDF)
-#  SET (HDF4_MFHDF_LIBSRC_CSTUB_FSRCS ${HDF4_MFHDF_LIBSRC_CSTUB_FSRCS} ${HDF4_BINARY_DIR}/jackets.c)
-  SET (HDF4_MFHDF_LIBSRC_CSTUB_FHDRS ${HDF4_MFHDF_LIBSRC_CSTUB_FHDRS} ${HDF4_BINARY_DIR}/netcdf.h)
-ELSE (HDF4_ENABLE_NETCDF)
-  SET (HDF4_MFHDF_LIBSRC_CSTUB_FHDRS ${HDF4_MFHDF_LIBSRC_CSTUB_FHDRS} ${HDF4_BINARY_DIR}/hdf4_netcdf.h)
-ENDIF (HDF4_ENABLE_NETCDF)
+if (HDF4_ENABLE_NETCDF)
+#  set (HDF4_MFHDF_LIBSRC_CSTUB_FSRCS ${HDF4_MFHDF_LIBSRC_CSTUB_FSRCS} ${HDF4_BINARY_DIR}/jackets.c)
+  set (HDF4_MFHDF_LIBSRC_CSTUB_FHDRS ${HDF4_MFHDF_LIBSRC_CSTUB_FHDRS} ${HDF4_BINARY_DIR}/netcdf.h)
+else (HDF4_ENABLE_NETCDF)
+  set (HDF4_MFHDF_LIBSRC_CSTUB_FHDRS ${HDF4_MFHDF_LIBSRC_CSTUB_FHDRS} ${HDF4_BINARY_DIR}/hdf4_netcdf.h)
+endif (HDF4_ENABLE_NETCDF)
 
-SET (FORTRAN_SRC_DIR ${CMAKE_CURRENT_SOURCE_DIR})
+set (FORTRAN_SRC_DIR ${CMAKE_CURRENT_SOURCE_DIR})
 
 #-----------------------------------------------------------------------------
 # Add Main fortran library
 #-----------------------------------------------------------------------------
-ADD_LIBRARY (${HDF4_MF_FCSTUB_LIB_TARGET} ${LIB_TYPE} ${HDF4_MFHDF_LIBSRC_CSTUB_FSRCS} ${HDF4_MFHDF_LIBSRC_CSTUB_FHDRS} ${HDF4_HDF_SRC_CHDRS} ${HDF4_HDFSOURCE_DIR}/hproto_fortran.h)
-SET_TARGET_PROPERTIES (${HDF4_MF_FCSTUB_LIB_TARGET} PROPERTIES LINKER_LANGUAGE C)
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS)
-ENDIF (WIN32 AND NOT CYGWIN)
-IF (HDF4_BUILD_XDR_LIB)
-  IF (WIN32 AND NOT CYGWIN)
-    ADD_DEFINITIONS (-DNO_SYS_XDR_INC)
-  ENDIF (WIN32 AND NOT CYGWIN)
+add_library (${HDF4_MF_FCSTUB_LIB_TARGET} ${LIB_TYPE} ${HDF4_MFHDF_LIBSRC_CSTUB_FSRCS} ${HDF4_MFHDF_LIBSRC_CSTUB_FHDRS} ${HDF4_HDF_SRC_CHDRS} ${HDF4_HDFSOURCE_DIR}/hproto_fortran.h)
+set_target_properties (${HDF4_MF_FCSTUB_LIB_TARGET} PROPERTIES LINKER_LANGUAGE C)
+if (WIN32)
+  add_definitions (-DDOS_FS)
+endif (WIN32)
+if (HDF4_BUILD_XDR_LIB)
+  if (WIN32)
+    add_definitions (-DNO_SYS_XDR_INC)
+  endif (WIN32)
   INCLUDE_DIRECTORIES (${HDF4_MFHDF_XDR_DIR})
-  TARGET_LINK_LIBRARIES (${HDF4_MF_FCSTUB_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET})
-ENDIF (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (${HDF4_MF_FCSTUB_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET})
+endif (HDF4_BUILD_XDR_LIB)
 TARGET_C_PROPERTIES (${HDF4_MF_FCSTUB_LIB_TARGET} " " " ")
-TARGET_LINK_LIBRARIES (${HDF4_MF_FCSTUB_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET})
-SET_GLOBAL_VARIABLE (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_MF_FCSTUB_LIB_TARGET}")
+target_link_libraries (${HDF4_MF_FCSTUB_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET})
+set_global_variable (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_MF_FCSTUB_LIB_TARGET}")
 H4_SET_LIB_OPTIONS (${HDF4_MF_FCSTUB_LIB_TARGET} ${HDF4_MF_FCSTUB_LIB_NAME} ${LIB_TYPE})
 
-SET (HDF4_MF_FORTRAN_SRCS 
+set (HDF4_MF_FORTRAN_SRCS 
     ${HDF4_MFHDF_FORTRAN_DIR}/mfsdff.f
 )
 #-----------------------------------------------------------------------------
-ADD_LIBRARY (${HDF4_MF_FORTRAN_LIB_TARGET} ${LIB_TYPE} ${HDF4_MF_FORTRAN_SRCS})
-SET (SHARED_LINK_FLAGS " ")
-IF (WIN32)
-  IF (${LIB_TYPE} MATCHES "SHARED")
-    IF (MSVC)
-      SET (SHARED_LINK_FLAGS "/DLL /DEF:${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/mfhdf_fortrandll.def")
-    ENDIF (MSVC)
-  ENDIF (${LIB_TYPE} MATCHES "SHARED")
-ENDIF (WIN32)
+add_library (${HDF4_MF_FORTRAN_LIB_TARGET} ${LIB_TYPE} ${HDF4_MF_FORTRAN_SRCS})
+set (SHARED_LINK_FLAGS " ")
+if (WIN32)
+  if (${LIB_TYPE} MATCHES "SHARED")
+    if (MSVC)
+      set (SHARED_LINK_FLAGS "/DLL /DEF:${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/mfhdf_fortrandll.def")
+    endif (MSVC)
+  endif (${LIB_TYPE} MATCHES "SHARED")
+endif (WIN32)
 TARGET_FORTRAN_PROPERTIES (${HDF4_MF_FORTRAN_LIB_TARGET} " " ${SHARED_LINK_FLAGS})
-SET_TARGET_PROPERTIES (${HDF4_MF_FORTRAN_LIB_TARGET} PROPERTIES LINKER_LANGUAGE Fortran)
-TARGET_LINK_LIBRARIES (${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_MF_FCSTUB_LIB_TARGET} ${LINK_LIBS})
-SET_GLOBAL_VARIABLE (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_MF_FORTRAN_LIB_TARGET}")
+set_target_properties (${HDF4_MF_FORTRAN_LIB_TARGET} PROPERTIES LINKER_LANGUAGE Fortran)
+target_link_libraries (${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_MF_FCSTUB_LIB_TARGET} ${LINK_LIBS})
+set_global_variable (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_MF_FORTRAN_LIB_TARGET}")
 H4_SET_LIB_OPTIONS (${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_MF_FORTRAN_LIB_NAME} ${LIB_TYPE})
 
-IF (BUILD_TESTING)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING)
+if (BUILD_TESTING)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING)
 
 #-----------------------------------------------------------------------------
 # Add file(s) to CMake Install
 #-----------------------------------------------------------------------------
-INSTALL (
+install (
     FILES
         ${HDF4_MFHDF_FORTRAN_XFHDRS}
     DESTINATION
@@ -97,12 +103,12 @@ INSTALL (
 #-----------------------------------------------------------------------------
 # Add library to CMake Install : Installs lib and cmake config info
 #-----------------------------------------------------------------------------
-IF (BUILD_SHARED_LIBS)
+if (BUILD_SHARED_LIBS)
   INSTALL_TARGET_PDB (${HDF4_MF_FCSTUB_LIB_TARGET} ${HDF4_INSTALL_LIB_DIR} fortlibraries)
   INSTALL_TARGET_PDB (${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_INSTALL_LIB_DIR} fortlibraries)
-ENDIF (BUILD_SHARED_LIBS)
+endif (BUILD_SHARED_LIBS)
   
-INSTALL (
+install (
     TARGETS 
         ${HDF4_MF_FCSTUB_LIB_TARGET}
         ${HDF4_MF_FORTRAN_LIB_TARGET}
diff --git a/mfhdf/fortran/CMakeTests.cmake b/mfhdf/fortran/CMakeTests.cmake
index c060833..a0b6615 100644
--- a/mfhdf/fortran/CMakeTests.cmake
+++ b/mfhdf/fortran/CMakeTests.cmake
@@ -10,69 +10,69 @@
   #-----------------------------------------------------------------------------
   # test programs
   #-----------------------------------------------------------------------------
-  IF (HDF4_ENABLE_NETCDF)
+  if (HDF4_ENABLE_NETCDF)
     #-- Adding test for ftest
     ADD_EXECUTABLE (ftest ${HDF4_BINARY_DIR}/ftest.f ${HDF4_HDF_TESTSOURCE_DIR}/forsupff.f ${HDF4_BINARY_DIR}/netcdf.inc)
     TARGET_NAMING (ftest ${LIB_TYPE})
     TARGET_FORTRAN_PROPERTIES (ftest " " " ")
-    SET_TARGET_PROPERTIES (ftest PROPERTIES LINKER_LANGUAGE Fortran)
-    IF (HDF4_BUILD_XDR_LIB)
-      TARGET_LINK_LIBRARIES (ftest ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET} ${LINK_LIBS})
-    ELSE (HDF4_BUILD_XDR_LIB)
-      TARGET_LINK_LIBRARIES (ftest ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-    ENDIF (HDF4_BUILD_XDR_LIB)
+    set_target_properties (ftest PROPERTIES LINKER_LANGUAGE Fortran)
+    if (HDF4_BUILD_XDR_LIB)
+      target_link_libraries (ftest ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET} ${LINK_LIBS})
+    else (HDF4_BUILD_XDR_LIB)
+      target_link_libraries (ftest ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_HDF_TEST_FCSTUB_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+    endif (HDF4_BUILD_XDR_LIB)
 
     #-- Copy all the dat files from the test directory into the source directory
-    SET (HDF4_REFERENCE_TEST_FILES
+    set (HDF4_REFERENCE_TEST_FILES
       test_nc.cdl
       test_nc.nc
     )
-    FOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
-      SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-      #MESSAGE (STATUS " Copying ${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/${h4_file} to ${PROJECT_BINARY_DIR}/")
+    foreach (h4_file ${HDF4_REFERENCE_TEST_FILES})
+      set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+      #message (STATUS " Copying ${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/${h4_file} to ${PROJECT_BINARY_DIR}/")
       ADD_CUSTOM_COMMAND (
           TARGET     ftest 
           POST_BUILD
           COMMAND    ${CMAKE_COMMAND}
           ARGS       -E copy_if_different ${HDF4_MFHDF_FORTRAN_SOURCE_DIR}/${h4_file} ${dest}
       )
-    ENDFOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
+    endforeach (h4_file ${HDF4_REFERENCE_TEST_FILES})
 
-    ADD_TEST (NAME ftest COMMAND $<TARGET_FILE:ftest>)
-  ENDIF (HDF4_ENABLE_NETCDF)
+    add_test (NAME ftest COMMAND $<TARGET_FILE:ftest>)
+  endif (HDF4_ENABLE_NETCDF)
 
   #-- Adding test for f_hdftest
   ADD_EXECUTABLE (f_hdftest hdftest.f)
   TARGET_NAMING (f_hdftest ${LIB_TYPE})
   TARGET_FORTRAN_PROPERTIES (f_hdftest " " " ")
-  SET_TARGET_PROPERTIES (f_hdftest PROPERTIES LINKER_LANGUAGE Fortran)
-  IF (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (f_hdftest ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET} ${LINK_LIBS})
-  ELSE (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (f_hdftest ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-  ENDIF (HDF4_BUILD_XDR_LIB)
+  set_target_properties (f_hdftest PROPERTIES LINKER_LANGUAGE Fortran)
+  if (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (f_hdftest ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET} ${LINK_LIBS})
+  else (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (f_hdftest ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  endif (HDF4_BUILD_XDR_LIB)
 
   #-- Adding test for f_hdftest1
   ADD_EXECUTABLE (f_hdftest1 hdftest1.f)
   TARGET_NAMING (f_hdftest1 ${LIB_TYPE})
   TARGET_FORTRAN_PROPERTIES (f_hdftest1 " " " ")
-  SET_TARGET_PROPERTIES (f_hdftest1 PROPERTIES LINKER_LANGUAGE Fortran)
-  IF (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (f_hdftest1 ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET} ${LINK_LIBS})
-  ELSE (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (f_hdftest1 ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${LINK_LIBS})
-  ENDIF (HDF4_BUILD_XDR_LIB)
+  set_target_properties (f_hdftest1 PROPERTIES LINKER_LANGUAGE Fortran)
+  if (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (f_hdftest1 ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET} ${LINK_LIBS})
+  else (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (f_hdftest1 ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${LINK_LIBS})
+  endif (HDF4_BUILD_XDR_LIB)
 
   #-- Adding test for f_tszip
   ADD_EXECUTABLE (f_tszip tszip.f)
   TARGET_NAMING (f_tszip ${LIB_TYPE})
   TARGET_FORTRAN_PROPERTIES (f_tszip " " " ")
-  SET_TARGET_PROPERTIES (f_tszip PROPERTIES LINKER_LANGUAGE Fortran)
-  IF (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (f_tszip ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET} ${LINK_LIBS})
-  ELSE (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (f_tszip ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${LINK_LIBS})
-  ENDIF (HDF4_BUILD_XDR_LIB)
+  set_target_properties (f_tszip PROPERTIES LINKER_LANGUAGE Fortran)
+  if (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (f_tszip ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET} ${LINK_LIBS})
+  else (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (f_tszip ${HDF4_MF_FORTRAN_LIB_TARGET} ${HDF4_SRC_FORTRAN_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_LIB_TARGET} ${LINK_LIBS})
+  endif (HDF4_BUILD_XDR_LIB)
 
 ##############################################################################
 ##############################################################################
@@ -80,7 +80,7 @@
 ##############################################################################
 ##############################################################################
   # Remove any output file left over from previous test run
-  ADD_TEST (
+  add_test (
       NAME MFHDF_FORTRAN-clearall-objects
       COMMAND    ${CMAKE_COMMAND}
           -E remove 
@@ -142,21 +142,21 @@
           test_file34.hdf
           test_file35.hdf
   )
-  IF (HDF4_ENABLE_NETCDF)
-    SET_TESTS_PROPERTIES (MFHDF_FORTRAN-clearall-objects PROPERTIES DEPENDS ftest LABELS ${PROJECT_NAME})
-  ENDIF (HDF4_ENABLE_NETCDF)
+  if (HDF4_ENABLE_NETCDF)
+    set_tests_properties (MFHDF_FORTRAN-clearall-objects PROPERTIES DEPENDS ftest LABELS ${PROJECT_NAME})
+  endif (HDF4_ENABLE_NETCDF)
 
-  ADD_TEST (NAME f_hdftest COMMAND $<TARGET_FILE:f_hdftest>)
-  SET (passRegex "Total errors : [ ]+0")
+  add_test (NAME f_hdftest COMMAND $<TARGET_FILE:f_hdftest>)
+  set (passRegex "Total errors : [ ]+0")
   SET_PROPERTY (TEST f_hdftest PROPERTY PASS_REGULAR_EXPRESSION "${passRegex}")
-  SET_TESTS_PROPERTIES (f_hdftest PROPERTIES DEPENDS MFHDF_FORTRAN-clearall-objects LABELS ${PROJECT_NAME})
+  set_tests_properties (f_hdftest PROPERTIES DEPENDS MFHDF_FORTRAN-clearall-objects LABELS ${PROJECT_NAME})
 
-  ADD_TEST (NAME f_hdftest1 COMMAND $<TARGET_FILE:f_hdftest1>)
-  SET (failRegex "failed" "errors")
+  add_test (NAME f_hdftest1 COMMAND $<TARGET_FILE:f_hdftest1>)
+  set (failRegex "failed" "errors")
   SET_PROPERTY (TEST f_hdftest1 PROPERTY FAIL_REGULAR_EXPRESSION "${failRegex}")
-  SET_TESTS_PROPERTIES (f_hdftest1 PROPERTIES DEPENDS f_hdftest LABELS ${PROJECT_NAME})
+  set_tests_properties (f_hdftest1 PROPERTIES DEPENDS f_hdftest LABELS ${PROJECT_NAME})
 
-  ADD_TEST (NAME f_tszip COMMAND $<TARGET_FILE:f_tszip>)
-  SET (failRegex "failed" "errors")
+  add_test (NAME f_tszip COMMAND $<TARGET_FILE:f_tszip>)
+  set (failRegex "failed" "errors")
   SET_PROPERTY (TEST f_tszip PROPERTY FAIL_REGULAR_EXPRESSION "${failRegex}")
-  SET_TESTS_PROPERTIES (f_tszip PROPERTIES DEPENDS f_hdftest1 LABELS ${PROJECT_NAME})
+  set_tests_properties (f_tszip PROPERTIES DEPENDS f_hdftest1 LABELS ${PROJECT_NAME})
diff --git a/mfhdf/fortran/Makefile.am b/mfhdf/fortran/Makefile.am
index cfc869a..e40fa70 100644
--- a/mfhdf/fortran/Makefile.am
+++ b/mfhdf/fortran/Makefile.am
@@ -4,12 +4,12 @@
 
 include $(top_srcdir)/config/commence.am
 
-INCLUDES=-I$(top_srcdir)/hdf/src        \
+fort_INCLUDES=-I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/hdf/test       \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 DEFINES=-DNDEBUG -DHDF
-AM_CPPFLAGS=$(INCLUDES) $(DEFINES)
+AM_CPPFLAGS=$(fort_INCLUDES) $(DEFINES)
 
 DIST_SUBDIRS = examples
 
diff --git a/mfhdf/fortran/Makefile.in b/mfhdf/fortran/Makefile.in
index ecc4b55..fe1d7fd 100644
--- a/mfhdf/fortran/Makefile.in
+++ b/mfhdf/fortran/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -18,23 +18,51 @@
 #############################################################################
 
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -53,12 +81,12 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(am__include_HEADERS_DIST) $(srcdir)/Makefile.am \
-	$(srcdir)/Makefile.in $(srcdir)/ftest.f.in \
-	$(srcdir)/jackets.c.in $(srcdir)/netcdf.inc.in \
-	$(srcdir)/testfortran.sh.in $(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
+	$(srcdir)/ftest.f.in $(srcdir)/jackets.c.in \
+	$(srcdir)/netcdf.inc.in $(srcdir)/testfortran.sh.in \
+	$(am__include_HEADERS_DIST) $(top_srcdir)/bin/test-driver
 @HDF_BUILD_NETCDF_FALSE at check_PROGRAMS = hdftest$(EXEEXT) \
 @HDF_BUILD_NETCDF_FALSE@	tszip$(EXEEXT) hdftest1$(EXEEXT)
 @HDF_BUILD_NETCDF_TRUE at check_PROGRAMS = ftest$(EXEEXT) \
@@ -78,31 +106,56 @@ CONFIG_CLEAN_VPATH_FILES =
 am__ftest_SOURCES_DIST = ftest.f
 @HDF_BUILD_NETCDF_TRUE at am_ftest_OBJECTS = ftest.$(OBJEXT)
 ftest_OBJECTS = $(am_ftest_OBJECTS)
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
 am_hdftest_OBJECTS = hdftest.$(OBJEXT)
 hdftest_OBJECTS = $(am_hdftest_OBJECTS)
 am_hdftest1_OBJECTS = hdftest1.$(OBJEXT)
 hdftest1_OBJECTS = $(am_hdftest1_OBJECTS)
 am_tszip_OBJECTS = tszip.$(OBJEXT)
 tszip_OBJECTS = $(am_tszip_OBJECTS)
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 F77COMPILE = $(F77) $(AM_FFLAGS) $(FFLAGS)
-LTF77COMPILE = $(LIBTOOL) --tag=F77 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(F77) $(AM_FFLAGS) $(FFLAGS)
+LTF77COMPILE = $(LIBTOOL) $(AM_V_lt) --tag=F77 $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(F77) $(AM_FFLAGS) $(FFLAGS)
+AM_V_F77 = $(am__v_F77_ at AM_V@)
+am__v_F77_ = $(am__v_F77_ at AM_DEFAULT_V@)
+am__v_F77_0 = @echo "  F77     " $@;
+am__v_F77_1 = 
 F77LD = $(F77)
-F77LINK = $(LIBTOOL) --tag=F77 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(F77LD) $(AM_FFLAGS) $(FFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+F77LINK = $(LIBTOOL) $(AM_V_lt) --tag=F77 $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(F77LD) $(AM_FFLAGS) $(FFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_F77LD = $(am__v_F77LD_ at AM_V@)
+am__v_F77LD_ = $(am__v_F77LD_ at AM_DEFAULT_V@)
+am__v_F77LD_0 = @echo "  F77LD   " $@;
+am__v_F77LD_1 = 
 SOURCES = $(ftest_SOURCES) $(hdftest_SOURCES) $(hdftest1_SOURCES) \
 	$(tszip_SOURCES)
 DIST_SOURCES = $(am__ftest_SOURCES_DIST) $(hdftest_SOURCES) \
 	$(hdftest1_SOURCES) $(tszip_SOURCES)
-RECURSIVE_TARGETS = all-recursive check-recursive dvi-recursive \
-	html-recursive info-recursive install-data-recursive \
-	install-dvi-recursive install-exec-recursive \
-	install-html-recursive install-info-recursive \
-	install-pdf-recursive install-ps-recursive install-recursive \
-	installcheck-recursive installdirs-recursive pdf-recursive \
-	ps-recursive uninstall-recursive
+RECURSIVE_TARGETS = all-recursive check-recursive cscopelist-recursive \
+	ctags-recursive dvi-recursive html-recursive info-recursive \
+	install-data-recursive install-dvi-recursive \
+	install-exec-recursive install-html-recursive \
+	install-info-recursive install-pdf-recursive \
+	install-ps-recursive install-recursive installcheck-recursive \
+	installdirs-recursive pdf-recursive ps-recursive \
+	tags-recursive uninstall-recursive
 am__can_run_installinfo = \
   case $$AM_UPDATE_INFO_DIR in \
     n|no|NO) false;; \
@@ -140,15 +193,203 @@ am__installdirs = "$(DESTDIR)$(includedir)"
 HEADERS = $(include_HEADERS)
 RECURSIVE_CLEAN_TARGETS = mostlyclean-recursive clean-recursive	\
   distclean-recursive maintainer-clean-recursive
-AM_RECURSIVE_TARGETS = $(RECURSIVE_TARGETS:-recursive=) \
-	$(RECURSIVE_CLEAN_TARGETS:-recursive=) tags TAGS ctags CTAGS \
-	distdir
+am__recursive_targets = \
+  $(RECURSIVE_TARGETS) \
+  $(RECURSIVE_CLEAN_TARGETS) \
+  $(am__extra_recursive_targets)
+AM_RECURSIVE_TARGETS = $(am__recursive_targets:-recursive=) TAGS CTAGS \
+	check recheck distdir
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+TEST_SUITE_LOG = test-suite.log
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 am__relativize = \
   dir0=`pwd`; \
@@ -177,6 +418,7 @@ am__relativize = \
   reldir="$$dir2"
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -261,6 +503,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -345,13 +588,13 @@ ACLOCAL_AMFLAGS = "-I m4"
 #############################################################################
 CHECK_CLEANFILES = *.chkexe *.chklog test.nc copy.nc *.hdf \
 	testdir/testext.hdf
-INCLUDES = -I$(top_srcdir)/hdf/src        \
+fort_INCLUDES = -I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/hdf/test       \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 
 DEFINES = -DNDEBUG -DHDF
-AM_CPPFLAGS = $(INCLUDES) $(DEFINES)
+AM_CPPFLAGS = $(fort_INCLUDES) $(DEFINES)
 DIST_SUBDIRS = examples
 @HDF_BUILD_NETCDF_FALSE at include_HEADERS = mffunc.inc mffunc.f90
 
@@ -399,7 +642,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-recursive
 
 .SUFFIXES:
-.SUFFIXES: .inc .f90 .f .lo .o .obj
+.SUFFIXES: .inc .f90 .f .lo .log .o .obj .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -448,18 +691,22 @@ clean-checkPROGRAMS:
 	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
 	echo " rm -f" $$list; \
 	rm -f $$list
+
 ftest$(EXEEXT): $(ftest_OBJECTS) $(ftest_DEPENDENCIES) $(EXTRA_ftest_DEPENDENCIES) 
 	@rm -f ftest$(EXEEXT)
-	$(F77LINK) $(ftest_OBJECTS) $(ftest_LDADD) $(LIBS)
+	$(AM_V_F77LD)$(F77LINK) $(ftest_OBJECTS) $(ftest_LDADD) $(LIBS)
+
 hdftest$(EXEEXT): $(hdftest_OBJECTS) $(hdftest_DEPENDENCIES) $(EXTRA_hdftest_DEPENDENCIES) 
 	@rm -f hdftest$(EXEEXT)
-	$(F77LINK) $(hdftest_OBJECTS) $(hdftest_LDADD) $(LIBS)
+	$(AM_V_F77LD)$(F77LINK) $(hdftest_OBJECTS) $(hdftest_LDADD) $(LIBS)
+
 hdftest1$(EXEEXT): $(hdftest1_OBJECTS) $(hdftest1_DEPENDENCIES) $(EXTRA_hdftest1_DEPENDENCIES) 
 	@rm -f hdftest1$(EXEEXT)
-	$(F77LINK) $(hdftest1_OBJECTS) $(hdftest1_LDADD) $(LIBS)
+	$(AM_V_F77LD)$(F77LINK) $(hdftest1_OBJECTS) $(hdftest1_LDADD) $(LIBS)
+
 tszip$(EXEEXT): $(tszip_OBJECTS) $(tszip_DEPENDENCIES) $(EXTRA_tszip_DEPENDENCIES) 
 	@rm -f tszip$(EXEEXT)
-	$(F77LINK) $(tszip_OBJECTS) $(tszip_LDADD) $(LIBS)
+	$(AM_V_F77LD)$(F77LINK) $(tszip_OBJECTS) $(tszip_LDADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -468,13 +715,13 @@ distclean-compile:
 	-rm -f *.tab.c
 
 .f.o:
-	$(F77COMPILE) -c -o $@ $<
+	$(AM_V_F77)$(F77COMPILE) -c -o $@ $<
 
 .f.obj:
-	$(F77COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
+	$(AM_V_F77)$(F77COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f.lo:
-	$(LTF77COMPILE) -c -o $@ $<
+	$(AM_V_F77)$(LTF77COMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -509,14 +756,13 @@ uninstall-includeHEADERS:
 # (1) if the variable is set in 'config.status', edit 'config.status'
 #     (which will cause the Makefiles to be regenerated when you run 'make');
 # (2) otherwise, pass the desired values on the 'make' command line.
-$(RECURSIVE_TARGETS) $(RECURSIVE_CLEAN_TARGETS):
-	@fail= failcom='exit 1'; \
-	for f in x $$MAKEFLAGS; do \
-	  case $$f in \
-	    *=* | --[!k]*);; \
-	    *k*) failcom='fail=yes';; \
-	  esac; \
-	done; \
+$(am__recursive_targets):
+	@fail=; \
+	if $(am__make_keepgoing); then \
+	  failcom='fail=yes'; \
+	else \
+	  failcom='exit 1'; \
+	fi; \
 	dot_seen=no; \
 	target=`echo $@ | sed s/-recursive//`; \
 	case "$@" in \
@@ -537,31 +783,13 @@ $(RECURSIVE_TARGETS) $(RECURSIVE_CLEAN_TARGETS):
 	if test "$$dot_seen" = "no"; then \
 	  $(MAKE) $(AM_MAKEFLAGS) "$$target-am" || exit 1; \
 	fi; test -z "$$fail"
-tags-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) tags); \
-	done
-ctags-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) ctags); \
-	done
-cscopelist-recursive:
-	list='$(SUBDIRS)'; for subdir in $$list; do \
-	  test "$$subdir" = . || ($(am__cd) $$subdir && $(MAKE) $(AM_MAKEFLAGS) cscopelist); \
-	done
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-recursive
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
 	if ($(ETAGS) --etags-include --version) >/dev/null 2>&1; then \
@@ -577,12 +805,7 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      set "$$@" "$$include_option=$$here/$$subdir/TAGS"; \
 	  fi; \
 	done; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -594,15 +817,11 @@ TAGS: tags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS: ctags-recursive $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-recursive
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -611,9 +830,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-recursive
 
-cscopelist: cscopelist-recursive $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -629,6 +849,151 @@ cscopelist: cscopelist-recursive $(HEADERS) $(SOURCES) $(LISP)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all $(check_PROGRAMS) $(check_SCRIPTS)
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -714,6 +1079,9 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 
@@ -794,26 +1162,24 @@ ps-am:
 
 uninstall-am: uninstall-includeHEADERS
 
-.MAKE: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) check-am \
-	cscopelist-recursive ctags-recursive install-am install-strip \
-	tags-recursive
-
-.PHONY: $(RECURSIVE_CLEAN_TARGETS) $(RECURSIVE_TARGETS) CTAGS GTAGS \
-	all all-am all-local check check-TESTS check-am clean \
-	clean-checkPROGRAMS clean-generic clean-libtool cscopelist \
-	cscopelist-recursive ctags ctags-recursive distclean \
-	distclean-compile distclean-generic distclean-libtool \
-	distclean-local distclean-tags distdir dvi dvi-am html html-am \
-	info info-am install install-am install-data install-data-am \
-	install-dvi install-dvi-am install-exec install-exec-am \
-	install-html install-html-am install-includeHEADERS \
-	install-info install-info-am install-man install-pdf \
-	install-pdf-am install-ps install-ps-am install-strip \
-	installcheck installcheck-am installcheck-local installdirs \
-	installdirs-am maintainer-clean maintainer-clean-generic \
-	mostlyclean mostlyclean-compile mostlyclean-generic \
-	mostlyclean-libtool mostlyclean-local pdf pdf-am ps ps-am tags \
-	tags-recursive uninstall uninstall-am uninstall-includeHEADERS
+.MAKE: $(am__recursive_targets) check-am install-am install-strip
+
+.PHONY: $(am__recursive_targets) CTAGS GTAGS TAGS all all-am all-local \
+	check check-TESTS check-am clean clean-checkPROGRAMS \
+	clean-generic clean-libtool cscopelist-am ctags ctags-am \
+	distclean distclean-compile distclean-generic \
+	distclean-libtool distclean-local distclean-tags distdir dvi \
+	dvi-am html html-am info info-am install install-am \
+	install-data install-data-am install-dvi install-dvi-am \
+	install-exec install-exec-am install-html install-html-am \
+	install-includeHEADERS install-info install-info-am \
+	install-man install-pdf install-pdf-am install-ps \
+	install-ps-am install-strip installcheck installcheck-am \
+	installcheck-local installdirs installdirs-am maintainer-clean \
+	maintainer-clean-generic mostlyclean mostlyclean-compile \
+	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
+	pdf-am ps ps-am recheck tags tags-am uninstall uninstall-am \
+	uninstall-includeHEADERS
 
 
 testdir:
diff --git a/mfhdf/fortran/examples/CMakeLists.txt b/mfhdf/fortran/examples/CMakeLists.txt
index c27a952..4cb2dad 100644
--- a/mfhdf/fortran/examples/CMakeLists.txt
+++ b/mfhdf/fortran/examples/CMakeLists.txt
@@ -23,7 +23,7 @@ LINK_DIRECTORIES (
 #-----------------------------------------------------------------------------
 # Define Sources
 #-----------------------------------------------------------------------------
-SET (examples
+set (examples
     SD_create_sds 
     SD_write_to_sds 
     SD_write_slab 
@@ -41,36 +41,36 @@ SET (examples
     SD_compress_sds 
     SD_chunking_example
 )
-SET (skip_examples
+set (skip_examples
     SD_get_info
     SD_dimscale_vs_sds 
     SD_get_attr 
 )
 
-FOREACH (example ${examples})
+foreach (example ${examples})
   ADD_EXECUTABLE (f_exmf_${example} ${HDF4_MFHDF_FORTRAN_EXAMPLES_SOURCE_DIR}/${example}.f)
   TARGET_NAMING (f_exmf_${example} ${LIB_TYPE})
   TARGET_FORTRAN_PROPERTIES (f_exmf_${example} " " " ")
-  SET_TARGET_PROPERTIES (f_exmf_${example} PROPERTIES LINKER_LANGUAGE Fortran)
-  IF (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (f_exmf_${example} ${HDF4_MF_FORTRAN_LIB_TARGET}  ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-  ELSE (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (f_exmf_${example} ${HDF4_MF_FORTRAN_LIB_TARGET}  ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-  ENDIF (HDF4_BUILD_XDR_LIB)
-ENDFOREACH (example ${examples})
+  set_target_properties (f_exmf_${example} PROPERTIES LINKER_LANGUAGE Fortran)
+  if (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (f_exmf_${example} ${HDF4_MF_FORTRAN_LIB_TARGET}  ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+  else (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (f_exmf_${example} ${HDF4_MF_FORTRAN_LIB_TARGET}  ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  endif (HDF4_BUILD_XDR_LIB)
+endforeach (example ${examples})
 
-FOREACH (example ${skip_examples})
+foreach (example ${skip_examples})
   ADD_EXECUTABLE (f_exmf_${example} ${HDF4_MFHDF_FORTRAN_EXAMPLES_SOURCE_DIR}/${example}.f)
   TARGET_NAMING (f_exmf_${example} ${LIB_TYPE})
   TARGET_FORTRAN_PROPERTIES (f_exmf_${example} " " " ")
-  SET_TARGET_PROPERTIES (f_exmf_${example} PROPERTIES LINKER_LANGUAGE Fortran)
-  IF (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (f_exmf_${example} ${HDF4_MF_FORTRAN_LIB_TARGET}  ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-  ELSE (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (f_exmf_${example} ${HDF4_MF_FORTRAN_LIB_TARGET}  ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-  ENDIF (HDF4_BUILD_XDR_LIB)
-ENDFOREACH (example ${skip_examples})
+  set_target_properties (f_exmf_${example} PROPERTIES LINKER_LANGUAGE Fortran)
+  if (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (f_exmf_${example} ${HDF4_MF_FORTRAN_LIB_TARGET}  ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+  else (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (f_exmf_${example} ${HDF4_MF_FORTRAN_LIB_TARGET}  ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  endif (HDF4_BUILD_XDR_LIB)
+endforeach (example ${skip_examples})
 
-IF (BUILD_TESTING)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING)
+if (BUILD_TESTING)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING)
diff --git a/mfhdf/fortran/examples/CMakeTests.cmake b/mfhdf/fortran/examples/CMakeTests.cmake
index bf0b978..75e2c33 100644
--- a/mfhdf/fortran/examples/CMakeTests.cmake
+++ b/mfhdf/fortran/examples/CMakeTests.cmake
@@ -6,7 +6,7 @@
 ##############################################################################
 
 # Remove any output file left over from previous test run
-ADD_TEST (
+add_test (
     NAME MFHDF_FORTRAN_EXAMPLES-clearall-objects
     COMMAND    ${CMAKE_COMMAND}
         -E remove 
@@ -16,19 +16,19 @@ ADD_TEST (
         SDSUNLIMITED.hdf
         SLABS.hdf
 )
-SET_TESTS_PROPERTIES (MFHDF_FORTRAN_EXAMPLES-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
-SET (last_test "MFHDF_FORTRAN_EXAMPLES-clearall-objects")
+set_tests_properties (MFHDF_FORTRAN_EXAMPLES-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
+set (last_test "MFHDF_FORTRAN_EXAMPLES-clearall-objects")
 
-FOREACH (example ${examples})
-  ADD_TEST (NAME f_exmftest_${example} COMMAND $<TARGET_FILE:f_exmf_${example}>)
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (f_exmftest_${example} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (f_exmftest_${example} PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "f_exmftest_${example}")
-ENDFOREACH (example ${examples})
+foreach (example ${examples})
+  add_test (NAME f_exmftest_${example} COMMAND $<TARGET_FILE:f_exmf_${example}>)
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (f_exmftest_${example} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (f_exmftest_${example} PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "f_exmftest_${example}")
+endforeach (example ${examples})
 
-FOREACH (example ${skip_examples})
-  ADD_TEST (NAME f_exmftest_${example} COMMAND ${CMAKE_COMMAND} -E echo "SKIP f_exmftest_${example}")
-ENDFOREACH (example ${skip_examples})
+foreach (example ${skip_examples})
+  add_test (NAME f_exmftest_${example} COMMAND ${CMAKE_COMMAND} -E echo "SKIP f_exmftest_${example}")
+endforeach (example ${skip_examples})
diff --git a/mfhdf/fortran/examples/Makefile.in b/mfhdf/fortran/examples/Makefile.in
index 672e772..47e1a35 100644
--- a/mfhdf/fortran/examples/Makefile.in
+++ b/mfhdf/fortran/examples/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -21,23 +21,51 @@
 # built using h4cc (or h4fc, etc.) instead of the standard compilers.
 # This creates some extra work for us.
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -56,11 +84,11 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am \
-	$(top_srcdir)/config/examples.am
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/examples.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
+	$(top_srcdir)/bin/test-driver
 TESTS = $(TEST_PROG)
 subdir = mfhdf/fortran/examples
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
@@ -71,6 +99,18 @@ mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs
 CONFIG_HEADER = $(top_builddir)/hdf/src/h4config.h
 CONFIG_CLEAN_FILES =
 CONFIG_CLEAN_VPATH_FILES =
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 SOURCES =
 DIST_SOURCES =
 am__can_run_installinfo = \
@@ -78,13 +118,213 @@ am__can_run_installinfo = \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+  test -z "$$files" \
+    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+         $(am__cd) "$$dir" && rm -f $$files; }; \
+  }
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
+TEST_SUITE_LOG = test-suite.log
+LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -169,6 +409,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -302,6 +543,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
+.SUFFIXES: .log .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/examples.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -339,15 +581,270 @@ mostlyclean-libtool:
 
 clean-libtool:
 	-rm -rf .libs _libs
-tags: TAGS
-TAGS:
+tags TAGS:
 
-ctags: CTAGS
-CTAGS:
+ctags CTAGS:
 
 cscope cscopelist:
 
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all 
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+SD_create_sds.log: SD_create_sds
+	@p='SD_create_sds'; \
+	b='SD_create_sds'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_write_to_sds.log: SD_write_to_sds
+	@p='SD_write_to_sds'; \
+	b='SD_write_to_sds'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_write_slab.log: SD_write_slab
+	@p='SD_write_slab'; \
+	b='SD_write_slab'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_alter_sds_values.log: SD_alter_sds_values
+	@p='SD_alter_sds_values'; \
+	b='SD_alter_sds_values'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_unlimited_sds.log: SD_unlimited_sds
+	@p='SD_unlimited_sds'; \
+	b='SD_unlimited_sds'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_mv_sds_to_external.log: SD_mv_sds_to_external
+	@p='SD_mv_sds_to_external'; \
+	b='SD_mv_sds_to_external'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_read_from_sds.log: SD_read_from_sds
+	@p='SD_read_from_sds'; \
+	b='SD_read_from_sds'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_read_subsets.log: SD_read_subsets
+	@p='SD_read_subsets'; \
+	b='SD_read_subsets'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_get_info.log: SD_get_info
+	@p='SD_get_info'; \
+	b='SD_get_info'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_find_sds_by_name.log: SD_find_sds_by_name
+	@p='SD_find_sds_by_name'; \
+	b='SD_find_sds_by_name'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_set_get_dim_info.log: SD_set_get_dim_info
+	@p='SD_set_get_dim_info'; \
+	b='SD_set_get_dim_info'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_dimscale_vs_sds.log: SD_dimscale_vs_sds
+	@p='SD_dimscale_vs_sds'; \
+	b='SD_dimscale_vs_sds'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_set_attr.log: SD_set_attr
+	@p='SD_set_attr'; \
+	b='SD_set_attr'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_get_attr.log: SD_get_attr
+	@p='SD_get_attr'; \
+	b='SD_get_attr'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_compress_sds.log: SD_compress_sds
+	@p='SD_compress_sds'; \
+	b='SD_compress_sds'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+SD_chunking_example.log: SD_chunking_example
+	@p='SD_chunking_example'; \
+	b='SD_chunking_example'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -404,6 +901,9 @@ install-strip:
 	fi
 mostlyclean-generic:
 	-test -z "$(MOSTLYCLEANFILES)" || rm -f $(MOSTLYCLEANFILES)
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 	-test -z "$(CLEANFILES)" || rm -f $(CLEANFILES)
@@ -486,17 +986,18 @@ uninstall-am: uninstall-local
 .MAKE: check-am install-am install-strip
 
 .PHONY: all all-am all-local check check-TESTS check-am clean \
-	clean-generic clean-libtool distclean distclean-generic \
-	distclean-libtool distdir dvi dvi-am html html-am info info-am \
-	install install-am install-data install-data-am \
-	install-data-local install-dvi install-dvi-am install-exec \
-	install-exec-am install-html install-html-am install-info \
-	install-info-am install-man install-pdf install-pdf-am \
-	install-ps install-ps-am install-strip installcheck \
-	installcheck-am installcheck-local installdirs \
+	clean-generic clean-libtool cscopelist-am ctags-am distclean \
+	distclean-generic distclean-libtool distdir dvi dvi-am html \
+	html-am info info-am install install-am install-data \
+	install-data-am install-data-local install-dvi install-dvi-am \
+	install-exec install-exec-am install-html install-html-am \
+	install-info install-info-am install-man install-pdf \
+	install-pdf-am install-ps install-ps-am install-strip \
+	installcheck installcheck-am installcheck-local installdirs \
 	maintainer-clean maintainer-clean-generic mostlyclean \
 	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
-	pdf-am ps ps-am uninstall uninstall-am uninstall-local
+	pdf-am ps ps-am recheck tags-am uninstall uninstall-am \
+	uninstall-local
 
 
 # How to build Fortran programs using h4fc
diff --git a/mfhdf/fortran/testfortran.sh.in b/mfhdf/fortran/testfortran.sh.in
old mode 100755
new mode 100644
diff --git a/mfhdf/hdfimport/CMakeLists.txt b/mfhdf/hdfimport/CMakeLists.txt
index 42c1238..7d26c32 100644
--- a/mfhdf/hdfimport/CMakeLists.txt
+++ b/mfhdf/hdfimport/CMakeLists.txt
@@ -4,39 +4,39 @@ PROJECT (HDF4_MFHDF_HDFIMPORT)
 INCLUDE_DIRECTORIES (${HDF4_HDFSOURCE_DIR})
 INCLUDE_DIRECTORIES (${HDF4_MFHDFSOURCE_DIR})
 
-IF (WIN32 AND NOT CYGWIN)
-  SET (CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} /NODEFAULTLIB:LIBCMT")
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  set (CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} /NODEFAULTLIB:LIBCMT")
+endif (WIN32)
 
-ADD_DEFINITIONS (-DHDF)
+add_definitions (-DHDF)
 
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS)
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  add_definitions (-DDOS_FS)
+endif (WIN32)
 
-IF (HDF4_BUILD_XDR_LIB)
-  IF (WIN32 AND NOT CYGWIN)
-    ADD_DEFINITIONS (-DNO_SYS_XDR_INC)
-  ENDIF (WIN32 AND NOT CYGWIN)
+if (HDF4_BUILD_XDR_LIB)
+  if (WIN32)
+    add_definitions (-DNO_SYS_XDR_INC)
+  endif (WIN32)
   INCLUDE_DIRECTORIES (${HDF4_MFHDF_XDR_DIR})
-ENDIF (HDF4_BUILD_XDR_LIB)
+endif (HDF4_BUILD_XDR_LIB)
 
-SET (hdfimport_SRCS
+set (hdfimport_SRCS
     ${HDF4_MFHDF_HDFIMPORT_SOURCE_DIR}/hdfimport.c
 )
   
 ADD_EXECUTABLE (hdfimport ${hdfimport_SRCS})
 TARGET_C_PROPERTIES (hdfimport " " " ")
-IF (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (hdfimport ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-ELSE (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (hdfimport ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDIF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (hdfimport ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+else (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (hdfimport ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endif (HDF4_BUILD_XDR_LIB)
 TARGET_NAMING (hdfimport ${LIB_TYPE})
 
-IF (BUILD_TESTING)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING)
+if (BUILD_TESTING)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING)
 
 ##############################################################################
 ##############################################################################
diff --git a/mfhdf/hdfimport/CMakeTests.cmake b/mfhdf/hdfimport/CMakeTests.cmake
index 3a7127e..52de670 100644
--- a/mfhdf/hdfimport/CMakeTests.cmake
+++ b/mfhdf/hdfimport/CMakeTests.cmake
@@ -6,7 +6,7 @@
 ##############################################################################
  
   #-- Copy all the dat files from the test directory into the source directory
-  SET (HDF4_REFERENCE_TEST_FILES
+  set (HDF4_REFERENCE_TEST_FILES
       hdfimport.input1
       hdfimport.out1
 #      hdfimport.out2
@@ -15,35 +15,35 @@
       SDSfloat3.hdf
   )
    
-  FOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
-      SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-      #MESSAGE (STATUS " Copying ${HDF4_MFHDF_HDFIMPORT_SOURCE_DIR}/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_REFERENCE_TEST_FILES})
+      set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+      #message (STATUS " Copying ${HDF4_MFHDF_HDFIMPORT_SOURCE_DIR}/${h4_file} to ${PROJECT_BINARY_DIR}/")
       ADD_CUSTOM_COMMAND (
           TARGET     hdfimport 
           POST_BUILD
           COMMAND    ${CMAKE_COMMAND}
           ARGS       -E copy_if_different ${HDF4_MFHDF_HDFIMPORT_SOURCE_DIR}/${h4_file} ${dest}
      )      
-  ENDFOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
+  endforeach (h4_file ${HDF4_REFERENCE_TEST_FILES})
   
-  IF (WIN32 AND NOT CYGWIN)
+  if (WIN32)
     ADD_CUSTOM_COMMAND (
         TARGET     hdfimport
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_MFHDF_HDFIMPORT_SOURCE_DIR}/hdfimport-w.out2 ${PROJECT_BINARY_DIR}/hdfimport.out2
     )
-  ELSE (WIN32 AND NOT CYGWIN)
+  else (WIN32)
     ADD_CUSTOM_COMMAND (
         TARGET     hdfimport
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_MFHDF_HDFIMPORT_SOURCE_DIR}/hdfimport.out2 ${PROJECT_BINARY_DIR}/hdfimport.out2
     )
-  ENDIF (WIN32 AND NOT CYGWIN)
+  endif (WIN32)
  
   #-- Copy all the hdfls tst files from the test directory into the source directory
-  SET (HDF4_LS_TEST_FILES
+  set (HDF4_LS_TEST_FILES
       ctxtr2.tst 
       ctxtr3.tst 
       cb32i2.tst 
@@ -62,43 +62,43 @@
       SDSfloat3.tst
   )
    
-  FOREACH (ls_file ${HDF4_LS_TEST_FILES})
-      SET (dest "${PROJECT_BINARY_DIR}/${ls_file}")
-      #MESSAGE (STATUS " Copying ${HDF4_MFHDF_HDFIMPORT_SOURCE_DIR}/${ls_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (ls_file ${HDF4_LS_TEST_FILES})
+      set (dest "${PROJECT_BINARY_DIR}/${ls_file}")
+      #message (STATUS " Copying ${HDF4_MFHDF_HDFIMPORT_SOURCE_DIR}/${ls_file} to ${PROJECT_BINARY_DIR}/")
       ADD_CUSTOM_COMMAND (
           TARGET     hdfimport 
           POST_BUILD
           COMMAND    ${CMAKE_COMMAND}
           ARGS       -E copy_if_different ${HDF4_MFHDF_HDFIMPORT_SOURCE_DIR}/testfiles/${ls_file} ${dest}
      )      
-  ENDFOREACH (ls_file ${HDF4_LS_TEST_FILES})
+  endforeach (ls_file ${HDF4_LS_TEST_FILES})
 
   #-- hdfimporttest
-  SET (hdfimporttest_SRCS
+  set (hdfimporttest_SRCS
       ${HDF4_MFHDF_HDFIMPORT_SOURCE_DIR}/hdfimporttest.c
   )
   
   ADD_EXECUTABLE (hdfimporttest ${hdfimporttest_SRCS})
   TARGET_C_PROPERTIES (hdfimporttest " " " ")
-  IF (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (hdfimporttest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-  ELSE (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (hdfimporttest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-  ENDIF (HDF4_BUILD_XDR_LIB)
+  if (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (hdfimporttest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+  else (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (hdfimporttest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  endif (HDF4_BUILD_XDR_LIB)
   TARGET_NAMING (hdfimporttest ${LIB_TYPE})
 
   #-- gen_sds_floats
-  SET (gen_sds_floats_SRCS
+  set (gen_sds_floats_SRCS
       ${HDF4_MFHDF_HDFIMPORT_SOURCE_DIR}/gen_sds_floats.c
   )
   
   ADD_EXECUTABLE (gen_sds_floats ${gen_sds_floats_SRCS})
   TARGET_C_PROPERTIES (gen_sds_floats " " " ")
-  IF (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (gen_sds_floats ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-  ELSE (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (gen_sds_floats ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-  ENDIF (HDF4_BUILD_XDR_LIB)
+  if (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (gen_sds_floats ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+  else (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (gen_sds_floats ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  endif (HDF4_BUILD_XDR_LIB)
   TARGET_NAMING (gen_sds_floats ${LIB_TYPE})
   
 ##############################################################################
@@ -108,26 +108,26 @@
 ##############################################################################
 
   MACRO (ADD_H4_TEST resultfile resultcode testtfile testtype)
-    IF ( NOT ${testtype} STREQUAL "")
-      IF (${testtype} STREQUAL "N")
-        ADD_TEST (NAME HIMPORT-${testtfile} COMMAND $<TARGET_FILE:hdfimport> ${resultfile} -n -o ${testtfile}.hdf)
-      ENDIF (${testtype} STREQUAL "N")
-      IF (${testtype} STREQUAL "R")
-        ADD_TEST (NAME HIMPORT-${testtfile} COMMAND $<TARGET_FILE:hdfimport> ${resultfile} -o ${testtfile}.hdf -raster ${ARGN})
-      ENDIF (${testtype} STREQUAL "R")
-    ELSE ( NOT ${testtype} STREQUAL "")
-      ADD_TEST (NAME HIMPORT-${testtfile} COMMAND $<TARGET_FILE:hdfimport> ${resultfile} -o ${testtfile}.hdf)
-    ENDIF ( NOT ${testtype} STREQUAL "")
-    IF (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HIMPORT-${testtfile} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-    ELSE (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HIMPORT-${testtfile} PROPERTIES LABELS ${PROJECT_NAME})
-    ENDIF (NOT "${last_test}" STREQUAL "")
+    if ( NOT ${testtype} STREQUAL "")
+      if (${testtype} STREQUAL "N")
+        add_test (NAME HIMPORT-${testtfile} COMMAND $<TARGET_FILE:hdfimport> ${resultfile} -n -o ${testtfile}.hdf)
+      endif (${testtype} STREQUAL "N")
+      if (${testtype} STREQUAL "R")
+        add_test (NAME HIMPORT-${testtfile} COMMAND $<TARGET_FILE:hdfimport> ${resultfile} -o ${testtfile}.hdf -raster ${ARGN})
+      endif (${testtype} STREQUAL "R")
+    else ( NOT ${testtype} STREQUAL "")
+      add_test (NAME HIMPORT-${testtfile} COMMAND $<TARGET_FILE:hdfimport> ${resultfile} -o ${testtfile}.hdf)
+    endif ( NOT ${testtype} STREQUAL "")
+    if (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HIMPORT-${testtfile} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+    else (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HIMPORT-${testtfile} PROPERTIES LABELS ${PROJECT_NAME})
+    endif (NOT "${last_test}" STREQUAL "")
 
-    IF (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (NAME HIMPORTLS-${testtfile} COMMAND $<TARGET_FILE:hdfls> -l ${testtfile}.hdf)
-    ELSE (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (
+    if (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (NAME HIMPORTLS-${testtfile} COMMAND $<TARGET_FILE:hdfls> -l ${testtfile}.hdf)
+    else (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (
           NAME HIMPORTLS-${testtfile}
           COMMAND "${CMAKE_COMMAND}"
               -D "TEST_PROGRAM=$<TARGET_FILE:hdfls>"
@@ -137,25 +137,25 @@
               -D "TEST_EXPECT=${resultcode}"
               -D "TEST_FILTER:STRING=(File library|String)[^\n]+\n"
               -D "TEST_REFERENCE=${testtfile}.tst"
-              -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+              -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
       )
-    ENDIF (HDF4_ENABLE_USING_MEMCHECKER)
-    SET_TESTS_PROPERTIES (HIMPORTLS-${testtfile} PROPERTIES DEPENDS HIMPORT-${testtfile} LABELS ${PROJECT_NAME})
-    SET (last_test "HIMPORTLS-${testtfile}")
+    endif (HDF4_ENABLE_USING_MEMCHECKER)
+    set_tests_properties (HIMPORTLS-${testtfile} PROPERTIES DEPENDS HIMPORT-${testtfile} LABELS ${PROJECT_NAME})
+    set (last_test "HIMPORTLS-${testtfile}")
   ENDMACRO (ADD_H4_TEST)
 
   MACRO (ADD_H4_TEST_OUT resultfile resultcode)
-    ADD_TEST (NAME HIMPORT-OUT-${resultfile} COMMAND $<TARGET_FILE:hdfimport> ${resultfile}.hdf -o ${resultfile}.out)
-    IF (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HIMPORT-OUT-${resultfile} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-    ELSE (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HIMPORT-OUT-${resultfile} PROPERTIES LABELS ${PROJECT_NAME})
-    ENDIF (NOT "${last_test}" STREQUAL "")
+    add_test (NAME HIMPORT-OUT-${resultfile} COMMAND $<TARGET_FILE:hdfimport> ${resultfile}.hdf -o ${resultfile}.out)
+    if (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HIMPORT-OUT-${resultfile} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+    else (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HIMPORT-OUT-${resultfile} PROPERTIES LABELS ${PROJECT_NAME})
+    endif (NOT "${last_test}" STREQUAL "")
 
-    IF (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (NAME HIMPORTLS-OUT-${resultfile} COMMAND $<TARGET_FILE:hdfls> ${resultfile}.out)
-    ELSE (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (
+    if (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (NAME HIMPORTLS-OUT-${resultfile} COMMAND $<TARGET_FILE:hdfls> ${resultfile}.out)
+    else (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (
           NAME HIMPORTLS-OUT-${resultfile}
           COMMAND "${CMAKE_COMMAND}"
               -D "TEST_PROGRAM=$<TARGET_FILE:hdfls>"
@@ -165,18 +165,18 @@
               -D "TEST_EXPECT=${resultcode}"
               -D "TEST_FILTER:STRING=(File library|String)[^\n]+\n"
               -D "TEST_REFERENCE=${resultfile}.tst"
-              -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+              -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
       )
-    ENDIF (HDF4_ENABLE_USING_MEMCHECKER)
-    SET_TESTS_PROPERTIES (HIMPORTLS-OUT-${resultfile} PROPERTIES DEPENDS HIMPORT-OUT-${resultfile} LABELS ${PROJECT_NAME})
-    SET (last_test "HIMPORTLS-OUT-${resultfile}")
+    endif (HDF4_ENABLE_USING_MEMCHECKER)
+    set_tests_properties (HIMPORTLS-OUT-${resultfile} PROPERTIES DEPENDS HIMPORT-OUT-${resultfile} LABELS ${PROJECT_NAME})
+    set (last_test "HIMPORTLS-OUT-${resultfile}")
   ENDMACRO (ADD_H4_TEST_OUT)
 
   MACRO (ADD_H4_TEST_ED testfile resultfile resultcode)
-    IF (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (NAME HIMPORT-EDIT COMMAND $<TARGET_FILE:hdfed> -batch)
-    ELSE (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (
+    if (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (NAME HIMPORT-EDIT COMMAND $<TARGET_FILE:hdfed> -batch)
+    else (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (
           NAME HIMPORT-EDIT
           COMMAND "${CMAKE_COMMAND}"
               -D "TEST_PROGRAM=$<TARGET_FILE:hdfed>"
@@ -186,15 +186,15 @@
               -D "TEST_OUTPUT=${testfile}.tmp"
               -D "TEST_EXPECT=${resultcode}"
               -D "TEST_REFERENCE=${resultfile}"
-              -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+              -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
       )
-    ENDIF (HDF4_ENABLE_USING_MEMCHECKER)
-    IF (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HIMPORT-EDIT PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-    ELSE (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HIMPORT-EDIT PROPERTIES LABELS ${PROJECT_NAME})
-    ENDIF (NOT "${last_test}" STREQUAL "")
-    SET (last_test "HIMPORT-EDIT")
+    endif (HDF4_ENABLE_USING_MEMCHECKER)
+    if (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HIMPORT-EDIT PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+    else (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HIMPORT-EDIT PROPERTIES LABELS ${PROJECT_NAME})
+    endif (NOT "${last_test}" STREQUAL "")
+    set (last_test "HIMPORT-EDIT")
   ENDMACRO (ADD_H4_TEST_ED)
 
 ##############################################################################
@@ -204,7 +204,7 @@
 ##############################################################################
 
   # Remove any output file left over from previous test run
-  ADD_TEST (
+  add_test (
       NAME hdfimport-clear-refs
       COMMAND    ${CMAKE_COMMAND}
           -E remove 
@@ -269,20 +269,20 @@
           SDSfloat2.tmp.err
           SDSfloat3.tmp.err
   )
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (hdfimport-clear-refs PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (hdfimport-clear-refs PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "hdfimport-clear-refs")
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (hdfimport-clear-refs PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (hdfimport-clear-refs PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "hdfimport-clear-refs")
 
-  ADD_TEST (NAME HIMPORTtest COMMAND $<TARGET_FILE:hdfimporttest>)
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (HIMPORTtest PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (HIMPORTtest PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "HIMPORTtest")
+  add_test (NAME HIMPORTtest COMMAND $<TARGET_FILE:hdfimporttest>)
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (HIMPORTtest PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (HIMPORTtest PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "HIMPORTtest")
 
   # "Testing for 32-bit floating point ASCII (2D data)" 
   ADD_H4_TEST (ctxtr2 0 ctxtr2 "")
diff --git a/mfhdf/hdfimport/Makefile.am b/mfhdf/hdfimport/Makefile.am
index 83be126..0716108 100644
--- a/mfhdf/hdfimport/Makefile.am
+++ b/mfhdf/hdfimport/Makefile.am
@@ -5,11 +5,11 @@
 include $(top_srcdir)/config/commence.am
 
 ## Setup the different includes and preprocessor #defines we need.
-INCLUDES=-I$(top_srcdir)/hdf/src        \
+hdfimport_INCLUDES=-I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 DEFINES=-DNDEBUG -DHDF
-AM_CPPFLAGS=$(INCLUDES) $(DEFINES)
+AM_CPPFLAGS=$(hdfimport_INCLUDES) $(DEFINES)
 
 ## Add hdfimport specific linker flags here
 hdfimport_LDFLAGS = $(LT_STATIC_EXEC) $(AM_LDFLAGS)
diff --git a/mfhdf/hdfimport/Makefile.in b/mfhdf/hdfimport/Makefile.in
index f5db6aa..171b135 100644
--- a/mfhdf/hdfimport/Makefile.in
+++ b/mfhdf/hdfimport/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -18,23 +18,51 @@
 #############################################################################
 
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -53,11 +81,11 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
 	$(srcdir)/testutil.sh.in $(top_srcdir)/bin/depcomp \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am
+	$(top_srcdir)/bin/test-driver
 bin_PROGRAMS = hdfimport$(EXEEXT)
 check_PROGRAMS = hdfimporttest$(EXEEXT) gen_sds_floats$(EXEEXT)
 TESTS = $(am__EXEEXT_1) $(TEST_SCRIPT)
@@ -76,30 +104,55 @@ gen_sds_floats_SOURCES = gen_sds_floats.c
 gen_sds_floats_OBJECTS = gen_sds_floats.$(OBJEXT)
 gen_sds_floats_LDADD = $(LDADD)
 gen_sds_floats_DEPENDENCIES = $(LIBMFHDF) $(LIBHDF)
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
 hdfimport_SOURCES = hdfimport.c
 hdfimport_OBJECTS = hdfimport.$(OBJEXT)
 hdfimport_LDADD = $(LDADD)
 hdfimport_DEPENDENCIES = $(LIBMFHDF) $(LIBHDF)
-hdfimport_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) \
+hdfimport_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
 	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
 	$(hdfimport_LDFLAGS) $(LDFLAGS) -o $@
 hdfimporttest_SOURCES = hdfimporttest.c
 hdfimporttest_OBJECTS = hdfimporttest.$(OBJEXT)
 hdfimporttest_LDADD = $(LDADD)
 hdfimporttest_DEPENDENCIES = $(LIBMFHDF) $(LIBHDF)
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 SOURCES = gen_sds_floats.c hdfimport.c hdfimporttest.c
 DIST_SOURCES = gen_sds_floats.c hdfimport.c hdfimporttest.c
 am__can_run_installinfo = \
@@ -107,16 +160,232 @@ am__can_run_installinfo = \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+  test -z "$$files" \
+    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+         $(am__cd) "$$dir" && rm -f $$files; }; \
+  }
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
 am__EXEEXT_1 = hdfimporttest$(EXEEXT)
+TEST_SUITE_LOG = test-suite.log
+LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -201,6 +470,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -281,12 +551,12 @@ ACLOCAL_AMFLAGS = "-I m4"
 # .chkexe files are used to mark tests that have run successfully.
 # .chklog files are output from those tests.
 CHECK_CLEANFILES = *.chkexe *.chklog
-INCLUDES = -I$(top_srcdir)/hdf/src        \
+hdfimport_INCLUDES = -I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 
 DEFINES = -DNDEBUG -DHDF
-AM_CPPFLAGS = $(INCLUDES) $(DEFINES)
+AM_CPPFLAGS = $(hdfimport_INCLUDES) $(DEFINES)
 hdfimport_LDFLAGS = $(LT_STATIC_EXEC) $(AM_LDFLAGS)
 
 #############################################################################
@@ -319,7 +589,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
-.SUFFIXES: .c .lo .o .obj
+.SUFFIXES: .c .lo .log .o .obj .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -362,10 +632,12 @@ install-binPROGRAMS: $(bin_PROGRAMS)
 	fi; \
 	for p in $$list; do echo "$$p $$p"; done | \
 	sed 's/$(EXEEXT)$$//' | \
-	while read p p1; do if test -f $$p || test -f $$p1; \
-	  then echo "$$p"; echo "$$p"; else :; fi; \
+	while read p p1; do if test -f $$p \
+	 || test -f $$p1 \
+	  ; then echo "$$p"; echo "$$p"; else :; fi; \
 	done | \
-	sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \
+	sed -e 'p;s,.*/,,;n;h' \
+	    -e 's|.*|.|' \
 	    -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
 	sed 'N;N;N;s,\n, ,g' | \
 	$(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
@@ -386,7 +658,8 @@ uninstall-binPROGRAMS:
 	@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
 	files=`for p in $$list; do echo "$$p"; done | \
 	  sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
-	      -e 's/$$/$(EXEEXT)/' `; \
+	      -e 's/$$/$(EXEEXT)/' \
+	`; \
 	test -n "$$list" || exit 0; \
 	echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
 	cd "$(DESTDIR)$(bindir)" && rm -f $$files
@@ -408,15 +681,18 @@ clean-checkPROGRAMS:
 	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
 	echo " rm -f" $$list; \
 	rm -f $$list
+
 gen_sds_floats$(EXEEXT): $(gen_sds_floats_OBJECTS) $(gen_sds_floats_DEPENDENCIES) $(EXTRA_gen_sds_floats_DEPENDENCIES) 
 	@rm -f gen_sds_floats$(EXEEXT)
-	$(LINK) $(gen_sds_floats_OBJECTS) $(gen_sds_floats_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(gen_sds_floats_OBJECTS) $(gen_sds_floats_LDADD) $(LIBS)
+
 hdfimport$(EXEEXT): $(hdfimport_OBJECTS) $(hdfimport_DEPENDENCIES) $(EXTRA_hdfimport_DEPENDENCIES) 
 	@rm -f hdfimport$(EXEEXT)
-	$(hdfimport_LINK) $(hdfimport_OBJECTS) $(hdfimport_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdfimport_LINK) $(hdfimport_OBJECTS) $(hdfimport_LDADD) $(LIBS)
+
 hdfimporttest$(EXEEXT): $(hdfimporttest_OBJECTS) $(hdfimporttest_DEPENDENCIES) $(EXTRA_hdfimporttest_DEPENDENCIES) 
 	@rm -f hdfimporttest$(EXEEXT)
-	$(LINK) $(hdfimporttest_OBJECTS) $(hdfimporttest_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(hdfimporttest_OBJECTS) $(hdfimporttest_LDADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -429,25 +705,25 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdfimporttest.Po at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -455,26 +731,15 @@ mostlyclean-libtool:
 clean-libtool:
 	-rm -rf .libs _libs
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -486,15 +751,11 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -503,9 +764,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -521,6 +783,158 @@ cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all $(check_PROGRAMS) $(check_SCRIPTS)
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+hdfimporttest.log: hdfimporttest$(EXEEXT)
+	@p='hdfimporttest$(EXEEXT)'; \
+	b='hdfimporttest'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -580,6 +994,9 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 
@@ -663,20 +1080,21 @@ uninstall-am: uninstall-binPROGRAMS
 
 .MAKE: check-am install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am all-local check check-TESTS check-am \
-	clean clean-binPROGRAMS clean-checkPROGRAMS clean-generic \
-	clean-libtool cscopelist ctags distclean distclean-compile \
-	distclean-generic distclean-libtool distclean-tags distdir dvi \
-	dvi-am html html-am info info-am install install-am \
-	install-binPROGRAMS install-data install-data-am install-dvi \
-	install-dvi-am install-exec install-exec-am install-html \
-	install-html-am install-info install-info-am install-man \
-	install-pdf install-pdf-am install-ps install-ps-am \
-	install-strip installcheck installcheck-am installdirs \
-	maintainer-clean maintainer-clean-generic mostlyclean \
-	mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
-	mostlyclean-local pdf pdf-am ps ps-am tags uninstall \
-	uninstall-am uninstall-binPROGRAMS
+.PHONY: CTAGS GTAGS TAGS all all-am all-local check check-TESTS \
+	check-am clean clean-binPROGRAMS clean-checkPROGRAMS \
+	clean-generic clean-libtool cscopelist-am ctags ctags-am \
+	distclean distclean-compile distclean-generic \
+	distclean-libtool distclean-tags distdir dvi dvi-am html \
+	html-am info info-am install install-am install-binPROGRAMS \
+	install-data install-data-am install-dvi install-dvi-am \
+	install-exec install-exec-am install-html install-html-am \
+	install-info install-info-am install-man install-pdf \
+	install-pdf-am install-ps install-ps-am install-strip \
+	installcheck installcheck-am installdirs maintainer-clean \
+	maintainer-clean-generic mostlyclean mostlyclean-compile \
+	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
+	pdf-am ps ps-am recheck tags tags-am uninstall uninstall-am \
+	uninstall-binPROGRAMS
 
 
 # lib/progs/tests targets recurse into subdirectories. build-* targets
diff --git a/mfhdf/hdfimport/hdfimport.c b/mfhdf/hdfimport/hdfimport.c
index 5834de8..755db56 100644
--- a/mfhdf/hdfimport/hdfimport.c
+++ b/mfhdf/hdfimport/hdfimport.c
@@ -624,7 +624,7 @@ main(int argc, char *argv[])
 	      break;
 	    case ERR:   /* command syntax error */
 	    default:
-	      (void) fprintf(stderr, err2);
+	      (void) fprintf(stderr, "%s", err2);
 	      usage(argv[0]);
 	      goto err;
             }
@@ -635,7 +635,7 @@ main(int argc, char *argv[])
      */
     if (!outfile_named)
       {
-          (void) fprintf(stderr, err3);
+          (void) fprintf(stderr, "%s", err3);
           usage(argv[0]);
           goto err;
       }
@@ -652,7 +652,7 @@ main(int argc, char *argv[])
     return(0);
 
   err:
-    (void) fprintf(stderr, err4);
+    (void) fprintf(stderr, "%s", err4);
     return(1);
 }
 
@@ -941,7 +941,7 @@ gdimen(struct infilesformat infile_info, struct Input *in, FILE *strm)
 	sds_id = SDselect (sd_id, sd_index);
 	if (sds_id == FAIL)
           {
-            (void) fprintf(stderr, err7, infile);
+            (void) fprintf(stderr, "%s", err7);
             goto err;
           }
 
@@ -956,7 +956,7 @@ gdimen(struct infilesformat infile_info, struct Input *in, FILE *strm)
 	sds_name = (char *)HDmalloc(name_len+1);
 	if (sds_name == NULL)
           {
-            (void) fprintf(stderr, err6);
+            (void) fprintf(stderr, "%s", err6);
             goto err;
           }
 
@@ -1190,7 +1190,7 @@ gint(char *infile, FILE * strm, int32 *ival, struct Input *in)
 static int
 gint32(char *infile, FILE * strm, int32 *ival, struct Input *in)
 {
-    const char *err1 = "Unable to get 'int' value from file: %s.\n";
+    const char *err1 = "Unable to get 'int32' value from file: %s.\n";
     /*
      * process TEXT-formatted input
      */
@@ -1233,7 +1233,7 @@ gint32(char *infile, FILE * strm, int32 *ival, struct Input *in)
 static int
 gint16(char *infile, FILE * strm, int16 *ival, struct Input *in)
 {
-    const char *err1 = "Unable to get 'int' value from file: %s.\n";
+    const char *err1 = "Unable to get 'int16' value from file: %s.\n";
      
     if (in->is_text == TRUE)
       {
@@ -1272,7 +1272,7 @@ gint16(char *infile, FILE * strm, int16 *ival, struct Input *in)
 static int
 gint8(char *infile, FILE * strm, int8 *ival, struct Input *in)
 {
-    const char *err1 = "Unable to get 'int' 8  value from file: %s.\n";
+    const char *err1 = "Unable to get 'int8' value from file: %s.\n";
     int16 temp;
     
     if (in->is_text == TRUE)
@@ -2223,7 +2223,7 @@ indexes(float32 *scale, int dim, int *idx, int res)
      */
     if ((midpt = (float32 *) HDmalloc((size_t) dim * sizeof(float32))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
     for (i = 0; i < dim - 1; i++)
@@ -2325,13 +2325,13 @@ interp(struct Input *in, struct Raster *im)
      */
     if ((hratio = (float32 *) HDmalloc((size_t) im->hres * sizeof(float32))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
     if ((vratio = (float32 *) HDmalloc((unsigned int) im->vres *
                                          sizeof(float32))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
     if (in->rank == 3)
@@ -2339,7 +2339,7 @@ interp(struct Input *in, struct Raster *im)
           if ((dratio = (float32 *) HDmalloc((unsigned int) im->dres *
                                                sizeof(float32))) == NULL)
             {
-                (void) fprintf(stderr, err1);
+                (void) fprintf(stderr, "%s", err1);
                 goto err;
             }
       }
@@ -2351,13 +2351,13 @@ interp(struct Input *in, struct Raster *im)
     if ((hinc = (int *) HDmalloc((unsigned int) im->hres *
                                    sizeof(int))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
     if ((voff = (int *) HDmalloc((unsigned int) (im->vres + 1) *
                                    sizeof(int))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
     if (in->rank == 3)
@@ -2365,7 +2365,7 @@ interp(struct Input *in, struct Raster *im)
           if ((doff = (int *) HDmalloc((unsigned int) (im->dres + 1) *
                                          sizeof(int))) == NULL)
             {
-                (void) fprintf(stderr, err1);
+                (void) fprintf(stderr, "%s", err1);
                 goto err;
             }
       }
@@ -2636,7 +2636,7 @@ palette(char *palfile)
      */
     if (DFR8setpalette(pal))
       {
-          (void) fprintf(stderr, err3);
+          (void) fprintf(stderr, "%s", err3);
           goto err;
       }
 
@@ -2677,7 +2677,7 @@ pixrep(struct Input *in, struct Raster *im)
      */
     if ((hidx = (int *) HDmalloc((unsigned int) (im->hres + 1) * sizeof(int))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
 
@@ -2690,7 +2690,7 @@ pixrep(struct Input *in, struct Raster *im)
     if ((vidx = (int *) HDmalloc((unsigned int) (im->vres + 1) *
                                    sizeof(int))) == NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
 
@@ -2707,7 +2707,7 @@ pixrep(struct Input *in, struct Raster *im)
           if ((didx = (int *) HDmalloc((unsigned int) (im->dres + 1) *
                                          sizeof(int))) == NULL)
             {
-                (void) fprintf(stderr, err1);
+                (void) fprintf(stderr, "%s", err1);
                 goto err;
             }
 
@@ -2721,7 +2721,7 @@ pixrep(struct Input *in, struct Raster *im)
     if ((pix = (unsigned char *) HDmalloc((unsigned int) (in->dims[0] + 1))) ==
         NULL)
       {
-          (void) fprintf(stderr, err1);
+          (void) fprintf(stderr, "%s", err1);
           goto err;
       }
     for (k = 0, odidx = didx[0] - 1; k < im->dres; k++)
@@ -2838,35 +2838,35 @@ alloc_data(VOIDP *data, int32 len, int outtype)
 	case 5: /* NO_NE */
 	    if ((*data = (VOIDP) HDmalloc((size_t) len * sizeof(float32))) == NULL)
 	      {
-		(void) fprintf(stderr, alloc_err);
+		(void) fprintf(stderr, "%s", alloc_err);
 		return FAIL;
 	      }
 	    break;
 	case 1: /* 64-bit float */
 	    if ((*data = (VOIDP) HDmalloc((size_t) len * sizeof(float64))) == NULL)
 	      {
-		(void) fprintf(stderr, alloc_err);
+		(void) fprintf(stderr, "%s", alloc_err);
 		return FAIL;
 	      }
 	    break;
 	case 2: /* 32-bit integer */
 	    if ((*data = (VOIDP) HDmalloc((size_t) len * sizeof(int32))) == NULL)
 	      {
-		(void) fprintf(stderr, alloc_err);
+		(void) fprintf(stderr, "%s", alloc_err);
 		return FAIL;
 	      }
 	    break;
 	case 3: /* 16-bit integer */
 	    if ((*data = (VOIDP) HDmalloc((size_t) len * sizeof(int16))) == NULL)
 	      {
-		(void) fprintf(stderr, alloc_err);
+		(void) fprintf(stderr, "%s", alloc_err);
 		return FAIL;
 	      }
 	    break;
 	case 4: /* 8-bit integer */
 	    if ((*data = (VOIDP) HDmalloc((size_t) len * sizeof(int8))) == NULL)
 	      {
-		(void) fprintf(stderr, alloc_err);
+		(void) fprintf(stderr, "%s", alloc_err);
 		return FAIL;
 	      }
 	    break;
@@ -2897,7 +2897,7 @@ write_SDS(int32 sds_id, struct Input *in)
 	start[1] = 0;
 	if (SDwritedata(sds_id, start, NULL, edges, (VOIDP)in->data) != 0)
 	  {
-	    (void) fprintf(stderr, write_err);
+	    (void) fprintf(stderr, "%s", write_err);
 	    return FAIL;
 	  }
       }
@@ -2912,7 +2912,7 @@ write_SDS(int32 sds_id, struct Input *in)
 	start[2] = 0;
 	if (SDwritedata(sds_id, start, NULL, edges, (VOIDP)in->data) != 0)
 	  {
-	    (void) fprintf(stderr, write_err);
+	    (void) fprintf(stderr, "%s", write_err);
 	    return FAIL;
 	  }
       }
@@ -3037,15 +3037,15 @@ process(struct Options *opt)
 #endif /* DEBUG */
 
     const char *err1 = "Error creating HDF output file: %s.\n";
-    const char *err1a = "Error opening the created HDF output file for writing.\n";
+    const char *err1a = "Error opening the created HDF output file for writing, file %s.\n";
     const char *err2 = "Unable to dynamically allocate memory.\n";
     const char *err3a = "Warning: cannot make image smaller using -e ";
     const char *err3b = "option.\n\t %s resolution will be made the ";
     const char *err3c = "same as %s dimension of the\n\t dataset, ";
     const char *err3d = "which is: %d.\n\n";
     const char *err4 = "Unable to write an RIS8 to the HDF output file\n";
-    const char *err5 = "err5 - Unable to write an SDS to the HDF output file\n";
-    const char *err5a = "err5aaaa - Unable to write an SDS to the HDF output file\n";
+    const char *err5 = "Unable to write an SDS to the HDF output file\n";
+    const char *err5a = "Unable to set range to an SDS\n";
     const char *err6a = "Unable to close the SDS\n";
     const char *err6 = "Unable to close the HDF output file\n";
     /*
@@ -3159,7 +3159,7 @@ process(struct Options *opt)
 			/* set range */
 			if (SDsetrange(sds_id, &in.max, &in.min)!=0)
 			  {
-			    (void) fprintf(stderr, err5a);
+			    (void) fprintf(stderr, "%s", err5a);
 			    goto err;
 			  }	
 		    
@@ -3187,7 +3187,7 @@ process(struct Options *opt)
 			/* set range */
 			if (SDsetrange(sds_id, &in.fp64s.max, &in.fp64s.min)!=0)
 			  {
-			    (void) fprintf(stderr, err5a);
+			    (void) fprintf(stderr, "%s", err5a);
 			    goto err;
 			  }	
 		    
@@ -3216,7 +3216,7 @@ process(struct Options *opt)
 			/* set range */
 			if (SDsetrange(sds_id, &in.in32s.max, &in.in32s.min)!=0)
 			  {
-			    (void) fprintf(stderr, err5a);
+			    (void) fprintf(stderr, "%s", err5a);
 			    goto err;
 			  }	
 		    
@@ -3244,7 +3244,7 @@ process(struct Options *opt)
 			/* set range */
 			if (SDsetrange(sds_id, &in.in16s.max, &in.in16s.min)!=0)
 			  {
-			    (void) fprintf(stderr, err5a);
+			    (void) fprintf(stderr, "%s", err5a);
 			    goto err;
 			  }	
 		    
@@ -3272,7 +3272,7 @@ process(struct Options *opt)
 			/* set range */
 			if (SDsetrange(sds_id, &in.in8s.max, &in.in8s.min)!=0)
 			  {
-			    (void) fprintf(stderr, err5a);
+			    (void) fprintf(stderr, "%s", err5a);
 			    goto err;
 			  }	
 		    
@@ -3292,7 +3292,7 @@ process(struct Options *opt)
 	    /* close data set */
 	    if (SDendaccess(sds_id) == FAIL )
 	      {
-		(void) fprintf(stderr, err6a);
+		(void) fprintf(stderr, "%s", err6a);
 		goto err;
 	      }
 
@@ -3301,7 +3301,7 @@ process(struct Options *opt)
 	      {
 		if (SDend(opt->infiles[i].handle) == FAIL)
 		{
-		    (void) fprintf(stderr, "SDend handle");
+		    (void) fprintf(stderr, "SDend failed");
 		    goto err;
 	        }
 	      }
@@ -3318,7 +3318,7 @@ process(struct Options *opt)
                 im.hres = (opt->hres == 0) ? in.dims[0] : opt->hres;
                 if ((im.hres < in.dims[0]) && (opt->ctm == EXPAND))
                   {
-                      (void) fprintf(stderr, err3a);
+                      (void) fprintf(stderr, "%s", err3a);
                       (void) fprintf(stderr, err3b, "Horiz.");
                       (void) fprintf(stderr, err3c, "horiz.");
                       (void) fprintf(stderr, err3d, in.dims[0]);
@@ -3328,7 +3328,7 @@ process(struct Options *opt)
                 im.vres = (opt->vres == 0) ? in.dims[1] : opt->vres;
                 if ((im.vres < in.dims[1]) && (opt->ctm == EXPAND))
                   {
-                      (void) fprintf(stderr, err3a);
+                      (void) fprintf(stderr, "%s", err3a);
                       (void) fprintf(stderr, err3b, "Vert.");
                       (void) fprintf(stderr, err3c, "vert.");
                       (void) fprintf(stderr, err3d, in.dims[1]);
@@ -3343,11 +3343,10 @@ process(struct Options *opt)
                       if ((im.dres < in.dims[2]) &&
                           (opt->ctm == EXPAND))
                         {
-                            (void) fprintf(stderr, err3a);
+                            (void) fprintf(stderr, "%s", err3a);
                             (void) fprintf(stderr, err3b, "Depth");
                             (void) fprintf(stderr, err3c, "depth");
-                            (void) fprintf(stderr, err3d,
-                                           in.dims[2]);
+                            (void) fprintf(stderr, err3d, in.dims[2]);
                             im.dres = in.dims[2];
                             opt->dres = in.dims[2];
                         }
@@ -3355,7 +3354,7 @@ process(struct Options *opt)
                 len = im.hres * im.vres * im.dres;
                 if ((im.image = (unsigned char *) HDmalloc((unsigned int) len)) == NULL)
                   {
-                      (void) fprintf(stderr, err2);
+                      (void) fprintf(stderr, "%s", err2);
                       goto err;
                   }
 
@@ -3385,7 +3384,7 @@ process(struct Options *opt)
                       if (DFR8addimage(opt->outfile, ip, im.hres,
                                        im.vres, DFTAG_RLE))
                         {
-                            (void) fprintf(stderr, err4);
+                            (void) fprintf(stderr, "%s", err4);
                             goto err;
                         }
                   }
@@ -3426,7 +3425,7 @@ process(struct Options *opt)
     /* close the output file */
     if (SDend (sd_id) != 0)
       {
-	(void) fprintf(stderr, err6);
+	(void) fprintf(stderr, "%s", err6);
 	goto err;
       }
 	
@@ -3515,13 +3514,13 @@ static int init_scales(struct Input * in)
       if ((in->hscale = (float32 *) HDmalloc((size_t)
 					     (in->dims[0] + 1) * sizeof(float32))) == NULL)
 	{
-	  (void) fprintf(stderr, err1);
+	  (void) fprintf(stderr, "%s", err1);
 	  goto err;
 	}
       if ((in->vscale = (float32 *) HDmalloc((size_t)
 					     (in->dims[1] + 1) * sizeof(float32))) == NULL)
 	{
-	  (void) fprintf(stderr, err1);
+	  (void) fprintf(stderr, "%s", err1);
 	  goto err;
 	}
       if (in->rank == 3)
@@ -3529,7 +3528,7 @@ static int init_scales(struct Input * in)
 	  if ((in->dscale = (float32 *) HDmalloc((size_t)
 						 (in->dims[2] + 1) * sizeof(float32))) == NULL)
 	    {
-	      (void) fprintf(stderr, err1);
+	      (void) fprintf(stderr, "%s", err1);
 	      goto err;
 	    }
 	}
@@ -3540,13 +3539,13 @@ static int init_scales(struct Input * in)
       if ((in->fp64s.hscale = (float64 *) HDmalloc((size_t)
 						   (in->dims[0] + 1) * sizeof(float64))) == NULL)
 	{
-	    (void) fprintf(stderr, err1);
+	    (void) fprintf(stderr, "%s", err1);
 	    goto err;
 	}
       if ((in->fp64s.vscale = (float64 *) HDmalloc((size_t)
 						   (in->dims[1] + 1) * sizeof(float64))) == NULL)
 	{
-	  (void) fprintf(stderr, err1);
+	  (void) fprintf(stderr, "%s", err1);
 	  goto err;
 	}
       if (in->rank == 3)
@@ -3554,7 +3553,7 @@ static int init_scales(struct Input * in)
 	  if ((in->fp64s.dscale = (float64 *) HDmalloc((size_t)
 						  (in->dims[2] + 1) * sizeof(float64))) == NULL)
 	    {
-	      (void) fprintf(stderr, err1);
+	      (void) fprintf(stderr, "%s", err1);
 	      goto err;
 	    }
 	}
@@ -3563,13 +3562,13 @@ static int init_scales(struct Input * in)
       if ((in->in32s.hscale = (int32 *) HDmalloc((size_t)
 						 (in->dims[0] + 1) * sizeof(int32))) == NULL)
 	{
-	  (void) fprintf(stderr, err1);
+	  (void) fprintf(stderr, "%s", err1);
 	  goto err;
 	}
       if ((in->in32s.vscale = (int32 *) HDmalloc((size_t)
 						 (in->dims[1] + 1) * sizeof(int32))) == NULL)
 	{
-	  (void) fprintf(stderr, err1);
+	  (void) fprintf(stderr, "%s", err1);
 	  goto err;
 	}
       if (in->rank == 3)
@@ -3577,7 +3576,7 @@ static int init_scales(struct Input * in)
 	  if ((in->in32s.dscale = (int32 *) HDmalloc((size_t)
                              (in->dims[2] + 1) * sizeof(int32))) == NULL)
 	    {
-	      (void) fprintf(stderr, err1);
+	      (void) fprintf(stderr, "%s", err1);
 	      goto err;
 	    }
 	}
@@ -3587,13 +3586,13 @@ static int init_scales(struct Input * in)
       if ((in->in16s.hscale = (int16 *) HDmalloc((size_t)
 						 (in->dims[0] + 1) * sizeof(int16))) == NULL)
 	{
-	  (void) fprintf(stderr, err1);
+	  (void) fprintf(stderr, "%s", err1);
 	  goto err;
 	}
       if ((in->in16s.vscale = (int16 *) HDmalloc((size_t)
 						 (in->dims[1] + 1) * sizeof(int16))) == NULL)
 	{
-	  (void) fprintf(stderr, err1);
+	  (void) fprintf(stderr, "%s", err1);
 	  goto err;
 	}
       if (in->rank == 3)
@@ -3601,7 +3600,7 @@ static int init_scales(struct Input * in)
 	  if ((in->in16s.dscale = (int16 *) HDmalloc((size_t)
 						     (in->dims[2] + 1) * sizeof(int16))) == NULL)
 	    {
-	      (void) fprintf(stderr, err1);
+	      (void) fprintf(stderr, "%s", err1);
 	      goto err;
 	    }
 	}
@@ -3611,13 +3610,13 @@ static int init_scales(struct Input * in)
       if ((in->in8s.hscale = (int8 *) HDmalloc((size_t)
 					       (in->dims[0] + 1) * sizeof(int8))) == NULL)
 	{
-	  (void) fprintf(stderr, err1);
+	  (void) fprintf(stderr, "%s", err1);
 	  goto err;
 	}
       if ((in->in8s.vscale = (int8 *) HDmalloc((size_t)
                              (in->dims[1] + 1) * sizeof(int8))) == NULL)
 	{
-	  (void) fprintf(stderr, err1);
+	  (void) fprintf(stderr, "%s", err1);
 	  goto err;
 	}
       if (in->rank == 3)
@@ -3625,7 +3624,7 @@ static int init_scales(struct Input * in)
 	  if ((in->in8s.dscale = (int8 *) HDmalloc((size_t)
 						   (in->dims[2] + 1) * sizeof(int8))) == NULL)
 	    {
-	      (void) fprintf(stderr, err1);
+	      (void) fprintf(stderr, "%s", err1);
 	      goto err;
 	    }
 	}
@@ -3684,27 +3683,4 @@ usage(char *name)
     (void) fprintf(stderr, "around\n");
     (void) fprintf(stderr, "\t-f[loat]:\n");
     (void) fprintf(stderr, "\t\tproduce floating point data\n\n");
-
-    return;
 }
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/mfhdf/hdfimport/testutil.sh.in b/mfhdf/hdfimport/testutil.sh.in
old mode 100755
new mode 100644
diff --git a/mfhdf/hdiff/CMakeLists.txt b/mfhdf/hdiff/CMakeLists.txt
index 04a64e4..009b2dd 100644
--- a/mfhdf/hdiff/CMakeLists.txt
+++ b/mfhdf/hdiff/CMakeLists.txt
@@ -4,18 +4,18 @@ PROJECT (HDF4_MFHDF_HDIFF)
 INCLUDE_DIRECTORIES (${HDF4_HDFSOURCE_DIR})
 INCLUDE_DIRECTORIES (${HDF4_MFHDFSOURCE_DIR})
 
-IF (WIN32 AND NOT CYGWIN)
-  SET (CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} /NODEFAULTLIB:LIBCMT")
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  set (CMAKE_EXE_LINKER_FLAGS_DEBUG "${CMAKE_EXE_LINKER_FLAGS_DEBUG} /NODEFAULTLIB:LIBCMT")
+endif (WIN32)
 
-IF (HDF4_BUILD_XDR_LIB)
-  IF (WIN32 AND NOT CYGWIN)
-    ADD_DEFINITIONS (-DNO_SYS_XDR_INC)
-  ENDIF (WIN32 AND NOT CYGWIN)
+if (HDF4_BUILD_XDR_LIB)
+  if (WIN32)
+    add_definitions (-DNO_SYS_XDR_INC)
+  endif (WIN32)
   INCLUDE_DIRECTORIES (${HDF4_MFHDF_XDR_DIR})
-ENDIF (HDF4_BUILD_XDR_LIB)
+endif (HDF4_BUILD_XDR_LIB)
 
-SET (hdiff_SRCS
+set (hdiff_SRCS
     ${HDF4_MFHDF_HDIFF_SOURCE_DIR}/hdiff.c
     ${HDF4_MFHDF_HDIFF_SOURCE_DIR}/hdiff_array.c
     ${HDF4_MFHDF_HDIFF_SOURCE_DIR}/hdiff_gr.c
@@ -33,16 +33,16 @@ SET (hdiff_SRCS
   
 ADD_EXECUTABLE(hdiff ${hdiff_SRCS})
 TARGET_C_PROPERTIES (hdiff " " " ")
-IF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
   TARGET_LINK_LIBRARIES(hdiff ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-ELSE (HDF4_BUILD_XDR_LIB)
+else (HDF4_BUILD_XDR_LIB)
   TARGET_LINK_LIBRARIES(hdiff ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDIF (HDF4_BUILD_XDR_LIB)
+endif (HDF4_BUILD_XDR_LIB)
 TARGET_NAMING (hdiff ${LIB_TYPE})
 
-IF (BUILD_TESTING)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING)
+if (BUILD_TESTING)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING)
 
 ##############################################################################
 ##############################################################################
diff --git a/mfhdf/hdiff/CMakeTests.cmake b/mfhdf/hdiff/CMakeTests.cmake
index 64d1271..283cf06 100644
--- a/mfhdf/hdiff/CMakeTests.cmake
+++ b/mfhdf/hdiff/CMakeTests.cmake
@@ -9,22 +9,22 @@
   # This executable is used to generate test files for the hdiff tests.
   # It should only be run during development when new test files are needed
   # --------------------------------------------------------------------
-  IF (HDF4_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS)
-    SET (hdifftst_SRCS
+  if (HDF4_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS)
+    set (hdifftst_SRCS
         ${HDF4_MFHDF_HDIFF_SOURCE_DIR}/hdifftst.c
     )
   
     ADD_EXECUTABLE (hdifftst ${hdifftst_SRCS})
     TARGET_C_PROPERTIES (hdifftst " " " ")
-    IF (HDF4_BUILD_XDR_LIB)
-      TARGET_LINK_LIBRARIES (hdifftst ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-    ELSE (HDF4_BUILD_XDR_LIB)
-      TARGET_LINK_LIBRARIES (hdifftst ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-    ENDIF (HDF4_BUILD_XDR_LIB)
+    if (HDF4_BUILD_XDR_LIB)
+      target_link_libraries (hdifftst ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+    else (HDF4_BUILD_XDR_LIB)
+      target_link_libraries (hdifftst ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+    endif (HDF4_BUILD_XDR_LIB)
     TARGET_NAMING (hdifftst ${LIB_TYPE})
 
     # Remove any output file left over from previous test run
-    ADD_TEST (
+    add_test (
         NAME HDIFF-GEN-clearall-objects
         COMMAND    ${CMAKE_COMMAND}
             -E remove 
@@ -36,23 +36,23 @@
             hdifftst6.hdf
             hdifftst7.hdf
     )
-    SET (last_test "HDIFF-GEN-clearall-objects")
+    set (last_test "HDIFF-GEN-clearall-objects")
     
-    ADD_TEST (NAME hdifftst COMMAND $<TARGET_FILE:hdifftst>)
-    SET_TESTS_PROPERTIES (hdifftst PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-    SET (last_test "hdifftst")
-  ENDIF (HDF4_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS)
+    add_test (NAME hdifftst COMMAND $<TARGET_FILE:hdifftst>)
+    set_tests_properties (hdifftst PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+    set (last_test "hdifftst")
+  endif (HDF4_BUILD_GENERATORS AND NOT BUILD_SHARED_LIBS)
 
   MACRO (ADD_H4_TEST resultfile resultcode)
-    IF (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (NAME HDIFF-${resultfile} COMMAND $<TARGET_FILE:hdiff> ${ARGN})
-      IF (NOT ${resultcode} STREQUAL "0")
-        SET_TESTS_PROPERTIES (HDIFF-${resultfile} PROPERTIES LABELS ${PROJECT_NAME} WILL_FAIL "true")
-      ELSE (NOT ${resultcode} STREQUAL "0")
-        SET_TESTS_PROPERTIES (HDIFF-${resultfile} PROPERTIES LABELS ${PROJECT_NAME})
-      ENDIF (NOT ${resultcode} STREQUAL "0")
-    ELSE (HDF4_ENABLE_USING_MEMCHECKER)
-      ADD_TEST (
+    if (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (NAME HDIFF-${resultfile} COMMAND $<TARGET_FILE:hdiff> ${ARGN})
+      if (NOT ${resultcode} STREQUAL "0")
+        set_tests_properties (HDIFF-${resultfile} PROPERTIES LABELS ${PROJECT_NAME} WILL_FAIL "true")
+      else (NOT ${resultcode} STREQUAL "0")
+        set_tests_properties (HDIFF-${resultfile} PROPERTIES LABELS ${PROJECT_NAME})
+      endif (NOT ${resultcode} STREQUAL "0")
+    else (HDF4_ENABLE_USING_MEMCHECKER)
+      add_test (
           NAME HDIFF-${resultfile}
           COMMAND "${CMAKE_COMMAND}"
               -D "TEST_PROGRAM=$<TARGET_FILE:hdiff>"
@@ -61,19 +61,19 @@
               -D "TEST_OUTPUT=${resultfile}.out"
               -D "TEST_EXPECT=${resultcode}"
               -D "TEST_REFERENCE=${resultfile}.txt"
-              -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+              -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
       )
-    ENDIF (HDF4_ENABLE_USING_MEMCHECKER)
-    IF (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HDIFF-${resultfile} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-    ELSE (NOT "${last_test}" STREQUAL "")
-      SET_TESTS_PROPERTIES (HDIFF-${resultfile} PROPERTIES LABELS ${PROJECT_NAME})
-    ENDIF (NOT "${last_test}" STREQUAL "")
-    SET (last_test "HDIFF-${resultfile}")
+    endif (HDF4_ENABLE_USING_MEMCHECKER)
+    if (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HDIFF-${resultfile} PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+    else (NOT "${last_test}" STREQUAL "")
+      set_tests_properties (HDIFF-${resultfile} PROPERTIES LABELS ${PROJECT_NAME})
+    endif (NOT "${last_test}" STREQUAL "")
+    set (last_test "HDIFF-${resultfile}")
   ENDMACRO (ADD_H4_TEST file)
  
   #-- Copy all the data files from the test directory into the source directory
-  SET (HDF4_REFERENCE_TEST_FILES
+  set (HDF4_REFERENCE_TEST_FILES
       hdifftst1.hdf
       hdifftst2.hdf
       hdifftst3.hdf
@@ -82,7 +82,7 @@
       hdifftst6.hdf
       hdifftst7.hdf
   )
-  SET (HDF4_REFERENCE_FILES
+  set (HDF4_REFERENCE_FILES
       hdiff_01.txt
       hdiff_02.txt
       hdiff_03.txt
@@ -100,8 +100,8 @@
       hdiff_15.txt
   )
  
-  FOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/testfiles/${h4_file}")
+  foreach (h4_file ${HDF4_REFERENCE_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/testfiles/${h4_file}")
     #MESSAGE(STATUS " Copying ${HDF4_MFHDF_HDIFF_SOURCE_DIR}/testfiles/${h4_file} to ${PROJECT_BINARY_DIR}/testfiles/")
     ADD_CUSTOM_COMMAND (
         TARGET     hdiff 
@@ -109,34 +109,34 @@
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_MFHDF_HDIFF_SOURCE_DIR}/testfiles/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
+  endforeach (h4_file ${HDF4_REFERENCE_TEST_FILES})
 
-  FOREACH (out_file ${HDF4_REFERENCE_FILES})
-    SET (outdest "${PROJECT_BINARY_DIR}/testfiles/${out_file}")
-    #MESSAGE (STATUS " Translating ${out_file}")
+  foreach (out_file ${HDF4_REFERENCE_FILES})
+    set (outdest "${PROJECT_BINARY_DIR}/testfiles/${out_file}")
+    #message (STATUS " Translating ${out_file}")
     ADD_CUSTOM_COMMAND (
         TARGET     hdiff
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_MFHDF_HDIFF_SOURCE_DIR}/testfiles/${out_file} ${outdest}
     )
-  ENDFOREACH (out_file ${HDF4_REFERENCE_FILES})
+  endforeach (out_file ${HDF4_REFERENCE_FILES})
 
-  IF (WIN32 AND NOT CYGWIN)
+  if (WIN32)
     ADD_CUSTOM_COMMAND (
         TARGET     hdiff
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_MFHDF_HDIFF_SOURCE_DIR}/testfiles/hdiff_06w.txt ${PROJECT_BINARY_DIR}/testfiles/hdiff_06.txt
     )
-  ELSE (WIN32 AND NOT CYGWIN)
+  else (WIN32)
     ADD_CUSTOM_COMMAND (
         TARGET     hdiff
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_MFHDF_HDIFF_SOURCE_DIR}/testfiles/hdiff_06.txt ${PROJECT_BINARY_DIR}/testfiles/hdiff_06.txt
     )
-  ENDIF (WIN32 AND NOT CYGWIN)
+  endif (WIN32)
 
 ##############################################################################
 ##############################################################################
@@ -144,7 +144,7 @@
 ##############################################################################
 ##############################################################################
   # Remove any output file left over from previous test run
-  ADD_TEST (
+  add_test (
       NAME HDIFF-clearall-objects
       COMMAND    ${CMAKE_COMMAND}
           -E remove 
@@ -179,12 +179,12 @@
           hdiff_14.out.err
           hdiff_15.out.err
   )
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (HDIFF-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (HDIFF-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "HDIFF-clearall-objects")
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (HDIFF-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (HDIFF-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "HDIFF-clearall-objects")
 
   # help message
   ADD_H4_TEST (hdiff_01 1) 
diff --git a/mfhdf/hdiff/Makefile.am b/mfhdf/hdiff/Makefile.am
index 82e4e30..7be8f50 100644
--- a/mfhdf/hdiff/Makefile.am
+++ b/mfhdf/hdiff/Makefile.am
@@ -5,11 +5,11 @@
 include $(top_srcdir)/config/commence.am
 
 ## Setup the different includes and preprocessor #defines we need.
-INCLUDES=-I$(top_srcdir)/hdf/src        \
+hdiff_INCLUDES=-I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 DEFINES=-DNDEBUG -DHDF
-AM_CPPFLAGS=$(INCLUDES) $(DEFINES)
+AM_CPPFLAGS=$(hdiff_INCLUDES) $(DEFINES)
 
 ## Add hdiff specific linker flags here
 hdiff_LDFLAGS = $(LT_STATIC_EXEC) $(AM_LDFLAGS)
diff --git a/mfhdf/hdiff/Makefile.in b/mfhdf/hdiff/Makefile.in
index 35c3b63..15f6679 100644
--- a/mfhdf/hdiff/Makefile.in
+++ b/mfhdf/hdiff/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -18,23 +18,51 @@
 #############################################################################
 
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -53,11 +81,11 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
 	$(srcdir)/testhdiff.sh.in $(top_srcdir)/bin/depcomp \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am
+	$(top_srcdir)/bin/test-driver
 bin_PROGRAMS = hdiff$(EXEEXT)
 noinst_PROGRAMS = hdifftst$(EXEEXT)
 TESTS = $(am__EXEEXT_1) $(TEST_SCRIPT)
@@ -78,24 +106,49 @@ am_hdiff_OBJECTS = hdiff.$(OBJEXT) hdiff_array.$(OBJEXT) \
 	hdiff_misc.$(OBJEXT) hdiff_sds.$(OBJEXT) hdiff_table.$(OBJEXT) \
 	hdiff_vs.$(OBJEXT) hdiff_dim.$(OBJEXT)
 hdiff_OBJECTS = $(am_hdiff_OBJECTS)
-hdiff_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hdiff_LDFLAGS) \
-	$(LDFLAGS) -o $@
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
+hdiff_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hdiff_LDFLAGS) $(LDFLAGS) -o $@
 am_hdifftst_OBJECTS = hdifftst.$(OBJEXT)
 hdifftst_OBJECTS = $(am_hdifftst_OBJECTS)
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 SOURCES = $(hdiff_SOURCES) $(hdifftst_SOURCES)
 DIST_SOURCES = $(hdiff_SOURCES) $(hdifftst_SOURCES)
 am__can_run_installinfo = \
@@ -103,16 +156,232 @@ am__can_run_installinfo = \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+  test -z "$$files" \
+    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+         $(am__cd) "$$dir" && rm -f $$files; }; \
+  }
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
 am__EXEEXT_1 = hdifftst$(EXEEXT)
+TEST_SUITE_LOG = test-suite.log
+LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -197,6 +466,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -282,12 +552,12 @@ ACLOCAL_AMFLAGS = "-I m4"
 CHECK_CLEANFILES = *.chkexe *.chklog hdifftst1.hdf hdifftst2.hdf \
 	hdifftst3.hdf hdifftst4.hdf hdifftst5.hdf hdifftst6.hdf \
 	hdifftst7.hdf
-INCLUDES = -I$(top_srcdir)/hdf/src        \
+hdiff_INCLUDES = -I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 
 DEFINES = -DNDEBUG -DHDF
-AM_CPPFLAGS = $(INCLUDES) $(DEFINES)
+AM_CPPFLAGS = $(hdiff_INCLUDES) $(DEFINES)
 hdiff_LDFLAGS = $(LT_STATIC_EXEC) $(AM_LDFLAGS)
 hdiff_SOURCES = hdiff.c hdiff_array.c hdiff_gr.c hdiff_list.c hdiff_main.c  \
                 hdiff_mattbl.c hdiff_gattr.c hdiff_misc.c hdiff_sds.c       \
@@ -326,7 +596,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
-.SUFFIXES: .c .lo .o .obj
+.SUFFIXES: .c .lo .log .o .obj .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -369,10 +639,12 @@ install-binPROGRAMS: $(bin_PROGRAMS)
 	fi; \
 	for p in $$list; do echo "$$p $$p"; done | \
 	sed 's/$(EXEEXT)$$//' | \
-	while read p p1; do if test -f $$p || test -f $$p1; \
-	  then echo "$$p"; echo "$$p"; else :; fi; \
+	while read p p1; do if test -f $$p \
+	 || test -f $$p1 \
+	  ; then echo "$$p"; echo "$$p"; else :; fi; \
 	done | \
-	sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \
+	sed -e 'p;s,.*/,,;n;h' \
+	    -e 's|.*|.|' \
 	    -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
 	sed 'N;N;N;s,\n, ,g' | \
 	$(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
@@ -393,7 +665,8 @@ uninstall-binPROGRAMS:
 	@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
 	files=`for p in $$list; do echo "$$p"; done | \
 	  sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
-	      -e 's/$$/$(EXEEXT)/' `; \
+	      -e 's/$$/$(EXEEXT)/' \
+	`; \
 	test -n "$$list" || exit 0; \
 	echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
 	cd "$(DESTDIR)$(bindir)" && rm -f $$files
@@ -415,12 +688,14 @@ clean-noinstPROGRAMS:
 	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
 	echo " rm -f" $$list; \
 	rm -f $$list
+
 hdiff$(EXEEXT): $(hdiff_OBJECTS) $(hdiff_DEPENDENCIES) $(EXTRA_hdiff_DEPENDENCIES) 
 	@rm -f hdiff$(EXEEXT)
-	$(hdiff_LINK) $(hdiff_OBJECTS) $(hdiff_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hdiff_LINK) $(hdiff_OBJECTS) $(hdiff_LDADD) $(LIBS)
+
 hdifftst$(EXEEXT): $(hdifftst_OBJECTS) $(hdifftst_DEPENDENCIES) $(EXTRA_hdifftst_DEPENDENCIES) 
 	@rm -f hdifftst$(EXEEXT)
-	$(LINK) $(hdifftst_OBJECTS) $(hdifftst_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(hdifftst_OBJECTS) $(hdifftst_LDADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -443,25 +718,25 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdifftst.Po at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -469,26 +744,15 @@ mostlyclean-libtool:
 clean-libtool:
 	-rm -rf .libs _libs
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -500,15 +764,11 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -517,9 +777,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -535,6 +796,158 @@ cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all $(check_SCRIPTS)
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+hdifftst.log: hdifftst$(EXEEXT)
+	@p='hdifftst$(EXEEXT)'; \
+	b='hdifftst'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -594,6 +1007,9 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 
@@ -678,9 +1094,9 @@ uninstall-am: uninstall-binPROGRAMS
 
 .MAKE: check-am install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am all-local check check-TESTS check-am \
-	clean clean-binPROGRAMS clean-generic clean-libtool \
-	clean-noinstPROGRAMS cscopelist ctags distclean \
+.PHONY: CTAGS GTAGS TAGS all all-am all-local check check-TESTS \
+	check-am clean clean-binPROGRAMS clean-generic clean-libtool \
+	clean-noinstPROGRAMS cscopelist-am ctags ctags-am distclean \
 	distclean-compile distclean-generic distclean-libtool \
 	distclean-tags distdir dvi dvi-am html html-am info info-am \
 	install install-am install-binPROGRAMS install-data \
@@ -691,7 +1107,7 @@ uninstall-am: uninstall-binPROGRAMS
 	installcheck-am installdirs maintainer-clean \
 	maintainer-clean-generic mostlyclean mostlyclean-compile \
 	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
-	pdf-am ps ps-am tags uninstall uninstall-am \
+	pdf-am ps ps-am recheck tags tags-am uninstall uninstall-am \
 	uninstall-binPROGRAMS
 
 
diff --git a/mfhdf/hdiff/hdiff.h b/mfhdf/hdiff/hdiff.h
index a9ac427..cf47b1f 100644
--- a/mfhdf/hdiff/hdiff.h
+++ b/mfhdf/hdiff/hdiff.h
@@ -108,7 +108,8 @@ typedef struct {   /* selection for comparison  */
 extern "C" {
 #endif
 
-uint32  hdiff(const char *fname1, const char *fname2, diff_opt_t *opt);
+HDFTOOLSAPI uint32  hdiff(const char *fname1, const char *fname2, diff_opt_t *opt);
+HDFTOOLSAPI void    make_vars(char *optarg, diff_opt_t *opt, int option);
 
 #ifdef __cplusplus
 }
@@ -124,7 +125,6 @@ uint32  hdiff(const char *fname1, const char *fname2, diff_opt_t *opt);
 
 uint32  gattr_diff(int32 sdid1, int32 sdid2, diff_opt_t *opt);
 void    pr_att_vals(nc_type type, int len, void *vals);
-void    make_vars(char *optarg, diff_opt_t *opt, int option);
 
 
 uint32 array_diff(void *buf1, 
diff --git a/mfhdf/hdiff/testhdiff.sh.in b/mfhdf/hdiff/testhdiff.sh.in
old mode 100755
new mode 100644
diff --git a/mfhdf/hrepack/CMakeLists.txt b/mfhdf/hrepack/CMakeLists.txt
index fb24c34..fa4b4d6 100644
--- a/mfhdf/hrepack/CMakeLists.txt
+++ b/mfhdf/hrepack/CMakeLists.txt
@@ -5,20 +5,20 @@ INCLUDE_DIRECTORIES (${HDF4_HDFSOURCE_DIR})
 INCLUDE_DIRECTORIES (${HDF4_MFHDFSOURCE_DIR})
 INCLUDE_DIRECTORIES (${HDF4_SOURCE_DIR}/mfhdf/hdiff)
 
-ADD_DEFINITIONS (-DHDF)
+add_definitions (-DHDF)
 
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS)
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  add_definitions (-DDOS_FS)
+endif (WIN32)
 
-IF (HDF4_BUILD_XDR_LIB)
-  IF (WIN32 AND NOT CYGWIN)
-    ADD_DEFINITIONS (-DNO_SYS_XDR_INC)
-  ENDIF (WIN32 AND NOT CYGWIN)
+if (HDF4_BUILD_XDR_LIB)
+  if (WIN32)
+    add_definitions (-DNO_SYS_XDR_INC)
+  endif (WIN32)
   INCLUDE_DIRECTORIES (${HDF4_MFHDF_XDR_DIR})
-ENDIF (HDF4_BUILD_XDR_LIB)
+endif (HDF4_BUILD_XDR_LIB)
 
-SET (hrepack_SRCS
+set (hrepack_SRCS
     ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack.c
     ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_an.c
     ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_gr.c
@@ -36,16 +36,25 @@ SET (hrepack_SRCS
   
 ADD_EXECUTABLE (hrepack ${hrepack_SRCS})
 TARGET_C_PROPERTIES (hrepack " " " ")
-IF (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (hrepack ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-ELSE (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (hrepack ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDIF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (hrepack ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+else (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (hrepack ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endif (HDF4_BUILD_XDR_LIB)
 TARGET_NAMING (hrepack ${LIB_TYPE})
+  
+ADD_EXECUTABLE (hrepack_check ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_check.c)
+TARGET_C_PROPERTIES (hrepack_check " " " ")
+if (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (hrepack_check ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+else (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (hrepack_check ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endif (HDF4_BUILD_XDR_LIB)
+TARGET_NAMING (hrepack_check ${LIB_TYPE})
 
-IF (BUILD_TESTING)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING)
+if (BUILD_TESTING)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING)
 
 ##############################################################################
 ##############################################################################
@@ -61,7 +70,7 @@ INSTALL_PROGRAM_PDB (hrepack ${HDF4_INSTALL_TOOLS_BIN_DIR} toolsapplications)
 
 INSTALL (
     TARGETS
-        hrepack
+        hrepack hrepack_check
     RUNTIME DESTINATION
         ${HDF4_INSTALL_TOOLS_BIN_DIR}
     COMPONENT
diff --git a/mfhdf/hrepack/CMakeTests.cmake b/mfhdf/hrepack/CMakeTests.cmake
index 65d89e1..da49967 100644
--- a/mfhdf/hrepack/CMakeTests.cmake
+++ b/mfhdf/hrepack/CMakeTests.cmake
@@ -5,77 +5,65 @@
 ##############################################################################
 ##############################################################################
 
-#-- Adding test for hrepack_check
-
-  SET (hrepack_check_SRCS
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_check.c
-  )
-  
-  ADD_EXECUTABLE (hrepack_check ${hrepack_check_SRCS})
-  TARGET_C_PROPERTIES (hrepack_check " " " ")
-  IF (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (hrepack_check ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-  ELSE (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (hrepack_check ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-  ENDIF (HDF4_BUILD_XDR_LIB)
-  TARGET_NAMING (hrepack_check ${LIB_TYPE})
-
-#-- Adding test for test_hrepack
-
-  SET (test_hrepack_SRCS
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack.c
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_an.c
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_gr.c
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_list.c
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_lsttable.c
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_opttable.c
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_parse.c
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_sds.c
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_utils.c
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_vg.c
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_dim.c
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepack_vs.c
-      ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepacktst.c
-      ${HDF4_SOURCE_DIR}/mfhdf/hdiff/hdiff.c
-      ${HDF4_SOURCE_DIR}/mfhdf/hdiff/hdiff_array.c
-      ${HDF4_SOURCE_DIR}/mfhdf/hdiff/hdiff_gattr.c
-      ${HDF4_SOURCE_DIR}/mfhdf/hdiff/hdiff_gr.c
-      ${HDF4_SOURCE_DIR}/mfhdf/hdiff/hdiff_list.c
-      ${HDF4_SOURCE_DIR}/mfhdf/hdiff/hdiff_mattbl.c
-      ${HDF4_SOURCE_DIR}/mfhdf/hdiff/hdiff_misc.c
-      ${HDF4_SOURCE_DIR}/mfhdf/hdiff/hdiff_sds.c
-      ${HDF4_SOURCE_DIR}/mfhdf/hdiff/hdiff_table.c
-      ${HDF4_SOURCE_DIR}/mfhdf/hdiff/hdiff_vs.c
-      ${HDF4_SOURCE_DIR}/mfhdf/hdiff/hdiff_dim.c
-  )
-  
-  ADD_EXECUTABLE (test_hrepack ${test_hrepack_SRCS})
-  TARGET_C_PROPERTIES (test_hrepack " " " ")
-  IF (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (test_hrepack ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-  ELSE (HDF4_BUILD_XDR_LIB)
-    TARGET_LINK_LIBRARIES (test_hrepack ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-  ENDIF (HDF4_BUILD_XDR_LIB)
-  TARGET_NAMING (test_hrepack ${LIB_TYPE})
- 
 #-- Copy all the dat files from the test directory into the source directory
-  SET (HDF4_REPACK_TEST_FILES
+  set (HDF4_REPACK_TEST_FILES
+      hrepack_help.txt
+      hrepack_check_help.txt
       image24pixel.txt
       image24plane.txt
       image8.txt
       info.txt
   )
  
-  FOREACH (h4_file ${HDF4_REPACK_TEST_FILES})
-    SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-    #MESSAGE (STATUS " Copying ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/${h4_file} to ${PROJECT_BINARY_DIR}/")
+  foreach (h4_file ${HDF4_REPACK_TEST_FILES})
+    set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+    #message (STATUS " Copying ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/${h4_file} to ${PROJECT_BINARY_DIR}/")
     ADD_CUSTOM_COMMAND (
-        TARGET     test_hrepack 
+        TARGET     hrepack_check 
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/${h4_file} ${dest}
     )
-  ENDFOREACH (h4_file ${HDF4_REPACK_TEST_FILES})
+  endforeach (h4_file ${HDF4_REPACK_TEST_FILES})
+
+#-- Adding test for test_hrepack for generating testfiles
+  ADD_EXECUTABLE (test_hrepack ${HDF4_MFHDF_HREPACK_SOURCE_DIR}/hrepacktst.c)
+  TARGET_C_PROPERTIES (test_hrepack " " " ")
+  if (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (test_hrepack ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+  else (HDF4_BUILD_XDR_LIB)
+    target_link_libraries (test_hrepack ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+  endif (HDF4_BUILD_XDR_LIB)
+  TARGET_NAMING (test_hrepack ${LIB_TYPE})
+
+  MACRO (ADD_H4_TEST testname testtype testfile)
+    if (${testtype} STREQUAL "SKIP")
+      if (NOT HDF4_ENABLE_USING_MEMCHECKER)
+        add_test (
+            NAME HREPACK-${testname}-SKIPPED
+            COMMAND ${CMAKE_COMMAND} -E echo "SKIP  -v -i ${PROJECT_BINARY_DIR}/${testfile} -o ${PROJECT_BINARY_DIR}/out-${testname}.${testfile} ${ARGN}"
+        )
+      endif (NOT HDF4_ENABLE_USING_MEMCHECKER)
+    else (${testtype} STREQUAL "SKIP")
+      add_test (
+          NAME HREPACK-${testname}-clearall-objects
+          COMMAND    ${CMAKE_COMMAND}
+              -E remove 
+              out-${testname}.${testfile}
+      )
+      set_tests_properties (HREPACK-${testname}-clearall-objects PROPERTIES DEPENDS HREPACK-test_hrepack LABELS ${PROJECT_NAME})
+      add_test (
+          NAME HREPACK-${testname}
+          COMMAND $<TARGET_FILE:hrepack> -v -i ${PROJECT_BINARY_DIR}/${testfile} -o ${PROJECT_BINARY_DIR}/out-${testname}.${testfile} ${ARGN}
+      )
+      set_tests_properties (HREPACK-${testname} PROPERTIES DEPENDS HREPACK-${testname}-clearall-objects LABELS ${PROJECT_NAME})
+      add_test (
+          NAME HREPACK-${testname}_DFF
+          COMMAND $<TARGET_FILE:hdiff> ${PROJECT_BINARY_DIR}/${testfile} ${PROJECT_BINARY_DIR}/out-${testname}.${testfile}
+      )
+      set_tests_properties (HREPACK-${testname}_DFF PROPERTIES DEPENDS HREPACK-${testname} LABELS ${PROJECT_NAME})
+    endif (${testtype} STREQUAL "SKIP")
+  ENDMACRO (ADD_H4_TEST)
 
 ##############################################################################
 ##############################################################################
@@ -83,19 +71,233 @@
 ##############################################################################
 ##############################################################################
   # Remove any output file left over from previous test run
-  ADD_TEST (
-      NAME hrepack-clearall-objects
+  add_test (
+      NAME HREPACK-hrepack-clearall-objects
       COMMAND    ${CMAKE_COMMAND}
           -E remove 
+          hrepack_help.out
+          hrepack_check_help.out
           hrepacktst1.hdf
-          hrepacktst1_out.hdf
           hrepacktst2.hdf
-          hrepacktst2_out.hdf
           hrepacktst3.hdf
-          hrepacktst3_out.hdf
   )
 
-#  ADD_TEST (NAME hrepack_check COMMAND $<TARGET_FILE:hrepack_check>)
-  
-  ADD_TEST (NAME test_hrepack COMMAND $<TARGET_FILE:test_hrepack>)
-  SET_TESTS_PROPERTIES (test_hrepack PROPERTIES DEPENDS hrepack-clearall-objects LABELS ${PROJECT_NAME})
+  if (NOT HDF4_ENABLE_USING_MEMCHECKER)
+    add_test (
+        NAME HREPACK-hrepack_check
+        COMMAND "${CMAKE_COMMAND}"
+            -D "TEST_PROGRAM=$<TARGET_FILE:hrepack_check>"
+            -D "TEST_ARGS:STRING=${ARGN}"
+            -D "TEST_FOLDER=${PROJECT_BINARY_DIR}"
+            -D "TEST_OUTPUT=hrepack_check_help.out"
+            -D "TEST_EXPECT=1"
+            -D "TEST_REFERENCE=hrepack_check_help.txt"
+            -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
+    )
+    set_tests_properties (HREPACK-hrepack_check PROPERTIES DEPENDS HREPACK-hrepack-clearall-objects LABELS ${PROJECT_NAME})
+  endif (NOT HDF4_ENABLE_USING_MEMCHECKER)
+
+  if (NOT HDF4_ENABLE_USING_MEMCHECKER)
+    add_test (
+        NAME HREPACK-hrepack_help
+        COMMAND "${CMAKE_COMMAND}"
+            -D "TEST_PROGRAM=$<TARGET_FILE:hrepack>"
+            -D "TEST_ARGS:STRING=${ARGN}"
+            -D "TEST_FOLDER=${PROJECT_BINARY_DIR}"
+            -D "TEST_OUTPUT=hrepack_help.out"
+            -D "TEST_EXPECT=0"
+            -D "TEST_REFERENCE=hrepack_help.txt"
+            -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
+    )
+    set_tests_properties (HREPACK-hrepack_help PROPERTIES DEPENDS HREPACK-hrepack-clearall-objects LABELS ${PROJECT_NAME})
+  endif (NOT HDF4_ENABLE_USING_MEMCHECKER)
+
+  add_test (NAME HREPACK-test_hrepack COMMAND $<TARGET_FILE:test_hrepack>)
+  set_tests_properties (HREPACK-test_hrepack PROPERTIES DEPENDS HREPACK-hrepack-clearall-objects LABELS ${PROJECT_NAME})
+      
+  set (HREPACK_FILE1 hrepacktst1.hdf)
+  set (HREPACK_FILE2 hrepacktst2.hdf)
+  set (HREPACK_FILE3 hrepacktst3.hdf)
+   #-------------------------------------------------------------------------
+   # test1:  
+   # HUFF
+   #-------------------------------------------------------------------------
+   #
+    ADD_H4_TEST (HUFF "TEST" ${HREPACK_FILE1} -t "dset7:HUFF 1" -c dset7:10x8x6)
+    
+#    if ( sds_verifiy_comp("dset7",COMP_CODE_SKPHUFF, 1) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset7",HDF_CHUNK|HDF_COMP,3,in_chunk_lengths) == -1) 
+#        goto out;
+    
+    
+   #-------------------------------------------------------------------------
+   # test2: 
+   # RLE
+   #-------------------------------------------------------------------------
+   #
+    ADD_H4_TEST(RLE "TEST" ${HREPACK_FILE1} -t dset4:RLE -c dset4:10x8)
+    
+#    if ( sds_verifiy_comp("dset4",COMP_CODE_RLE, 0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset4",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
+#        goto out;
+    
+   #-------------------------------------------------------------------------
+   # test3:  
+   # SDS SELECTED with GZIP, chunking SELECTED
+   #-------------------------------------------------------------------------
+   #
+    ADD_H4_TEST(SDSGZIP_CHUNK "TEST" ${HREPACK_FILE1} -t "dset4:GZIP 6" -c dset4:10x8)
+    
+#    if ( sds_verifiy_comp("dset4",COMP_CODE_DEFLATE, 6) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset4",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
+#        goto out;
+    
+    
+   #-------------------------------------------------------------------------
+   # test4:  
+   # SDS SELECTED with SZIP, chunking SELECTED
+   #-------------------------------------------------------------------------
+   #
+   if (H4_HAVE_SZIP_ENCODER)
+     ADD_H4_TEST(SDSSZIP_CHUNK "TEST" ${HREPACK_FILE1} -t "dset4:SZIP 8,EC" -c dset4:10x8)
+   else (H4_HAVE_SZIP_ENCODER)
+     ADD_H4_TEST(SDSSZIP_CHUNK "SKIP" ${HREPACK_FILE1} -c dset4:10x8)
+   endif (H4_HAVE_SZIP_ENCODER)
+#if defined (H4_HAVE_LIBSZ)
+#    if (SZ_encoder_enabled()) 
+#    {
+#        
+#        if ( sds_verifiy_comp("dset4",COMP_CODE_SZIP, 0) == -1) 
+#            goto out;
+#        if ( sds_verifiy_chunk("dset4",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
+#            goto out;
+    
+   #-------------------------------------------------------------------------
+   # test4:  
+   # SDS SELECTED with NONE, chunking SELECTED NONE
+   #-------------------------------------------------------------------------
+   #
+    ADD_H4_TEST(SDSNONE_CHUNKNONE "TEST" ${HREPACK_FILE1} -t dset_chunk_comp:NONE -t dset_chunk:NONE -c dset_chunk_comp:NONE -c dset_chunk:NONE)
+    
+#    if ( sds_verifiy_comp("dset_chunk_comp",COMP_CODE_NONE, 0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_comp("dset_chunk",COMP_CODE_NONE, 0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset_chunk_comp",HDF_NONE,0,0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset_chunk",HDF_NONE,0,0) == -1) 
+#        goto out;
+    
+    
+   #-------------------------------------------------------------------------
+   # test5:
+   # SDS SELECTED with all types, chunking SELECTED
+   #-------------------------------------------------------------------------
+   #
+   if (H4_HAVE_SZIP_ENCODER)
+     ADD_H4_TEST(SDS_CHUNK "TEST" ${HREPACK_FILE1} -t "dset4:GZIP 9" -t dset5:RLE -t "dset6:HUFF 2" -t "dset7:SZIP 8,EC" -c dset4:10x8 -c dset5:10x8 -c dset6:10x8)
+   else (H4_HAVE_SZIP_ENCODER)
+     ADD_H4_TEST(SDS_CHUNK "TEST" ${HREPACK_FILE1} -t "dset4:GZIP 9" -t dset5:RLE -t "dset6:HUFF 2" -c dset4:10x8 -c dset5:10x8 -c dset6:10x8)
+   endif (H4_HAVE_SZIP_ENCODER)
+    
+#    if ( sds_verifiy_comp("dset4",COMP_CODE_DEFLATE, 9) == -1) 
+#        goto out;
+#    if ( sds_verifiy_comp("dset5",COMP_CODE_RLE, 0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_comp("dset6",COMP_CODE_SKPHUFF, 2) == -1) 
+#        goto out;
+#if defined (H4_HAVE_LIBSZ)
+#    if (SZ_encoder_enabled()) {
+#        if ( sds_verifiy_comp("dset7",COMP_CODE_SZIP, 0) == -1) 
+#            goto out;
+#    }
+#endif
+#    if ( sds_verifiy_chunk("dset4",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset5",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset6",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
+#        goto out;
+    
+    
+   #-------------------------------------------------------------------------
+   # test6: 
+   # SDS SELECTED with all types, no chunking
+   #-------------------------------------------------------------------------
+   #
+   if (H4_HAVE_SZIP_ENCODER)
+     ADD_H4_TEST(SEL_NOCHUNK "TEST" ${HREPACK_FILE1} -t "dset4:GZIP 9" -t dset5:RLE -t "dset6:HUFF 2" -t "dset7:SZIP 4,EC")
+   else (H4_HAVE_SZIP_ENCODER)
+     ADD_H4_TEST(SEL_NOCHUNK "TEST" ${HREPACK_FILE1} -t "dset4:GZIP 9" -t dset5:RLE -t "dset6:HUFF 2")
+   endif (H4_HAVE_SZIP_ENCODER)
+    
+#    if ( sds_verifiy_comp("dset4",COMP_CODE_DEFLATE, 9) == -1) 
+#        goto out;
+#    if ( sds_verifiy_comp("dset5",COMP_CODE_RLE, 0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_comp("dset6",COMP_CODE_SKPHUFF, 2) == -1) 
+#        goto out;
+#if defined (H4_HAVE_LIBSZ)
+#    if (SZ_encoder_enabled()) {
+#        if ( sds_verifiy_comp("dset7",COMP_CODE_SZIP, 0) == -1) 
+#            goto out;
+#    }
+#endif
+    
+    
+   #-------------------------------------------------------------------------
+   # test7:  
+   # compressing SDS ALL, chunking SELECTED NONE
+   #-------------------------------------------------------------------------
+   #
+    ADD_H4_TEST(COMPALL_CHUNKNONE "TEST" ${HREPACK_FILE1} -t "*:GZIP 1" -c dset_chunk_comp:NONE -c dset_chunk:NONE)
+    
+#    if ( sds_verifiy_comp_all(COMP_CODE_DEFLATE, 1) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset_chunk_comp",HDF_NONE,0,0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset_chunk",HDF_NONE,0,0) == -1) 
+#        goto out;
+    
+   #-------------------------------------------------------------------------
+   # test8:
+   # no compressing, chunking ALL
+   #-------------------------------------------------------------------------
+   #
+    ADD_H4_TEST(NOCOMP_CHUNKALL "TEST" ${HREPACK_FILE1} -c *:10x8)
+    
+#    if ( sds_verifiy_chunk_all(HDF_CHUNK,2,in_chunk_lengths,"dset7") == -1) 
+#        goto out;
+    
+    
+   #-------------------------------------------------------------------------
+   # test9: 
+   # compressing SDS ALL with GZIP
+   #-------------------------------------------------------------------------
+   #
+    ADD_H4_TEST(GZIP "TEST" ${HREPACK_FILE1} -t "*:GZIP 1")
+    
+#    if ( sds_verifiy_comp_all(COMP_CODE_DEFLATE, 1) == -1) 
+#        goto out;
+    
+    
+   #-------------------------------------------------------------------------
+   # test10: 
+   # repack a big file using hyperslab reading/writing
+   #-------------------------------------------------------------------------
+   #
+    ADD_H4_TEST(HYPERSLAB "TEST" ${HREPACK_FILE2})
+    
+   #-------------------------------------------------------------------------
+   # test11: 
+   # repack a file with vgroups
+   #-------------------------------------------------------------------------
+   #
+    ADD_H4_TEST(VGROUP "TEST" ${HREPACK_FILE3})
+    
+#    if (vg_verifygrpdep(HREPACK_FILE3,HREPACK_FILE3_OUT) != 0 )
+#        goto out;
+  
\ No newline at end of file
diff --git a/mfhdf/hrepack/Makefile.am b/mfhdf/hrepack/Makefile.am
index a43494f..1e5ef56 100644
--- a/mfhdf/hrepack/Makefile.am
+++ b/mfhdf/hrepack/Makefile.am
@@ -5,12 +5,12 @@
 include $(top_srcdir)/config/commence.am
 
 ## Setup the different includes and preprocessor #defines we need.
-INCLUDES=-I$(top_srcdir)/hdf/src        \
+hrepack_INCLUDES=-I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/hdiff    \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 DEFINES=-DNDEBUG -DHDF
-AM_CPPFLAGS=$(INCLUDES) $(DEFINES)
+AM_CPPFLAGS=$(hrepack_INCLUDES) $(DEFINES)
 
 ## Add hrepack specific linker flags here
 hrepack_LDFLAGS = $(LT_STATIC_EXEC) $(AM_LDFLAGS)
@@ -32,22 +32,13 @@ hrepack_DEPENDENCIES = $(LIBMFHDF) $(LIBHDF)
 #############################################################################
 ##                   Testing -- Here there be dragons.                     ##
 #############################################################################
+TEST_SCRIPT=hrepack.sh
+TEST_PROG=test_hrepack
 
+check_SCRIPTS=hrepack.sh
 check_PROGRAMS = hrepack_check test_hrepack
-TEST_PROG = test_hrepack
 
-test_hrepack_SOURCES = hrepack.c hrepack_an.c hrepack_gr.c                  \
-                       hrepack_list.c hrepack_lsttable.c hrepack_opttable.c \
-                       hrepack_parse.c hrepack_sds.c                        \
-                       hrepack_utils.c hrepack_vg.c                         \
-                       hrepack_dim.c                                        \
-                       hrepack_vs.c  hrepacktst.c                           \
-                       $(top_srcdir)/mfhdf/hdiff/hdiff.c                                     \
-                       $(top_srcdir)/mfhdf/hdiff/hdiff_array.c $(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c        \
-                       $(top_srcdir)/mfhdf/hdiff/hdiff_gr.c $(top_srcdir)/mfhdf/hdiff/hdiff_list.c            \
-                       $(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c $(top_srcdir)/mfhdf/hdiff/hdiff_misc.c        \
-                       $(top_srcdir)/mfhdf/hdiff/hdiff_sds.c $(top_srcdir)/mfhdf/hdiff/hdiff_table.c          \
-                       $(top_srcdir)/mfhdf/hdiff/hdiff_vs.c $(top_srcdir)/mfhdf/hdiff/hdiff_dim.c
+test_hrepack_SOURCES = hrepacktst.c
 test_hrepack_LDADD = $(LIBMFHDF) $(LIBHDF) -lm
 test_hrepack_DEPENDENCIES = $(LIBMFHDF) $(LIBHDF)
 
@@ -55,12 +46,15 @@ hrepack_check_SOURCES = hrepack_check.c
 hrepack_check_LDADD = $(LIBMFHDF) $(LIBHDF)
 hrepack_check_DEPENDENCIES = $(LIBMFHDF) $(LIBHDF)
 
+# The hrepack.sh script needs test_hrepack to run first.
+hrepack.sh.chkexe_: test_hrepack.chkexe_
+
 #############################################################################
 ##                          And the cleanup                                ##
 #############################################################################
 
 CHECK_CLEANFILES += *.hdf
 
-DISTCLEANFILES =
+DISTCLEANFILES = hrepack.sh
 
 include $(top_srcdir)/config/conclude.am
diff --git a/mfhdf/hrepack/Makefile.in b/mfhdf/hrepack/Makefile.in
index d5d7685..d174cca 100644
--- a/mfhdf/hrepack/Makefile.in
+++ b/mfhdf/hrepack/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -18,23 +18,51 @@
 #############################################################################
 
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -53,14 +81,14 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
-	$(srcdir)/hrepack_all.sh.in $(top_srcdir)/bin/depcomp \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
+	$(srcdir)/hrepack.sh.in $(srcdir)/hrepack_all.sh.in \
+	$(top_srcdir)/bin/depcomp $(top_srcdir)/bin/test-driver
 bin_PROGRAMS = hrepack$(EXEEXT)
 check_PROGRAMS = hrepack_check$(EXEEXT) test_hrepack$(EXEEXT)
-TESTS = $(am__EXEEXT_1)
+TESTS = $(am__EXEEXT_1) $(TEST_SCRIPT)
 subdir = mfhdf/hrepack
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 am__aclocal_m4_deps = $(top_srcdir)/configure.ac
@@ -68,7 +96,7 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
 	$(ACLOCAL_M4)
 mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs
 CONFIG_HEADER = $(top_builddir)/hdf/src/h4config.h
-CONFIG_CLEAN_FILES = hrepack_all.sh
+CONFIG_CLEAN_FILES = hrepack.sh hrepack_all.sh
 CONFIG_CLEAN_VPATH_FILES =
 am__installdirs = "$(DESTDIR)$(bindir)"
 PROGRAMS = $(bin_PROGRAMS)
@@ -80,36 +108,51 @@ am_hrepack_OBJECTS = hrepack.$(OBJEXT) hrepack_an.$(OBJEXT) \
 	hrepack_vg.$(OBJEXT) hrepack_vs.$(OBJEXT) \
 	hrepack_dim.$(OBJEXT)
 hrepack_OBJECTS = $(am_hrepack_OBJECTS)
-hrepack_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(hrepack_LDFLAGS) \
-	$(LDFLAGS) -o $@
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
+hrepack_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(hrepack_LDFLAGS) $(LDFLAGS) -o $@
 am_hrepack_check_OBJECTS = hrepack_check.$(OBJEXT)
 hrepack_check_OBJECTS = $(am_hrepack_check_OBJECTS)
-am_test_hrepack_OBJECTS = hrepack.$(OBJEXT) hrepack_an.$(OBJEXT) \
-	hrepack_gr.$(OBJEXT) hrepack_list.$(OBJEXT) \
-	hrepack_lsttable.$(OBJEXT) hrepack_opttable.$(OBJEXT) \
-	hrepack_parse.$(OBJEXT) hrepack_sds.$(OBJEXT) \
-	hrepack_utils.$(OBJEXT) hrepack_vg.$(OBJEXT) \
-	hrepack_dim.$(OBJEXT) hrepack_vs.$(OBJEXT) \
-	hrepacktst.$(OBJEXT) hdiff.$(OBJEXT) hdiff_array.$(OBJEXT) \
-	hdiff_gattr.$(OBJEXT) hdiff_gr.$(OBJEXT) hdiff_list.$(OBJEXT) \
-	hdiff_mattbl.$(OBJEXT) hdiff_misc.$(OBJEXT) \
-	hdiff_sds.$(OBJEXT) hdiff_table.$(OBJEXT) hdiff_vs.$(OBJEXT) \
-	hdiff_dim.$(OBJEXT)
+am_test_hrepack_OBJECTS = hrepacktst.$(OBJEXT)
 test_hrepack_OBJECTS = $(am_test_hrepack_OBJECTS)
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 SOURCES = $(hrepack_SOURCES) $(hrepack_check_SOURCES) \
 	$(test_hrepack_SOURCES)
 DIST_SOURCES = $(hrepack_SOURCES) $(hrepack_check_SOURCES) \
@@ -119,16 +162,232 @@ am__can_run_installinfo = \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+  test -z "$$files" \
+    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+         $(am__cd) "$$dir" && rm -f $$files; }; \
+  }
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
 am__EXEEXT_1 = test_hrepack$(EXEEXT)
+TEST_SUITE_LOG = test-suite.log
+LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -213,6 +472,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -296,13 +556,13 @@ ACLOCAL_AMFLAGS = "-I m4"
 #############################################################################
 #############################################################################
 CHECK_CLEANFILES = *.chkexe *.chklog *.hdf
-INCLUDES = -I$(top_srcdir)/hdf/src        \
+hrepack_INCLUDES = -I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/hdiff    \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 
 DEFINES = -DNDEBUG -DHDF
-AM_CPPFLAGS = $(INCLUDES) $(DEFINES)
+AM_CPPFLAGS = $(hrepack_INCLUDES) $(DEFINES)
 hrepack_LDFLAGS = $(LT_STATIC_EXEC) $(AM_LDFLAGS)
 hrepack_SOURCES = hrepack.c hrepack_an.c hrepack_gr.c                       \
                   hrepack_list.c hrepack_lsttable.c hrepack_main.c          \
@@ -312,26 +572,19 @@ hrepack_SOURCES = hrepack.c hrepack_an.c hrepack_gr.c                       \
 
 hrepack_LDADD = $(LIBMFHDF) $(LIBHDF)
 hrepack_DEPENDENCIES = $(LIBMFHDF) $(LIBHDF)
-TEST_PROG = test_hrepack
-test_hrepack_SOURCES = hrepack.c hrepack_an.c hrepack_gr.c                  \
-                       hrepack_list.c hrepack_lsttable.c hrepack_opttable.c \
-                       hrepack_parse.c hrepack_sds.c                        \
-                       hrepack_utils.c hrepack_vg.c                         \
-                       hrepack_dim.c                                        \
-                       hrepack_vs.c  hrepacktst.c                           \
-                       $(top_srcdir)/mfhdf/hdiff/hdiff.c                                     \
-                       $(top_srcdir)/mfhdf/hdiff/hdiff_array.c $(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c        \
-                       $(top_srcdir)/mfhdf/hdiff/hdiff_gr.c $(top_srcdir)/mfhdf/hdiff/hdiff_list.c            \
-                       $(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c $(top_srcdir)/mfhdf/hdiff/hdiff_misc.c        \
-                       $(top_srcdir)/mfhdf/hdiff/hdiff_sds.c $(top_srcdir)/mfhdf/hdiff/hdiff_table.c          \
-                       $(top_srcdir)/mfhdf/hdiff/hdiff_vs.c $(top_srcdir)/mfhdf/hdiff/hdiff_dim.c
 
+#############################################################################
+#############################################################################
+TEST_SCRIPT = hrepack.sh
+TEST_PROG = test_hrepack
+check_SCRIPTS = hrepack.sh
+test_hrepack_SOURCES = hrepacktst.c
 test_hrepack_LDADD = $(LIBMFHDF) $(LIBHDF) -lm
 test_hrepack_DEPENDENCIES = $(LIBMFHDF) $(LIBHDF)
 hrepack_check_SOURCES = hrepack_check.c
 hrepack_check_LDADD = $(LIBMFHDF) $(LIBHDF)
 hrepack_check_DEPENDENCIES = $(LIBMFHDF) $(LIBHDF)
-DISTCLEANFILES = 
+DISTCLEANFILES = hrepack.sh
 
 # Automake needs to be taught how to build lib, progs, and tests targets.
 # These will be filled in automatically for the most part (e.g.,
@@ -353,7 +606,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
-.SUFFIXES: .c .lo .o .obj
+.SUFFIXES: .c .lo .log .o .obj .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -385,6 +638,8 @@ $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(am__aclocal_m4_deps):
+hrepack.sh: $(top_builddir)/config.status $(srcdir)/hrepack.sh.in
+	cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
 hrepack_all.sh: $(top_builddir)/config.status $(srcdir)/hrepack_all.sh.in
 	cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
 install-binPROGRAMS: $(bin_PROGRAMS)
@@ -396,10 +651,12 @@ install-binPROGRAMS: $(bin_PROGRAMS)
 	fi; \
 	for p in $$list; do echo "$$p $$p"; done | \
 	sed 's/$(EXEEXT)$$//' | \
-	while read p p1; do if test -f $$p || test -f $$p1; \
-	  then echo "$$p"; echo "$$p"; else :; fi; \
+	while read p p1; do if test -f $$p \
+	 || test -f $$p1 \
+	  ; then echo "$$p"; echo "$$p"; else :; fi; \
 	done | \
-	sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \
+	sed -e 'p;s,.*/,,;n;h' \
+	    -e 's|.*|.|' \
 	    -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
 	sed 'N;N;N;s,\n, ,g' | \
 	$(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
@@ -420,7 +677,8 @@ uninstall-binPROGRAMS:
 	@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
 	files=`for p in $$list; do echo "$$p"; done | \
 	  sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
-	      -e 's/$$/$(EXEEXT)/' `; \
+	      -e 's/$$/$(EXEEXT)/' \
+	`; \
 	test -n "$$list" || exit 0; \
 	echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
 	cd "$(DESTDIR)$(bindir)" && rm -f $$files
@@ -442,15 +700,18 @@ clean-checkPROGRAMS:
 	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
 	echo " rm -f" $$list; \
 	rm -f $$list
+
 hrepack$(EXEEXT): $(hrepack_OBJECTS) $(hrepack_DEPENDENCIES) $(EXTRA_hrepack_DEPENDENCIES) 
 	@rm -f hrepack$(EXEEXT)
-	$(hrepack_LINK) $(hrepack_OBJECTS) $(hrepack_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(hrepack_LINK) $(hrepack_OBJECTS) $(hrepack_LDADD) $(LIBS)
+
 hrepack_check$(EXEEXT): $(hrepack_check_OBJECTS) $(hrepack_check_DEPENDENCIES) $(EXTRA_hrepack_check_DEPENDENCIES) 
 	@rm -f hrepack_check$(EXEEXT)
-	$(LINK) $(hrepack_check_OBJECTS) $(hrepack_check_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(hrepack_check_OBJECTS) $(hrepack_check_LDADD) $(LIBS)
+
 test_hrepack$(EXEEXT): $(test_hrepack_OBJECTS) $(test_hrepack_DEPENDENCIES) $(EXTRA_test_hrepack_DEPENDENCIES) 
 	@rm -f test_hrepack$(EXEEXT)
-	$(LINK) $(test_hrepack_OBJECTS) $(test_hrepack_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(test_hrepack_OBJECTS) $(test_hrepack_LDADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -458,17 +719,6 @@ mostlyclean-compile:
 distclean-compile:
 	-rm -f *.tab.c
 
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdiff.Po at am__quote@
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdiff_array.Po at am__quote@
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdiff_dim.Po at am__quote@
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdiff_gattr.Po at am__quote@
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdiff_gr.Po at am__quote@
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdiff_list.Po at am__quote@
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdiff_mattbl.Po at am__quote@
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdiff_misc.Po at am__quote@
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdiff_sds.Po at am__quote@
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdiff_table.Po at am__quote@
- at AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hdiff_vs.Po at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hrepack.Po at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hrepack_an.Po at am__quote@
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hrepack_check.Po at am__quote@
@@ -486,179 +736,25 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/hrepacktst.Po at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
-
-hdiff.o: $(top_srcdir)/mfhdf/hdiff/hdiff.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff.o -MD -MP -MF $(DEPDIR)/hdiff.Tpo -c -o hdiff.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff.Tpo $(DEPDIR)/hdiff.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff.c' object='hdiff.o' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff.c
-
-hdiff.obj: $(top_srcdir)/mfhdf/hdiff/hdiff.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff.obj -MD -MP -MF $(DEPDIR)/hdiff.Tpo -c -o hdiff.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff.c'; fi`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff.Tpo $(DEPDIR)/hdiff.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff.c' object='hdiff.obj' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff.c'; fi`
-
-hdiff_array.o: $(top_srcdir)/mfhdf/hdiff/hdiff_array.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_array.o -MD -MP -MF $(DEPDIR)/hdiff_array.Tpo -c -o hdiff_array.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_array.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_array.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_array.Tpo $(DEPDIR)/hdiff_array.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_array.c' object='hdiff_array.o' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_array.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_array.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_array.c
-
-hdiff_array.obj: $(top_srcdir)/mfhdf/hdiff/hdiff_array.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_array.obj -MD -MP -MF $(DEPDIR)/hdiff_array.Tpo -c -o hdiff_array.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_array.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_array.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_array.c'; fi`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_array.Tpo $(DEPDIR)/hdiff_array.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_array.c' object='hdiff_array.obj' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_array.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_array.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_array.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_array.c'; fi`
-
-hdiff_gattr.o: $(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_gattr.o -MD -MP -MF $(DEPDIR)/hdiff_gattr.Tpo -c -o hdiff_gattr.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_gattr.Tpo $(DEPDIR)/hdiff_gattr.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c' object='hdiff_gattr.o' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_gattr.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c
-
-hdiff_gattr.obj: $(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_gattr.obj -MD -MP -MF $(DEPDIR)/hdiff_gattr.Tpo -c -o hdiff_gattr.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c'; fi`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_gattr.Tpo $(DEPDIR)/hdiff_gattr.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c' object='hdiff_gattr.obj' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_gattr.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_gattr.c'; fi`
-
-hdiff_gr.o: $(top_srcdir)/mfhdf/hdiff/hdiff_gr.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_gr.o -MD -MP -MF $(DEPDIR)/hdiff_gr.Tpo -c -o hdiff_gr.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_gr.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_gr.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_gr.Tpo $(DEPDIR)/hdiff_gr.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_gr.c' object='hdiff_gr.o' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_gr.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_gr.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_gr.c
-
-hdiff_gr.obj: $(top_srcdir)/mfhdf/hdiff/hdiff_gr.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_gr.obj -MD -MP -MF $(DEPDIR)/hdiff_gr.Tpo -c -o hdiff_gr.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_gr.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_gr.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_gr.c'; fi`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_gr.Tpo $(DEPDIR)/hdiff_gr.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_gr.c' object='hdiff_gr.obj' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_gr.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_gr.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_gr.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_gr.c'; fi`
-
-hdiff_list.o: $(top_srcdir)/mfhdf/hdiff/hdiff_list.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_list.o -MD -MP -MF $(DEPDIR)/hdiff_list.Tpo -c -o hdiff_list.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_list.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_list.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_list.Tpo $(DEPDIR)/hdiff_list.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_list.c' object='hdiff_list.o' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_list.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_list.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_list.c
-
-hdiff_list.obj: $(top_srcdir)/mfhdf/hdiff/hdiff_list.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_list.obj -MD -MP -MF $(DEPDIR)/hdiff_list.Tpo -c -o hdiff_list.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_list.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_list.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_list.c'; fi`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_list.Tpo $(DEPDIR)/hdiff_list.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_list.c' object='hdiff_list.obj' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_list.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_list.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_list.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_list.c'; fi`
-
-hdiff_mattbl.o: $(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_mattbl.o -MD -MP -MF $(DEPDIR)/hdiff_mattbl.Tpo -c -o hdiff_mattbl.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_mattbl.Tpo $(DEPDIR)/hdiff_mattbl.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c' object='hdiff_mattbl.o' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_mattbl.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c
-
-hdiff_mattbl.obj: $(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_mattbl.obj -MD -MP -MF $(DEPDIR)/hdiff_mattbl.Tpo -c -o hdiff_mattbl.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c'; fi`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_mattbl.Tpo $(DEPDIR)/hdiff_mattbl.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c' object='hdiff_mattbl.obj' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_mattbl.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_mattbl.c'; fi`
-
-hdiff_misc.o: $(top_srcdir)/mfhdf/hdiff/hdiff_misc.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_misc.o -MD -MP -MF $(DEPDIR)/hdiff_misc.Tpo -c -o hdiff_misc.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_misc.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_misc.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_misc.Tpo $(DEPDIR)/hdiff_misc.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_misc.c' object='hdiff_misc.o' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_misc.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_misc.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_misc.c
-
-hdiff_misc.obj: $(top_srcdir)/mfhdf/hdiff/hdiff_misc.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_misc.obj -MD -MP -MF $(DEPDIR)/hdiff_misc.Tpo -c -o hdiff_misc.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_misc.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_misc.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_misc.c'; fi`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_misc.Tpo $(DEPDIR)/hdiff_misc.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_misc.c' object='hdiff_misc.obj' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_misc.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_misc.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_misc.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_misc.c'; fi`
-
-hdiff_sds.o: $(top_srcdir)/mfhdf/hdiff/hdiff_sds.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_sds.o -MD -MP -MF $(DEPDIR)/hdiff_sds.Tpo -c -o hdiff_sds.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_sds.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_sds.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_sds.Tpo $(DEPDIR)/hdiff_sds.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_sds.c' object='hdiff_sds.o' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_sds.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_sds.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_sds.c
-
-hdiff_sds.obj: $(top_srcdir)/mfhdf/hdiff/hdiff_sds.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_sds.obj -MD -MP -MF $(DEPDIR)/hdiff_sds.Tpo -c -o hdiff_sds.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_sds.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_sds.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_sds.c'; fi`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_sds.Tpo $(DEPDIR)/hdiff_sds.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_sds.c' object='hdiff_sds.obj' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_sds.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_sds.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_sds.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_sds.c'; fi`
-
-hdiff_table.o: $(top_srcdir)/mfhdf/hdiff/hdiff_table.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_table.o -MD -MP -MF $(DEPDIR)/hdiff_table.Tpo -c -o hdiff_table.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_table.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_table.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_table.Tpo $(DEPDIR)/hdiff_table.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_table.c' object='hdiff_table.o' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_table.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_table.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_table.c
-
-hdiff_table.obj: $(top_srcdir)/mfhdf/hdiff/hdiff_table.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_table.obj -MD -MP -MF $(DEPDIR)/hdiff_table.Tpo -c -o hdiff_table.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_table.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_table.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_table.c'; fi`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_table.Tpo $(DEPDIR)/hdiff_table.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_table.c' object='hdiff_table.obj' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_table.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_table.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_table.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_table.c'; fi`
-
-hdiff_vs.o: $(top_srcdir)/mfhdf/hdiff/hdiff_vs.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_vs.o -MD -MP -MF $(DEPDIR)/hdiff_vs.Tpo -c -o hdiff_vs.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_vs.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_vs.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_vs.Tpo $(DEPDIR)/hdiff_vs.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_vs.c' object='hdiff_vs.o' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_vs.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_vs.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_vs.c
-
-hdiff_vs.obj: $(top_srcdir)/mfhdf/hdiff/hdiff_vs.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_vs.obj -MD -MP -MF $(DEPDIR)/hdiff_vs.Tpo -c -o hdiff_vs.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_vs.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_vs.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_vs.c'; fi`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_vs.Tpo $(DEPDIR)/hdiff_vs.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_vs.c' object='hdiff_vs.obj' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_vs.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_vs.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_vs.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_vs.c'; fi`
-
-hdiff_dim.o: $(top_srcdir)/mfhdf/hdiff/hdiff_dim.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_dim.o -MD -MP -MF $(DEPDIR)/hdiff_dim.Tpo -c -o hdiff_dim.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_dim.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_dim.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_dim.Tpo $(DEPDIR)/hdiff_dim.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_dim.c' object='hdiff_dim.o' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_dim.o `test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_dim.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/hdiff/hdiff_dim.c
-
-hdiff_dim.obj: $(top_srcdir)/mfhdf/hdiff/hdiff_dim.c
- at am__fastdepCC_TRUE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT hdiff_dim.obj -MD -MP -MF $(DEPDIR)/hdiff_dim.Tpo -c -o hdiff_dim.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_dim.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_dim.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_dim.c'; fi`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/hdiff_dim.Tpo $(DEPDIR)/hdiff_dim.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/hdiff/hdiff_dim.c' object='hdiff_dim.obj' libtool=no @AMDEPBACKSLASH@
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o hdiff_dim.obj `if test -f '$(top_srcdir)/mfhdf/hdiff/hdiff_dim.c'; then $(CYGPATH_W) '$(top_srcdir)/mfhdf/hdiff/hdiff_dim.c'; else $(CYGPATH_W) '$(srcdir)/$(top_srcdir)/mfhdf/hdiff/hdiff_dim.c'; fi`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -666,26 +762,15 @@ mostlyclean-libtool:
 clean-libtool:
 	-rm -rf .libs _libs
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -697,15 +782,11 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -714,9 +795,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -732,6 +814,158 @@ cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all $(check_PROGRAMS) $(check_SCRIPTS)
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+test_hrepack.log: test_hrepack$(EXEEXT)
+	@p='test_hrepack$(EXEEXT)'; \
+	b='test_hrepack'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -763,7 +997,7 @@ distdir: $(DISTFILES)
 	  fi; \
 	done
 check-am: all-am
-	$(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS)
+	$(MAKE) $(AM_MAKEFLAGS) $(check_PROGRAMS) $(check_SCRIPTS)
 	$(MAKE) $(AM_MAKEFLAGS) check-TESTS
 check: check-am
 all-am: Makefile $(PROGRAMS) all-local
@@ -791,6 +1025,9 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 
@@ -875,21 +1112,25 @@ uninstall-am: uninstall-binPROGRAMS
 
 .MAKE: check-am install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am all-local check check-TESTS check-am \
-	clean clean-binPROGRAMS clean-checkPROGRAMS clean-generic \
-	clean-libtool cscopelist ctags distclean distclean-compile \
-	distclean-generic distclean-libtool distclean-tags distdir dvi \
-	dvi-am html html-am info info-am install install-am \
-	install-binPROGRAMS install-data install-data-am install-dvi \
-	install-dvi-am install-exec install-exec-am install-html \
-	install-html-am install-info install-info-am install-man \
-	install-pdf install-pdf-am install-ps install-ps-am \
-	install-strip installcheck installcheck-am installdirs \
-	maintainer-clean maintainer-clean-generic mostlyclean \
-	mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
-	mostlyclean-local pdf pdf-am ps ps-am tags uninstall \
-	uninstall-am uninstall-binPROGRAMS
-
+.PHONY: CTAGS GTAGS TAGS all all-am all-local check check-TESTS \
+	check-am clean clean-binPROGRAMS clean-checkPROGRAMS \
+	clean-generic clean-libtool cscopelist-am ctags ctags-am \
+	distclean distclean-compile distclean-generic \
+	distclean-libtool distclean-tags distdir dvi dvi-am html \
+	html-am info info-am install install-am install-binPROGRAMS \
+	install-data install-data-am install-dvi install-dvi-am \
+	install-exec install-exec-am install-html install-html-am \
+	install-info install-info-am install-man install-pdf \
+	install-pdf-am install-ps install-ps-am install-strip \
+	installcheck installcheck-am installdirs maintainer-clean \
+	maintainer-clean-generic mostlyclean mostlyclean-compile \
+	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
+	pdf-am ps ps-am recheck tags tags-am uninstall uninstall-am \
+	uninstall-binPROGRAMS
+
+
+# The hrepack.sh script needs test_hrepack to run first.
+hrepack.sh.chkexe_: test_hrepack.chkexe_
 
 # lib/progs/tests targets recurse into subdirectories. build-* targets
 # build files in this directory.
diff --git a/mfhdf/hrepack/hrepack.c b/mfhdf/hrepack/hrepack.c
index 87a0802..0726ee4 100644
--- a/mfhdf/hrepack/hrepack.c
+++ b/mfhdf/hrepack/hrepack.c
@@ -20,6 +20,7 @@
 
 
 int print_options(options_t *options);
+int list_main(const char* infname, const char* outfname, options_t *options);
 
 /*-------------------------------------------------------------------------
  * Function: hrepack
diff --git a/mfhdf/hrepack/hrepack.h b/mfhdf/hrepack/hrepack.h
index ce72da3..d05726c 100644
--- a/mfhdf/hrepack/hrepack.h
+++ b/mfhdf/hrepack/hrepack.h
@@ -76,14 +76,15 @@ typedef struct {
 extern "C" {
 #endif
 
-int  hrepack         (const char* infname, const char* outfname, options_t *options);
-int  hrepack_addcomp (const char* str, options_t *options);
-int  hrepack_addchunk(const char* str, options_t *options);
-void hrepack_init    (options_t *options, int verbose);
-void hrepack_end     (options_t *options);
-
-int  list(const char* infname,const char* outfname,options_t *options);
-int  read_info(const char *filename,options_t *options); 
+HDFTOOLSAPI int  hrepack         (const char* infname, const char* outfname, options_t *options);
+HDFTOOLSAPI int  hrepack_addcomp (const char* str, options_t *options);
+HDFTOOLSAPI int  hrepack_addchunk(const char* str, options_t *options);
+HDFTOOLSAPI void hrepack_init    (options_t *options, int verbose);
+HDFTOOLSAPI void hrepack_end     (options_t *options);
+HDFTOOLSAPI int  hrepack_main    (const char* infile, const char* outfile, options_t *options);
+
+HDFTOOLSAPI int  list(const char* infname,const char* outfname,options_t *options);
+HDFTOOLSAPI int  read_info(const char *filename,options_t *options);
 
 #ifdef __cplusplus
 }
diff --git a/mfhdf/hrepack/hrepack.sh.in b/mfhdf/hrepack/hrepack.sh.in
new file mode 100644
index 0000000..a0922f8
--- /dev/null
+++ b/mfhdf/hrepack/hrepack.sh.in
@@ -0,0 +1,357 @@
+#! /bin/sh
+#
+
+srcdir=@srcdir@
+
+
+# Determine whether the szip library is available
+USE_COMP_SZIP="@USE_COMP_SZIP@"
+SZIP_HAS_ENCODER="@SZIP_HAS_ENCODER@"
+
+TESTNAME=hrepack
+EXIT_SUCCESS=0
+EXIT_FAILURE=1
+
+HREPACK='./hrepack'               # The tool name
+HREPACK_BIN="${TESTS_ENVIRONMENT} "`pwd`/$HREPACK    # The path of the tool binary
+
+HDIFF='../hdiff/hdiff'         # The hdiff tool name 
+HDIFF_BIN="${TESTS_ENVIRONMENT} "`pwd`/$HDIFF        # The path of the hdiff tool binary
+
+HDP='../dumper/hdp'               # The dumper tool name
+HDP_BIN="${TESTS_ENVIRONMENT} "`pwd`/$HDP        # The path of the tool binary
+
+RM='rm -f'
+DIFF=diff
+CMP='cmp -s'
+nerrors=0       # number of errors (0)
+quitonerr=0     # quit on error (not)
+noclean=0       # no cleaning temp. files (yes)
+only=""         # dumper sub-command to test only
+except=""       # dumper sub-command to test not
+
+# Print a $* message left justified in a field of 70 characters
+#
+MESSAGE() {
+   SPACES="                                                               "
+   echo "$* $SPACES" | cut -c1-70 | tr -d '\012'
+}
+
+# Print a line-line message left justified in a field of 70 characters
+# beginning with the word "Testing".
+#
+TESTING() {
+    MESSAGE "Testing $*"
+}
+
+# Print a line-line message left justified in a field of 70 characters
+# beginning with the word "Verifying".
+#
+VERIFY() {
+    MESSAGE "Verifying $*"
+}
+
+# Print a message that a test has been skipped (because a required filter
+# was unavailable)
+SKIP() {
+    TESTING $HREPACK $@
+    echo " -SKIP-"
+}
+
+# Call the hdiff tool
+#
+DIFFTEST() 
+{
+    VERIFY hdiff output $@
+    (
+        $RUNSERIAL $HDIFF_BIN  "$@" 
+    )
+    RET=$?
+    if [ $RET != 0 ] ; then
+         echo "*FAILED*"
+         nerrors="`expr $nerrors + 1`"
+    else
+         echo " PASSED"
+    fi
+        
+}
+
+# Call hrepack
+#
+
+
+# call TOOLTEST_MAIN and delete $output file
+TOOLTEST() 
+{
+    infile=$2
+    outfile=out-$1.$2
+    shift
+    shift
+
+    # Run test.
+    TESTING $HREPACK $@
+    (
+        $RUNSERIAL $HREPACK_BIN -v -i $infile -o $outfile "$@"
+    )
+    RET=$?
+    if [ $RET != 0 ] ; then
+        echo "*FAILED*"
+        nerrors="`expr $nerrors + 1`"
+    else
+        echo " PASSED"
+        DIFFTEST $infile $outfile
+    fi
+    rm -f $outfile
+}
+
+# ADD_HELP_TEST
+TOOLTEST_HELP() {
+
+    expect="$1"
+    actual="`basename $1 .txt`.out"
+    actual_err="`basename $1 .txt`.err"
+    shift
+
+    # Run test.
+    TESTING $HREPACK $@
+    (
+      $RUNSERIAL $HREPACK_BIN "$@"
+    ) >$actual 2>$actual_err
+    cat $actual_err >> $actual
+
+    if [ ! -f $expect ]; then
+    # Create the expect data file if it doesn't yet exist.
+      echo " CREATED"
+      cp $actual $expect-CREATED
+    elif cmp -s $expect $actual; then
+      echo " PASSED"
+    else
+      echo "*FAILED*"
+      echo "    Expected output (*.txt) differs from actual output (*.out)"
+      nerrors="`expr $nerrors + 1`"
+    fi
+    
+    # Clean up output file
+    if test -z "$HDF_NOCLEANUP"; then
+     rm -f $actual $actual_err
+    fi
+
+}
+
+# This is different from $srcdir/../../bin/output_filter.sh
+STDOUT_FILTER() {
+    result_file=$1
+    tmp_file=/tmp/htest_tmp_$$
+    # Filter name of files.
+    cp $result_file $tmp_file
+    sed -e '/^Opening file/d' -e '/^Making file/d' \
+    < $tmp_file > $result_file
+    # cleanup
+    rm -f $tmp_file
+}
+
+#
+# The tests
+# We use the files generated by test_hrepack
+# Each run generates "<file>.out.hdf" and the tool hdiff is used to
+# compare the input and output files
+#
+# the tests are the same as the program hrepacktst, but run from the CLI 
+#
+
+##############################################################################
+###			  T H E   T E S T S                               
+##############################################################################
+# prepare for test
+
+#TOOLTEST_HELP hrepack-help.txt -h
+
+   #-------------------------------------------------------------------------
+   # test1:  
+   # HUFF
+   #-------------------------------------------------------------------------
+   #
+    TOOLTEST HUFF hrepacktst1.hdf -t "dset7:HUFF 1" -c dset7:10x8x6
+    
+#    if ( sds_verifiy_comp("dset7",COMP_CODE_SKPHUFF, 1) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset7",HDF_CHUNK|HDF_COMP,3,in_chunk_lengths) == -1) 
+#        goto out;
+    
+    
+   #-------------------------------------------------------------------------
+   # test2: 
+   # RLE
+   #-------------------------------------------------------------------------
+   #
+    TOOLTEST RLE hrepacktst1.hdf -t dset4:RLE -c dset4:10x8
+    
+#    if ( sds_verifiy_comp("dset4",COMP_CODE_RLE, 0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset4",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
+#        goto out;
+    
+   #-------------------------------------------------------------------------
+   # test3:  
+   # SDS SELECTED with GZIP, chunking SELECTED
+   #-------------------------------------------------------------------------
+   #
+    TOOLTEST SDSGZIP_CHUNK hrepacktst1.hdf -t "dset4:GZIP 6" -c dset4:10x8
+    
+#    if ( sds_verifiy_comp("dset4",COMP_CODE_DEFLATE, 6) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset4",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
+#        goto out;
+    
+    
+   #-------------------------------------------------------------------------
+   # test4:  
+   # SDS SELECTED with SZIP, chunking SELECTED
+   #-------------------------------------------------------------------------
+   #
+    if test $SZIP_HAS_ENCODER != "yes"; then
+        SKIP SDSSZIP_CHUNK hrepacktst1.hdf -c dset4:10x8
+    else
+        TOOLTEST SDSSZIP_CHUNK hrepacktst1.hdf -t "dset4:SZIP 8,EC" -c dset4:10x8
+    fi
+#if defined (H4_HAVE_LIBSZ)
+#    if (SZ_encoder_enabled()) 
+#    {
+#        
+#        if ( sds_verifiy_comp("dset4",COMP_CODE_SZIP, 0) == -1) 
+#            goto out;
+#        if ( sds_verifiy_chunk("dset4",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
+#            goto out;
+    
+   #-------------------------------------------------------------------------
+   # test4:  
+   # SDS SELECTED with NONE, chunking SELECTED NONE
+   #-------------------------------------------------------------------------
+   #
+    TOOLTEST SDSNONE_CHUNKNONE hrepacktst1.hdf -t dset_chunk_comp:NONE -t dset_chunk:NONE -c dset_chunk_comp:NONE -c dset_chunk:NONE
+    
+#    if ( sds_verifiy_comp("dset_chunk_comp",COMP_CODE_NONE, 0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_comp("dset_chunk",COMP_CODE_NONE, 0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset_chunk_comp",HDF_NONE,0,0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset_chunk",HDF_NONE,0,0) == -1) 
+#        goto out;
+    
+    
+   #-------------------------------------------------------------------------
+   # test5:
+   # SDS SELECTED with all types, chunking SELECTED
+   #-------------------------------------------------------------------------
+   #
+    if test $SZIP_HAS_ENCODER != "yes"; then
+        TOOLTEST SDS_CHUNK hrepacktst1.hdf -t "dset4:GZIP 9" -t dset5:RLE -t "dset6:HUFF 2" -c dset4:10x8 -c dset5:10x8 -c dset6:10x8
+    else
+        TOOLTEST SDS_CHUNK hrepacktst1.hdf -t "dset4:GZIP 9" -t dset5:RLE -t "dset6:HUFF 2" -t "dset7:SZIP 8,EC" -c dset4:10x8 -c dset5:10x8 -c dset6:10x8
+    fi
+    
+#    if ( sds_verifiy_comp("dset4",COMP_CODE_DEFLATE, 9) == -1) 
+#        goto out;
+#    if ( sds_verifiy_comp("dset5",COMP_CODE_RLE, 0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_comp("dset6",COMP_CODE_SKPHUFF, 2) == -1) 
+#        goto out;
+#if defined (H4_HAVE_LIBSZ)
+#    if (SZ_encoder_enabled()) {
+#        if ( sds_verifiy_comp("dset7",COMP_CODE_SZIP, 0) == -1) 
+#            goto out;
+#    }
+#endif
+#    if ( sds_verifiy_chunk("dset4",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset5",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset6",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
+#        goto out;
+    
+    
+   #-------------------------------------------------------------------------
+   # test6: 
+   # SDS SELECTED with all types, no chunking
+   #-------------------------------------------------------------------------
+   #
+    if test $SZIP_HAS_ENCODER != "yes"; then
+        TOOLTEST SEL_NOCHUNK hrepacktst1.hdf -t "dset4:GZIP 9" -t dset5:RLE -t "dset6:HUFF 2"
+    else
+        TOOLTEST SEL_NOCHUNK hrepacktst1.hdf -t "dset4:GZIP 9" -t dset5:RLE -t "dset6:HUFF 2" -t "dset7:SZIP 4,EC"
+    fi
+    
+#    if ( sds_verifiy_comp("dset4",COMP_CODE_DEFLATE, 9) == -1) 
+#        goto out;
+#    if ( sds_verifiy_comp("dset5",COMP_CODE_RLE, 0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_comp("dset6",COMP_CODE_SKPHUFF, 2) == -1) 
+#        goto out;
+#if defined (H4_HAVE_LIBSZ)
+#    if (SZ_encoder_enabled()) {
+#        if ( sds_verifiy_comp("dset7",COMP_CODE_SZIP, 0) == -1) 
+#            goto out;
+#    }
+#endif
+    
+    
+   #-------------------------------------------------------------------------
+   # test7:  
+   # compressing SDS ALL, chunking SELECTED NONE
+   #-------------------------------------------------------------------------
+   #
+    TOOLTEST COMPALL_CHUNKNONE hrepacktst1.hdf -t "*:GZIP 1" -c dset_chunk_comp:NONE -c dset_chunk:NONE
+    
+#    if ( sds_verifiy_comp_all(COMP_CODE_DEFLATE, 1) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset_chunk_comp",HDF_NONE,0,0) == -1) 
+#        goto out;
+#    if ( sds_verifiy_chunk("dset_chunk",HDF_NONE,0,0) == -1) 
+#        goto out;
+    
+   #-------------------------------------------------------------------------
+   # test8:
+   # no compressing, chunking ALL
+   #-------------------------------------------------------------------------
+   #
+    TOOLTEST NOCOMP_CHUNKALL hrepacktst1.hdf -c *:10x8
+    
+#    if ( sds_verifiy_chunk_all(HDF_CHUNK,2,in_chunk_lengths,"dset7") == -1) 
+#        goto out;
+    
+    
+   #-------------------------------------------------------------------------
+   # test9: 
+   # compressing SDS ALL with GZIP
+   #-------------------------------------------------------------------------
+   #
+    TOOLTEST GZIP hrepacktst1.hdf -t "*:GZIP 1"
+    
+#    if ( sds_verifiy_comp_all(COMP_CODE_DEFLATE, 1) == -1) 
+#        goto out;
+    
+    
+   #-------------------------------------------------------------------------
+   # test10: 
+   # repack a big file using hyperslab reading/writing
+   #-------------------------------------------------------------------------
+   #
+    TOOLTEST HYPERSLAB hrepacktst2.hdf
+    
+   #-------------------------------------------------------------------------
+   # test11: 
+   # repack a file with vgroups
+   #-------------------------------------------------------------------------
+   #
+    TOOLTEST VGROUP hrepacktst3.hdf
+
+
+if test $nerrors -eq 0 ; then
+    echo "All $TESTNAME tests passed."
+    exit $EXIT_SUCCESS
+else
+    echo "$TESTNAME tests failed with $nerrors errors."
+    exit $EXIT_FAILURE
+fi
+
diff --git a/mfhdf/hrepack/hrepack_all.sh.in b/mfhdf/hrepack/hrepack_all.sh.in
old mode 100755
new mode 100644
diff --git a/mfhdf/hrepack/hrepack_check_help.txt b/mfhdf/hrepack/hrepack_check_help.txt
new file mode 100644
index 0000000..8f80809
--- /dev/null
+++ b/mfhdf/hrepack/hrepack_check_help.txt
@@ -0,0 +1,3 @@
+hrepack_check file_name <sds_name>
+    file_name   HDF File
+    sds_name    SDS name (if no name, a list of all names is printed)
diff --git a/mfhdf/hrepack/hrepack_help.txt b/mfhdf/hrepack/hrepack_help.txt
new file mode 100644
index 0000000..58f21c1
--- /dev/null
+++ b/mfhdf/hrepack/hrepack_help.txt
@@ -0,0 +1,55 @@
+usage: hrepack -i input -o output [-V] [-h] [-v] [-t 'comp_info'] [-c 'chunk_info'] [-f cfile] [-m size]
+  -i input          input HDF File
+  -o output         output HDF File
+  [-V]              prints version of the HDF4 library and exits
+  [-h]              prints this usage
+  [-v]              verbose mode
+  [-t 'comp_info']  compression type: 'comp_info' is a string with the format
+		     <object list>:<type of compression><parameters>
+		     <object list> is a comma separated list of object names
+		        meaning apply compression only to those objects
+		        '*' means all objects
+		     <type of compression> can be:
+		       RLE, for RLE compression
+		       HUFF, for Huffman
+		       GZIP, for gzip
+		       JPEG, for JPEG (for images only)
+		       SZIP, for szip
+		       NONE, to uncompress
+		     <parameters> is optional compression info
+		       RLE, no parameter
+		       HUFF, the skip-size
+		       GZIP, the deflation level
+		       JPEG, the quality factor
+		       SZIP, pixels per block, compression mode (NN or EC)
+  [-c 'chunk_info'] apply chunking. 'chunk_info' is a string with the format
+		     <object list>:<chunk information>
+		       <object list> is a comma separated list of object names
+		         meaning apply chunking only to those objects
+		         '*' means all objects
+		       <chunk information> is the chunk size of each dimension:
+		        <dim_1 x dim_2 x ... dim_n> or
+		        NONE, to unchunk a previous chunked object
+  [-f cfile]      file with compression information -t and -c
+  [-m size]       do not compress objects smaller than size (bytes)
+
+Examples:
+
+1) hrepack -v -i file1.hdf -o file2.hdf -t '*:RLE'
+   compresses all objects in the file file1.hdf, using RLE compression
+
+2) hrepack -v -i file1.hdf -o file2.hdf -t '/group1/A,/group2/B,C:HUFF 1'
+   applies Skipping Huffman compression with skip factor of 1,
+   for objects /group1/A, /group2/B and C
+
+2) hrepack -v -i file1.hdf -o file2.hdf -t '/group1/D:RLE' -c 'D,E:10x10'
+   applies RLE compression for object /group1/D
+   applies chunking to objects D and E using a chunk size of 10 for the 2 dimensions
+
+3) hrepack -v -i file1.hdf -o file2.hdf -t 'A:NONE'
+   uncompresses object A
+
+4) hrepack -v -i file1.hdf -o file2.hdf -t 'A:SZIP 8,NN'
+   applies SZIP compression to object A, with parameters 8 and NN
+
+Note: the use of the verbose option -v is recommended
diff --git a/mfhdf/hrepack/hrepack_list.c b/mfhdf/hrepack/hrepack_list.c
index 964cdb9..6b23b81 100644
--- a/mfhdf/hrepack/hrepack_list.c
+++ b/mfhdf/hrepack/hrepack_list.c
@@ -72,6 +72,17 @@ int list_an (int32 infile_id,int32 outfile_id,options_t *options);
  *    and should not be added).  These objects belong to a root group. 
  * 4) Read all global attributes and annotations. 
  *
+ * Modification: January 15, 2015 - JIRA issue HDFFR-1428
+ *	The output file contains a vgroup of class RIG0.0 eventhough the input
+ *	file does not contain any GR elements, such as raster images or GR file
+ *	attribute.  That is because GRstart is called on the output file
+ *	regardless of whether there are any GR items in the input file.  Hrepack
+ *	will be reviewed and revised for correctness and efficiency (JIRA issue
+ *	HDFFR-1395.)  However, in this release, 4.2.11, an immediate solution is
+ *	applied to eliminate the unnecessary RIG0.0 vgroup.  The input file is
+ *	checked for GR elements, before any GR activity is invoked on the
+ *	output file. -BMR
+ *	
  *-------------------------------------------------------------------------
  */
 
@@ -88,7 +99,11 @@ int list_main(const char* infname,
                  gr_id=FAIL,      /* GR interface identifier */
                  gr_out=FAIL,     /* GR interface identifier */
                  infile_id=FAIL,
-                 outfile_id=FAIL;
+                 outfile_id=FAIL,
+		 n_rimages,       /* number of raster images in the file */
+		 n_file_attrs;    /* number of file attributes */
+    intn         has_GRelems = 0;  /* set to 1 when there are GR images or */
+                                  /* attributes in the file (HDFFR-1428) */
     int          i;
     const char*  err;
 
@@ -121,6 +136,17 @@ int list_main(const char* infname,
         printf( "Could not start GR for <%s>\n",infname);
         goto out;
     }
+
+   /*-------------------------------------------------------------------------
+    * set flag to indicate whether the input file contains any GR elements
+    *-------------------------------------------------------------------------
+    */
+    if (GRfileinfo (gr_id, &n_rimages, &n_file_attrs)==FAIL){
+        printf( "Could not get info for GR\n");
+        goto out;
+    }
+    if (n_rimages > 0 || n_file_attrs > 0)
+        has_GRelems = 1;
    
    /*-------------------------------------------------------------------------
     * create the output file and initialize interfaces
@@ -140,11 +166,12 @@ int list_main(const char* infname,
             goto out;
         }
         
-        if ((gr_out = GRstart (outfile_id))==FAIL)
-        {
-            printf( "Could not start GR for <%s>\n",outfname);
-            goto out;
-        }
+	if (has_GRelems)
+            if ((gr_out = GRstart (outfile_id))==FAIL)
+            {
+                printf( "Could not start GR for <%s>\n",outfname);
+                goto out;
+            }
     } /* options->trip==1 */
 
     
@@ -153,7 +180,7 @@ int list_main(const char* infname,
 
 
    /*-------------------------------------------------------------------------
-    * iterate tru HDF interfaces 
+    * iterate thru HDF interfaces 
     *-------------------------------------------------------------------------
     */
 
@@ -166,8 +193,13 @@ int list_main(const char* infname,
     
     if (list_vg (infile_id,outfile_id,sd_id,sd_out,gr_id,gr_out,list_tbl,td1,td2,options)<0) 
         goto out;
-    if (list_gr (infile_id,outfile_id,gr_id,gr_out,list_tbl,options)<0) 
-        goto out;
+
+    /* Only process GR interface if there is any GR elements in the file */
+    /* Design note: consider using the same approach for the SD API during the
+       improvement of hrepack, HDFFR-1395 */
+    if (has_GRelems)
+        if (list_gr (infile_id,outfile_id,gr_id,gr_out,list_tbl,options)<0) 
+            goto out;
     if (list_sds(infile_id,outfile_id,sd_id,sd_out,list_tbl,td1,td2,options)<0) 
         goto out;
     if (list_vs (infile_id,outfile_id,list_tbl,options)<0) 
@@ -223,7 +255,7 @@ int list_main(const char* infname,
     *-------------------------------------------------------------------------
     */
     if (GRend (gr_id)==FAIL)
-        printf( "Failed to close GR interface <%s>\n", infname);
+	printf( "Failed to close GR interface <%s>\n", infname);
     if (SDend (sd_id)==FAIL)
         printf( "Failed to close file <%s>\n", infname);
     if (Hclose (infile_id)==FAIL)
@@ -231,8 +263,9 @@ int list_main(const char* infname,
 
     if ( options->trip==1 ) 
     {
-        if (GRend (gr_out)==FAIL)
-            printf( "Failed to close GR interface <%s>\n", outfname);
+	if (has_GRelems)
+	    if (GRend (gr_out)==FAIL)
+		printf( "Failed to close GR interface <%s>\n", outfname);
         if (SDend (sd_out)==FAIL)
             printf( "Failed to close file <%s>\n", outfname);
         if (Hclose (outfile_id)==FAIL)
diff --git a/mfhdf/hrepack/hrepacktst.c b/mfhdf/hrepack/hrepacktst.c
index 3409e94..82dc5ac 100644
--- a/mfhdf/hrepack/hrepacktst.c
+++ b/mfhdf/hrepack/hrepacktst.c
@@ -14,8 +14,6 @@
 #include "hdf.h"
 #include "mfhdf.h"
 #include "hcomp.h"
-#include "hrepack.h"
-#include "hdiff.h"
 #include "pal_rgb.h"
 
 #if defined (H4_HAVE_LIBSZ)
@@ -31,9 +29,8 @@
 #define DATA_FILE1            "image8.txt"
 #define DATA_FILE2            "image24pixel.txt"
 #define DATA_FILE3            "image24plane.txt"
-#define HDIFF_TSTSTR          "hdiff hrepacktst1.hdf hrepacktst1_out.hdf"
-#define HDIFF_TSTSTR2         "hdiff hrepacktst2.hdf hrepacktst2_out.hdf"
-#define HDIFF_TSTSTR3         "hdiff hrepacktst3.hdf hrepacktst3_out.hdf"
+#define TAG_GRP_IMAGE DFTAG_RIG
+#define TAG_GRP_DSET  DFTAG_NDG
 
 #define TESTING(WHAT) {printf("%-70s", "Testing " WHAT); fflush(stdout); }
 #define PASSED() {puts(" PASSED");fflush(stdout);}
@@ -3008,389 +3005,10 @@ out:
 }
 
 
-
-/*-------------------------------------------------------------------------
- * Function: test_files
- *
- * Purpose: call hrepack and hdiff on the generated files
- * 1) zip HREPACK_FILE1 with some compression/chunking options
- * 2) use the hdiff utility to compare the input and output file; it returns RET==0
- *    if the high-level objects have the same data
- * 3) use the API functions SD(GR)getcompress, SD(GR)getchunk to verify
- *    the compression/chunking input on the output file
- *
- * Return: SUCCEED, FAIL
- *
- *-------------------------------------------------------------------------
- */
-
-static
-int test_files(void)
-{
-    options_t     options;      /* for hrepack  */ 
-    diff_opt_t    fspec;        /* for hdiff  */ 
-    int           verbose=0;
-    int32         in_chunk_lengths[H4_MAX_VAR_DIMS];
-    
-    /* initialize options for hdiff */
-    memset(&fspec,0,sizeof(diff_opt_t));
-    fspec.ga = 1;    /* compare global attributes */
-    fspec.sa = 1;    /* compare SD local attributes */
-    fspec.sd = 1;    /* compare SD data */
-    fspec.vd = 1;    /* compare Vdata */
-    fspec.gr = 1;    /* compare GR data */
-    
-    in_chunk_lengths[0]=10;
-    in_chunk_lengths[1]=8;
-    in_chunk_lengths[2]=6;
-    
-    
-   /*-------------------------------------------------------------------------
-    * test1:  
-    * HUFF
-    *-------------------------------------------------------------------------
-    */
-    
-    
-    TESTING("hrepack -t dset7:HUFF 1 -c dset7:10x8x6");
-    hrepack_init (&options,verbose);
-    hrepack_addcomp("dset7:HUFF 1",&options);
-    hrepack_addchunk("dset7:10x8x6",&options);
-    if (hrepack_main(HREPACK_FILE1,HREPACK_FILE1_OUT,&options)<0)
-        goto out;
-    hrepack_end (&options);
-    PASSED();
-    
-    TESTING(HDIFF_TSTSTR);
-    if (hdiff(HREPACK_FILE1,HREPACK_FILE1_OUT,&fspec) > 0 || fspec.err_stat)
-        goto out;
-    if ( sds_verifiy_comp("dset7",COMP_CODE_SKPHUFF, 1) == -1) 
-        goto out;
-    if ( sds_verifiy_chunk("dset7",HDF_CHUNK|HDF_COMP,3,in_chunk_lengths) == -1) 
-        goto out;
-    PASSED();
-    
-    
-   /*-------------------------------------------------------------------------
-    * test2: 
-    * RLE
-    *-------------------------------------------------------------------------
-    */
-    TESTING("hrepack -t dset4:RLE -c dset4:10x8");
-    hrepack_init (&options,verbose);
-    hrepack_addcomp("dset4:RLE",&options);
-    hrepack_addchunk("dset4:10x8",&options);
-    if (hrepack_main(HREPACK_FILE1,HREPACK_FILE1_OUT,&options)<0)
-        goto out;
-    hrepack_end (&options);
-    PASSED();
-    
-    TESTING(HDIFF_TSTSTR);
-    if (hdiff(HREPACK_FILE1,HREPACK_FILE1_OUT,&fspec) > 0 || fspec.err_stat)
-        goto out;
-    if ( sds_verifiy_comp("dset4",COMP_CODE_RLE, 0) == -1) 
-        goto out;
-    if ( sds_verifiy_chunk("dset4",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
-        goto out;
-    PASSED();
-    
-   /*-------------------------------------------------------------------------
-    * test3:  
-    * SDS SELECTED with GZIP, chunking SELECTED
-    *-------------------------------------------------------------------------
-    */
-    TESTING("hrepack -t dset4:GZIP 6 -c dset4:10x8");
-    hrepack_init (&options,verbose);
-    hrepack_addcomp("dset4:GZIP 6",&options);
-    hrepack_addchunk("dset4:10x8",&options);
-    if (hrepack_main(HREPACK_FILE1,HREPACK_FILE1_OUT,&options)<0)
-        goto out;
-    hrepack_end (&options);
-    PASSED();
-    
-    TESTING(HDIFF_TSTSTR);
-    if (hdiff(HREPACK_FILE1,HREPACK_FILE1_OUT,&fspec) > 0 || fspec.err_stat)
-        goto out;
-    if ( sds_verifiy_comp("dset4",COMP_CODE_DEFLATE, 6) == -1) 
-        goto out;
-    if ( sds_verifiy_chunk("dset4",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
-        goto out;
-    PASSED();
-    
-    
-   /*-------------------------------------------------------------------------
-    * test4:  
-    * SDS SELECTED with SZIP, chunking SELECTED
-    *-------------------------------------------------------------------------
-    */
-    TESTING("hrepack -t dset4:SZIP 8,EC -c dset4:10x8");
-#if defined (H4_HAVE_LIBSZ)
-    if (SZ_encoder_enabled()) 
-    {
-        hrepack_init (&options,verbose);
-        hrepack_addcomp("dset4:SZIP 8,EC",&options);
-        hrepack_addchunk("dset4:10x8",&options);
-        if (hrepack_main(HREPACK_FILE1,HREPACK_FILE1_OUT,&options)<0)
-            goto out;
-        hrepack_end (&options);
-        PASSED();
-        
-        TESTING(HDIFF_TSTSTR);
-        if (hdiff(HREPACK_FILE1,HREPACK_FILE1_OUT,&fspec) > 0 || fspec.err_stat)
-            goto out;
-        if ( sds_verifiy_comp("dset4",COMP_CODE_SZIP, 0) == -1) 
-            goto out;
-        if ( sds_verifiy_chunk("dset4",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
-            goto out;
-        PASSED();
-    } else 
-    {
-        /* no szip encoder */
-        SKIPPED();
-    }
-    
-#else
-    /* no szip at all */
-    SKIPPED();
-#endif
-    
-   /*-------------------------------------------------------------------------
-    * test4:  
-    * SDS SELECTED with NONE, chunking SELECTED NONE
-    *-------------------------------------------------------------------------
-    */
-    TESTING("hrepack -t dset_chunk:NONE -c dset_chunk:NONE");
-    hrepack_init (&options,verbose);
-    hrepack_addcomp("dset_chunk_comp:NONE",&options);
-    hrepack_addcomp("dset_chunk:NONE",&options);
-    hrepack_addchunk("dset_chunk_comp:NONE",&options);
-    hrepack_addchunk("dset_chunk:NONE",&options);
-    if (hrepack_main(HREPACK_FILE1,HREPACK_FILE1_OUT,&options)<0)
-        goto out;
-    hrepack_end (&options);
-    PASSED();
-    
-    TESTING(HDIFF_TSTSTR);
-    if (hdiff(HREPACK_FILE1,HREPACK_FILE1_OUT,&fspec) > 0 || fspec.err_stat)
-        goto out;
-    if ( sds_verifiy_comp("dset_chunk_comp",COMP_CODE_NONE, 0) == -1) 
-        goto out;
-    if ( sds_verifiy_comp("dset_chunk",COMP_CODE_NONE, 0) == -1) 
-        goto out;
-    if ( sds_verifiy_chunk("dset_chunk_comp",HDF_NONE,0,0) == -1) 
-        goto out;
-    if ( sds_verifiy_chunk("dset_chunk",HDF_NONE,0,0) == -1) 
-        goto out;
-    PASSED();
-    
-    
-   /*-------------------------------------------------------------------------
-    * test5:
-    * SDS SELECTED with all types, chunking SELECTED
-    *-------------------------------------------------------------------------
-    */
-    TESTING("hrepack -t dset4:GZIP 9 -t dset5:RLE -c dset4:10x8");
-    hrepack_init (&options,verbose);
-    hrepack_addcomp("dset4:GZIP 9",&options);
-    hrepack_addcomp("dset5:RLE",&options);
-    hrepack_addcomp("dset6:HUFF 2",&options);
-#if defined (H4_HAVE_LIBSZ)
-    if (SZ_encoder_enabled()) {
-        hrepack_addcomp("dset7:SZIP 8,EC",&options);
-    }
-#endif
-    hrepack_addchunk("dset4:10x8",&options);
-    hrepack_addchunk("dset5:10x8",&options);
-    hrepack_addchunk("dset6:10x8",&options);
-    if (hrepack_main(HREPACK_FILE1,HREPACK_FILE1_OUT,&options)<0)
-        goto out;
-    hrepack_end (&options);
-    PASSED();
-    
-    TESTING(HDIFF_TSTSTR);
-    if (hdiff(HREPACK_FILE1,HREPACK_FILE1_OUT,&fspec) > 0 || fspec.err_stat)
-        goto out;
-    if ( sds_verifiy_comp("dset4",COMP_CODE_DEFLATE, 9) == -1) 
-        goto out;
-    if ( sds_verifiy_comp("dset5",COMP_CODE_RLE, 0) == -1) 
-        goto out;
-    if ( sds_verifiy_comp("dset6",COMP_CODE_SKPHUFF, 2) == -1) 
-        goto out;
-#if defined (H4_HAVE_LIBSZ)
-    if (SZ_encoder_enabled()) {
-        if ( sds_verifiy_comp("dset7",COMP_CODE_SZIP, 0) == -1) 
-            goto out;
-    }
-#endif
-    if ( sds_verifiy_chunk("dset4",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
-        goto out;
-    if ( sds_verifiy_chunk("dset5",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
-        goto out;
-    if ( sds_verifiy_chunk("dset6",HDF_CHUNK|HDF_COMP,2,in_chunk_lengths) == -1) 
-        goto out;
-    PASSED();
-    
-    
-   /*-------------------------------------------------------------------------
-    * test6: 
-    * SDS SELECTED with all types, no chunking
-    *-------------------------------------------------------------------------
-    */
-    TESTING("hrepack -t dset4:GZIP 9 -t dset5:RLE -t dset6:HUFF 2");
-    hrepack_init (&options,verbose);
-    hrepack_addcomp("dset4:GZIP 9",&options);
-    hrepack_addcomp("dset5:RLE",&options);
-    hrepack_addcomp("dset6:HUFF 2",&options);
-#if defined (H4_HAVE_LIBSZ)
-    if (SZ_encoder_enabled()) {
-        hrepack_addcomp("dset7:SZIP 4,EC",&options);
-    }
-#endif
-    if (hrepack_main(HREPACK_FILE1,HREPACK_FILE1_OUT,&options)<0)
-        goto out;
-    hrepack_end (&options);
-    PASSED();
-    
-    TESTING(HDIFF_TSTSTR);
-    if (hdiff(HREPACK_FILE1,HREPACK_FILE1_OUT,&fspec) > 0 || fspec.err_stat)
-        goto out;
-    if ( sds_verifiy_comp("dset4",COMP_CODE_DEFLATE, 9) == -1) 
-        goto out;
-    if ( sds_verifiy_comp("dset5",COMP_CODE_RLE, 0) == -1) 
-        goto out;
-    if ( sds_verifiy_comp("dset6",COMP_CODE_SKPHUFF, 2) == -1) 
-        goto out;
-#if defined (H4_HAVE_LIBSZ)
-    if (SZ_encoder_enabled()) {
-        if ( sds_verifiy_comp("dset7",COMP_CODE_SZIP, 0) == -1) 
-            goto out;
-    }
-#endif
-    PASSED();
-    
-    
-   /*-------------------------------------------------------------------------
-    * test7:  
-    * compressing SDS ALL, chunking SELECTED NONE
-    *-------------------------------------------------------------------------
-    */
-    
-    TESTING("hrepack -t *:GZIP 1 -c dset_chunk:NONE");
-    hrepack_init (&options,verbose);
-    hrepack_addcomp("*:GZIP 1",&options);
-    hrepack_addchunk("dset_chunk_comp:NONE",&options);
-    hrepack_addchunk("dset_chunk:NONE",&options);
-    if (hrepack_main(HREPACK_FILE1,HREPACK_FILE1_OUT,&options)<0)
-        goto out;
-    hrepack_end (&options);
-    PASSED();
-    
-    TESTING(HDIFF_TSTSTR);
-    if (hdiff(HREPACK_FILE1,HREPACK_FILE1_OUT,&fspec) > 0 || fspec.err_stat)
-        goto out;
-    if ( sds_verifiy_comp_all(COMP_CODE_DEFLATE, 1) == -1) 
-        goto out;
-    if ( sds_verifiy_chunk("dset_chunk_comp",HDF_NONE,0,0) == -1) 
-        goto out;
-    if ( sds_verifiy_chunk("dset_chunk",HDF_NONE,0,0) == -1) 
-        goto out;
-    PASSED();
-    
-   /*-------------------------------------------------------------------------
-    * test8:
-    * no compressing, chunking ALL
-    *-------------------------------------------------------------------------
-    */
-    
-    TESTING("hrepack -c *:10x8");
-    hrepack_init (&options,verbose);
-    hrepack_addchunk("*:10x8",&options);
-    if (hrepack_main(HREPACK_FILE1,HREPACK_FILE1_OUT,&options)<0)
-        goto out;
-    hrepack_end (&options);
-    PASSED();
-    
-    TESTING(HDIFF_TSTSTR);
-    if (hdiff(HREPACK_FILE1,HREPACK_FILE1_OUT,&fspec) > 0 || fspec.err_stat)
-        goto out;
-    if ( sds_verifiy_chunk_all(HDF_CHUNK,2,in_chunk_lengths,"dset7") == -1) 
-        goto out;
-    PASSED();
-    
-    
-   /*-------------------------------------------------------------------------
-    * test9: 
-    * compressing SDS ALL with GZIP
-    *-------------------------------------------------------------------------
-    */
-    
-    TESTING("hrepack -t *:GZIP 1");
-    hrepack_init (&options,verbose);
-    hrepack_addcomp("*:GZIP 1",&options);
-    if (hrepack_main(HREPACK_FILE1,HREPACK_FILE1_OUT,&options)<0)
-        goto out;
-    hrepack_end (&options);
-    PASSED();
-    
-    TESTING(HDIFF_TSTSTR);
-    if (hdiff(HREPACK_FILE1,HREPACK_FILE1_OUT,&fspec) > 0 || fspec.err_stat)
-        goto out;
-    if ( sds_verifiy_comp_all(COMP_CODE_DEFLATE, 1) == -1) 
-        goto out;
-    PASSED();
-    
-    
-   /*-------------------------------------------------------------------------
-    * test10: 
-    * repack a big file using hyperslab reading/writing
-    *-------------------------------------------------------------------------
-    */
-    
-    TESTING("hyperslab repacking");
-    hrepack_init (&options,verbose);
-    if (hrepack_main(HREPACK_FILE2,HREPACK_FILE2_OUT,&options)<0)
-        goto out;
-    hrepack_end (&options);
-    PASSED();
-    
-    TESTING(HDIFF_TSTSTR2);
-    if (hdiff(HREPACK_FILE2,HREPACK_FILE2_OUT,&fspec) > 0 || fspec.err_stat)
-        goto out;
-    PASSED();
-
-   /*-------------------------------------------------------------------------
-    * test11: 
-    * repack a file with vgroups
-    *-------------------------------------------------------------------------
-    */
-    
-    TESTING("vgroups dependencies");
-    hrepack_init (&options,verbose);
-    if (hrepack_main(HREPACK_FILE3,HREPACK_FILE3_OUT,&options)<0)
-        goto out;
-    hrepack_end (&options);
-    PASSED();
-    
-    TESTING(HDIFF_TSTSTR3);
-    if (hdiff(HREPACK_FILE3,HREPACK_FILE3_OUT,&fspec) > 0 || fspec.err_stat)
-        goto out;
-    if (vg_verifygrpdep(HREPACK_FILE3,HREPACK_FILE3_OUT) != 0 )
-        goto out;
-    PASSED();
-
-   
-       
-    return SUCCEED;
-out:
-    H4_FAILED();
-    return FAIL;
-    
-}
-
 /*-------------------------------------------------------------------------
  * Function: generate_files
  *
- * Purpose: writes several HDF objects to the files 
+ * Purpose: writes several HDF objects to the files
  *  HREPACK_FILE1
  *  HREPACK_FILE2
  *  HREPACK_FILE3
@@ -3464,10 +3082,6 @@ int main(void)
     if ( generate_files() < 0 )
         return 1;
 
-    if ( test_files() < 0 )
-        return 1;
-
-
     return 0;
 
 }
diff --git a/mfhdf/libsrc/CMakeLists.txt b/mfhdf/libsrc/CMakeLists.txt
index 0ffb5de..6dd2c6f 100644
--- a/mfhdf/libsrc/CMakeLists.txt
+++ b/mfhdf/libsrc/CMakeLists.txt
@@ -4,16 +4,16 @@ PROJECT (HDF4_MFHDF_LIBSRC C CXX)
 #-----------------------------------------------------------------------------
 # Generate the netcdf.h file containing user settings needed by compilation
 #-----------------------------------------------------------------------------
-IF (WIN32 AND NOT CYGWIN)
-  SET (H4_WINDOWS_INCLUDE_FILE "#include <hdfi.h>")
-  SET (NETCDF_EXTERN HDFLIBAPI)
-ELSE (WIN32 AND NOT CYGWIN)
-  SET (NETCDF_EXTERN extern)
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  set (H4_WINDOWS_INCLUDE_FILE "#include <hdfi.h>")
+  set (NETCDF_EXTERN HDFLIBAPI)
+else (WIN32)
+  set (NETCDF_EXTERN extern)
+endif (WIN32)
 
-SET (NC_OLD_FILLVALUES 0)
+set (NC_OLD_FILLVALUES 0)
 
-SET (HDF4_MFHDF_LIBSRC_CSRCS
+set (HDF4_MFHDF_LIBSRC_CSRCS
     ${HDF4_MFHDF_LIBSRC_SOURCE_DIR}/array.c
     ${HDF4_MFHDF_LIBSRC_SOURCE_DIR}/attr.c
     ${HDF4_MFHDF_LIBSRC_SOURCE_DIR}/cdf.c
@@ -34,7 +34,7 @@ SET (HDF4_MFHDF_LIBSRC_CSRCS
     ${HDF4_MFHDF_LIBSRC_SOURCE_DIR}/xdrposix.c
 )
 
-SET (HDF4_MFHDF_LIBSRC_CHDRS
+set (HDF4_MFHDF_LIBSRC_CHDRS
     ${HDF4_MFHDF_LIBSRC_SOURCE_DIR}/alloc.h
     ${HDF4_MFHDF_LIBSRC_SOURCE_DIR}/error.h
     ${HDF4_MFHDF_LIBSRC_SOURCE_DIR}/local_nc.h
@@ -44,44 +44,46 @@ SET (HDF4_MFHDF_LIBSRC_CHDRS
     ${HDF4_MFHDF_LIBSRC_SOURCE_DIR}/hdf2netcdf.h
 )
 
-IF (HDF4_ENABLE_NETCDF)
-  CONFIGURE_FILE (${HDF4_MFHDF_LIBSRC_SOURCE_DIR}/netcdf.h.in ${HDF4_BINARY_DIR}/netcdf.h)
-  SET (HDF4_MFHDF_LIBSRC_XCHDRS ${HDF4_BINARY_DIR}/netcdf.h)
-ELSE(HDF4_ENABLE_NETCDF)
-  CONFIGURE_FILE (${HDF4_MFHDF_LIBSRC_SOURCE_DIR}/netcdf.h.in ${HDF4_BINARY_DIR}/hdf4_netcdf.h)
-  SET (HDF4_MFHDF_LIBSRC_XCHDRS ${HDF4_BINARY_DIR}/hdf4_netcdf.h)
-ENDIF (HDF4_ENABLE_NETCDF)
+if (HDF4_ENABLE_NETCDF)
+  configure_file (${HDF4_MFHDF_LIBSRC_SOURCE_DIR}/netcdf.h.in ${HDF4_BINARY_DIR}/netcdf.h)
+  set (HDF4_MFHDF_LIBSRC_XCHDRS ${HDF4_BINARY_DIR}/netcdf.h)
+else (HDF4_ENABLE_NETCDF)
+  configure_file (${HDF4_MFHDF_LIBSRC_SOURCE_DIR}/netcdf.h.in ${HDF4_BINARY_DIR}/hdf4_netcdf.h)
+  set (HDF4_MFHDF_LIBSRC_XCHDRS ${HDF4_BINARY_DIR}/hdf4_netcdf.h)
+endif (HDF4_ENABLE_NETCDF)
 
-IF (NOT HDF4_BUILD_XDR_LIB)
+if (CYGWIN)
+  INCLUDE_DIRECTORIES (/usr/include/tirpc)
+else (CYGWIN)
   INCLUDE_DIRECTORIES (/usr/include/rpc)
-ENDIF (NOT HDF4_BUILD_XDR_LIB)
+endif (CYGWIN)
 
 INCLUDE_DIRECTORIES (${HDF4_HDFSOURCE_DIR})
 INCLUDE_DIRECTORIES (${HDF4_MFHDFSOURCE_DIR})
 
-ADD_DEFINITIONS (-DHDF)
+add_definitions (-DHDF)
 
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS -DSWAP)
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  add_definitions (-DDOS_FS -DSWAP)
+endif (WIN32)
 
-ADD_LIBRARY (${HDF4_MF_LIB_TARGET} ${LIB_TYPE} ${HDF4_MFHDF_LIBSRC_CSRCS} ${HDF4_MFHDF_LIBSRC_CHDRS})
-IF (HDF4_BUILD_XDR_LIB)
-  IF (WIN32 AND NOT CYGWIN)
-    ADD_DEFINITIONS (-DNO_SYS_XDR_INC)
-  ENDIF (WIN32 AND NOT CYGWIN)
+add_library (${HDF4_MF_LIB_TARGET} ${LIB_TYPE} ${HDF4_MFHDF_LIBSRC_CSRCS} ${HDF4_MFHDF_LIBSRC_CHDRS})
+if (HDF4_BUILD_XDR_LIB)
+  if (WIN32)
+    add_definitions (-DNO_SYS_XDR_INC)
+  endif (WIN32)
   INCLUDE_DIRECTORIES (${HDF4_MFHDF_XDR_DIR})
-  TARGET_LINK_LIBRARIES (${HDF4_MF_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET})
-ENDIF (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (${HDF4_MF_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET})
+endif (HDF4_BUILD_XDR_LIB)
 TARGET_C_PROPERTIES (${HDF4_MF_LIB_TARGET} " " " ")
-TARGET_LINK_LIBRARIES (${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET})
-SET_GLOBAL_VARIABLE (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_MF_LIB_TARGET}")
+target_link_libraries (${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET})
+set_global_variable (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_MF_LIB_TARGET}")
 H4_SET_LIB_OPTIONS (${HDF4_MF_LIB_TARGET} ${HDF4_MF_LIB_NAME} ${LIB_TYPE})
 
 #-----------------------------------------------------------------------------
 # Add file(s) to CMake Install
 #-----------------------------------------------------------------------------
-INSTALL (
+install (
     FILES
         ${HDF4_MFHDF_LIBSRC_CHDRS} ${HDF4_MFHDF_LIBSRC_XCHDRS}
     DESTINATION
@@ -93,11 +95,11 @@ INSTALL (
 #-----------------------------------------------------------------------------
 # Add library to CMake Install : Installs lib and cmake config info
 #-----------------------------------------------------------------------------
-IF (BUILD_SHARED_LIBS)
+if (BUILD_SHARED_LIBS)
   INSTALL_TARGET_PDB (${HDF4_MF_LIB_TARGET} ${HDF4_INSTALL_LIB_DIR} libraries)
-ENDIF (BUILD_SHARED_LIBS)
+endif (BUILD_SHARED_LIBS)
   
-INSTALL (
+install (
     TARGETS 
         ${HDF4_MF_LIB_TARGET}
     EXPORT 
diff --git a/mfhdf/libsrc/Makefile.am b/mfhdf/libsrc/Makefile.am
index 21868b8..b24e02d 100644
--- a/mfhdf/libsrc/Makefile.am
+++ b/mfhdf/libsrc/Makefile.am
@@ -5,10 +5,10 @@
 include $(top_srcdir)/config/commence.am
 
 ## Setup the different includes and preprocessor #defines we need.
-INCLUDES = -I$(top_srcdir)/hdf/src        \
+lib_INCLUDES = -I$(top_srcdir)/hdf/src        \
            -I$(top_srcdir)/mfhdf/libsrc   
 DEFINES = -DNDEBUG -DHDF
-AM_CPPFLAGS = $(INCLUDES) $(DEFINES)
+AM_CPPFLAGS = $(lib_INCLUDES) $(DEFINES)
 
 #############################################################################
 ##                          Library to build                               ##
diff --git a/mfhdf/libsrc/Makefile.in b/mfhdf/libsrc/Makefile.in
index 1cdb694..846780e 100644
--- a/mfhdf/libsrc/Makefile.in
+++ b/mfhdf/libsrc/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -19,23 +19,51 @@
 
 
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -54,13 +82,13 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(am__include_HEADERS_DIST) $(srcdir)/Makefile.am \
-	$(srcdir)/Makefile.in $(srcdir)/netcdf.h.in \
-	$(top_srcdir)/bin/depcomp $(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am
-F77LINK = $(LIBTOOL) --tag=F77 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(F77LD) $(AM_FFLAGS) $(FFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+DIST_COMMON = $(top_srcdir)/config/commence.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
+	$(srcdir)/netcdf.h.in $(top_srcdir)/bin/depcomp \
+	$(am__include_HEADERS_DIST)
+F77LINK = $(LIBTOOL) $(AM_V_lt) --tag=F77 $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(F77LD) $(AM_FFLAGS) $(FFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
 subdir = mfhdf/libsrc
 ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
 am__aclocal_m4_deps = $(top_srcdir)/configure.ac
@@ -115,23 +143,56 @@ am__objects_1 = array.lo attr.lo cdf.lo dim.lo file.lo hdfsds.lo \
 @HDF_BUILD_FORTRAN_TRUE at am_libmfhdf_la_OBJECTS = $(am__objects_1) \
 @HDF_BUILD_FORTRAN_TRUE@	$(am__objects_2)
 libmfhdf_la_OBJECTS = $(am_libmfhdf_la_OBJECTS)
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 F77COMPILE = $(F77) $(AM_FFLAGS) $(FFLAGS)
-LTF77COMPILE = $(LIBTOOL) --tag=F77 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(F77) $(AM_FFLAGS) $(FFLAGS)
+LTF77COMPILE = $(LIBTOOL) $(AM_V_lt) --tag=F77 $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(F77) $(AM_FFLAGS) $(FFLAGS)
+AM_V_F77 = $(am__v_F77_ at AM_V@)
+am__v_F77_ = $(am__v_F77_ at AM_DEFAULT_V@)
+am__v_F77_0 = @echo "  F77     " $@;
+am__v_F77_1 = 
 F77LD = $(F77)
+AM_V_F77LD = $(am__v_F77LD_ at AM_V@)
+am__v_F77LD_ = $(am__v_F77LD_ at AM_DEFAULT_V@)
+am__v_F77LD_0 = @echo "  F77LD   " $@;
+am__v_F77LD_1 = 
 SOURCES = $(libmfhdf_la_SOURCES)
 DIST_SOURCES = $(am__libmfhdf_la_SOURCES_DIST)
 am__can_run_installinfo = \
@@ -142,11 +203,29 @@ am__can_run_installinfo = \
 am__include_HEADERS_DIST = hdf2netcdf.h local_nc.h mfhdf.h \
 	hdf4_netcdf.h mfhdfi.h mfdatainfo.h netcdf.h
 HEADERS = $(include_HEADERS)
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -231,6 +310,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -311,11 +391,11 @@ ACLOCAL_AMFLAGS = "-I m4"
 # .chkexe files are used to mark tests that have run successfully.
 # .chklog files are output from those tests.
 CHECK_CLEANFILES = *.chkexe *.chklog
-INCLUDES = -I$(top_srcdir)/hdf/src        \
+lib_INCLUDES = -I$(top_srcdir)/hdf/src        \
            -I$(top_srcdir)/mfhdf/libsrc   
 
 DEFINES = -DNDEBUG -DHDF
-AM_CPPFLAGS = $(INCLUDES) $(DEFINES)
+AM_CPPFLAGS = $(lib_INCLUDES) $(DEFINES)
 
 #############################################################################
 #############################################################################
@@ -374,6 +454,7 @@ $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
 $(am__aclocal_m4_deps):
 netcdf.h: $(top_builddir)/config.status $(srcdir)/netcdf.h.in
 	cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@
+
 install-libLTLIBRARIES: $(lib_LTLIBRARIES)
 	@$(NORMAL_INSTALL)
 	@list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
@@ -408,8 +489,9 @@ clean-libLTLIBRARIES:
 	  echo rm -f $${locs}; \
 	  rm -f $${locs}; \
 	}
+
 libmfhdf.la: $(libmfhdf_la_OBJECTS) $(libmfhdf_la_DEPENDENCIES) $(EXTRA_libmfhdf_la_DEPENDENCIES) 
-	$(F77LINK) -rpath $(libdir) $(libmfhdf_la_OBJECTS) $(libmfhdf_la_LIBADD) $(LIBS)
+	$(AM_V_F77LD)$(F77LINK) -rpath $(libdir) $(libmfhdf_la_OBJECTS) $(libmfhdf_la_LIBADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -439,51 +521,51 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/xdrposix.Plo at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 mfsdf.lo: $(top_srcdir)/mfhdf/fortran/mfsdf.c
- at am__fastdepCC_TRUE@	$(LIBTOOL)  --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mfsdf.lo -MD -MP -MF $(DEPDIR)/mfsdf.Tpo -c -o mfsdf.lo `test -f '$(top_srcdir)/mfhdf/fortran/mfsdf.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/fortran/mfsdf.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/mfsdf.Tpo $(DEPDIR)/mfsdf.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_srcdir)/mfhdf/fortran/mfsdf.c' object='mfsdf.lo' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT mfsdf.lo -MD -MP -MF $(DEPDIR)/mfsdf.Tpo -c -o mfsdf.lo `test -f '$(top_srcdir)/mfhdf/fortran/mfsdf.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/fortran/mfsdf.c
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/mfsdf.Tpo $(DEPDIR)/mfsdf.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$(top_srcdir)/mfhdf/fortran/mfsdf.c' object='mfsdf.lo' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LIBTOOL)  --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mfsdf.lo `test -f '$(top_srcdir)/mfhdf/fortran/mfsdf.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/fortran/mfsdf.c
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o mfsdf.lo `test -f '$(top_srcdir)/mfhdf/fortran/mfsdf.c' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/fortran/mfsdf.c
 
 jackets.lo: $(top_builddir)/mfhdf/fortran/jackets.c
- at am__fastdepCC_TRUE@	$(LIBTOOL)  --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT jackets.lo -MD -MP -MF $(DEPDIR)/jackets.Tpo -c -o jackets.lo `test -f '$(top_builddir)/mfhdf/fortran/jackets.c' || echo '$(srcdir)/'`$(top_builddir)/mfhdf/fortran/jackets.c
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/jackets.Tpo $(DEPDIR)/jackets.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$(top_builddir)/mfhdf/fortran/jackets.c' object='jackets.lo' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -MT jackets.lo -MD -MP -MF $(DEPDIR)/jackets.Tpo -c -o jackets.lo `test -f '$(top_builddir)/mfhdf/fortran/jackets.c' || echo '$(srcdir)/'`$(top_builddir)/mfhdf/fortran/jackets.c
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/jackets.Tpo $(DEPDIR)/jackets.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$(top_builddir)/mfhdf/fortran/jackets.c' object='jackets.lo' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LIBTOOL)  --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o jackets.lo `test -f '$(top_builddir)/mfhdf/fortran/jackets.c' || echo '$(srcdir)/'`$(top_builddir)/mfhdf/fortran/jackets.c
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS) -c -o jackets.lo `test -f '$(top_builddir)/mfhdf/fortran/jackets.c' || echo '$(srcdir)/'`$(top_builddir)/mfhdf/fortran/jackets.c
 
 .f.o:
-	$(F77COMPILE) -c -o $@ $<
+	$(AM_V_F77)$(F77COMPILE) -c -o $@ $<
 
 .f.obj:
-	$(F77COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
+	$(AM_V_F77)$(F77COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .f.lo:
-	$(LTF77COMPILE) -c -o $@ $<
+	$(AM_V_F77)$(LTF77COMPILE) -c -o $@ $<
 
 mfsdff.lo: $(top_srcdir)/mfhdf/fortran/mfsdff.f
-	$(LIBTOOL)  --tag=F77 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(F77) $(AM_FFLAGS) $(FFLAGS) -c -o mfsdff.lo `test -f '$(top_srcdir)/mfhdf/fortran/mfsdff.f' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/fortran/mfsdff.f
+	$(AM_V_F77)$(LIBTOOL) $(AM_V_lt) --tag=F77 $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(F77) $(AM_FFLAGS) $(FFLAGS) -c -o mfsdff.lo `test -f '$(top_srcdir)/mfhdf/fortran/mfsdff.f' || echo '$(srcdir)/'`$(top_srcdir)/mfhdf/fortran/mfsdff.f
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -512,26 +594,15 @@ uninstall-includeHEADERS:
 	files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
 	dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir)
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -543,15 +614,11 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -560,9 +627,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -719,19 +787,20 @@ uninstall-am: uninstall-includeHEADERS uninstall-libLTLIBRARIES
 
 .MAKE: install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \
-	clean-libLTLIBRARIES clean-libtool cscopelist ctags distclean \
-	distclean-compile distclean-generic distclean-libtool \
-	distclean-tags distdir dvi dvi-am html html-am info info-am \
-	install install-am install-data install-data-am install-dvi \
-	install-dvi-am install-exec install-exec-am install-html \
-	install-html-am install-includeHEADERS install-info \
-	install-info-am install-libLTLIBRARIES install-man install-pdf \
-	install-pdf-am install-ps install-ps-am install-strip \
-	installcheck installcheck-am installdirs maintainer-clean \
+.PHONY: CTAGS GTAGS TAGS all all-am check check-am clean clean-generic \
+	clean-libLTLIBRARIES clean-libtool cscopelist-am ctags \
+	ctags-am distclean distclean-compile distclean-generic \
+	distclean-libtool distclean-tags distdir dvi dvi-am html \
+	html-am info info-am install install-am install-data \
+	install-data-am install-dvi install-dvi-am install-exec \
+	install-exec-am install-html install-html-am \
+	install-includeHEADERS install-info install-info-am \
+	install-libLTLIBRARIES install-man install-pdf install-pdf-am \
+	install-ps install-ps-am install-strip installcheck \
+	installcheck-am installdirs maintainer-clean \
 	maintainer-clean-generic mostlyclean mostlyclean-compile \
 	mostlyclean-generic mostlyclean-libtool pdf pdf-am ps ps-am \
-	tags uninstall uninstall-am uninstall-includeHEADERS \
+	tags tags-am uninstall uninstall-am uninstall-includeHEADERS \
 	uninstall-libLTLIBRARIES
 
 # mfdatainfo.h should be added conditionally only; should local_nc.h even be here? -BMR
diff --git a/mfhdf/libsrc/local_nc.h b/mfhdf/libsrc/local_nc.h
index 039e084..10609f7 100644
--- a/mfhdf/libsrc/local_nc.h
+++ b/mfhdf/libsrc/local_nc.h
@@ -14,7 +14,7 @@
  * access to either file, you may request a copy from help at hdfgroup.org.     *
  * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
 
-/* $Id: local_nc.h 6043 2014-01-21 21:09:03Z acheng $ */
+/* $Id: local_nc.h 6112 2014-06-04 21:05:09Z byrn $ */
 #ifndef _LOCAL_NC_
 #define _LOCAL_NC_
 
@@ -30,7 +30,7 @@
 #define FILENAME_MAX  255
 #endif
 
-/* Do we have systeme XDR files */
+/* Do we have system XDR files */
 #ifndef  NO_SYS_XDR_INC 
 #include	<rpc/types.h>
 #include	<rpc/xdr.h>
diff --git a/mfhdf/libsrc/xdrposix.c b/mfhdf/libsrc/xdrposix.c
index 8bd6b18..0eacaab 100644
--- a/mfhdf/libsrc/xdrposix.c
+++ b/mfhdf/libsrc/xdrposix.c
@@ -12,7 +12,7 @@
  *
  * -glenn
  */
-/* $Id: xdrposix.c 6043 2014-01-21 21:09:03Z acheng $ */
+/* $Id: xdrposix.c 6112 2014-06-04 21:05:09Z byrn $ */
 
 /*
  * 32-bit integer on the host architecture (on the CRAY, this is actually 64
@@ -26,7 +26,11 @@
 typedef NETLONG     netlong;
 #undef  NETLONG
 
-#   if defined MSDOS || defined WINNT || defined _WIN32
+#   if defined __MINGW32__
+#       include <stdint.h>
+#   endif
+
+#   if defined MSDOS || defined WINNT || defined _WIN32 || defined __MINGW32__
 #       include <io.h>
 #   else
 #       include <unistd.h>
diff --git a/mfhdf/ncdump/CMakeLists.txt b/mfhdf/ncdump/CMakeLists.txt
index 72fa42d..2cfd98e 100644
--- a/mfhdf/ncdump/CMakeLists.txt
+++ b/mfhdf/ncdump/CMakeLists.txt
@@ -4,20 +4,20 @@ PROJECT (HDF4_MFHDF_NCDUMP)
 INCLUDE_DIRECTORIES (${HDF4_HDFSOURCE_DIR})
 INCLUDE_DIRECTORIES (${HDF4_MFHDFSOURCE_DIR})
 
-ADD_DEFINITIONS (-DHDF)
+add_definitions (-DHDF)
 
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS)
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  add_definitions (-DDOS_FS)
+endif (WIN32)
 
-IF (HDF4_BUILD_XDR_LIB)
-  IF (WIN32 AND NOT CYGWIN)
-    ADD_DEFINITIONS (-DNO_SYS_XDR_INC)
-  ENDIF (WIN32 AND NOT CYGWIN)
+if (HDF4_BUILD_XDR_LIB)
+  if (WIN32)
+    add_definitions (-DNO_SYS_XDR_INC)
+  endif (WIN32)
   INCLUDE_DIRECTORIES (${HDF4_MFHDF_XDR_DIR})
-ENDIF (HDF4_BUILD_XDR_LIB)
+endif (HDF4_BUILD_XDR_LIB)
 
-SET (ncdump_SRCS
+set (ncdump_SRCS
     ${HDF4_MFHDF_NCDUMP_SOURCE_DIR}/dumplib.c
     ${HDF4_MFHDF_NCDUMP_SOURCE_DIR}/ncdump.c
     ${HDF4_MFHDF_NCDUMP_SOURCE_DIR}/vardata.c
@@ -26,16 +26,16 @@ SET (ncdump_SRCS
   
 ADD_EXECUTABLE (ncdump ${ncdump_SRCS})
 TARGET_C_PROPERTIES (ncdump " " " ")
-IF (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (ncdump ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET} )
-ELSE (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (ncdump ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDIF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (ncdump ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET} )
+else (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (ncdump ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endif (HDF4_BUILD_XDR_LIB)
 TARGET_NAMING (ncdump ${LIB_TYPE})
 
-IF (BUILD_TESTING)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING)
+if (BUILD_TESTING)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING)
 
 ##############################################################################
 ##############################################################################
diff --git a/mfhdf/ncdump/CMakeTests.cmake b/mfhdf/ncdump/CMakeTests.cmake
index 76528eb..6baf00d 100644
--- a/mfhdf/ncdump/CMakeTests.cmake
+++ b/mfhdf/ncdump/CMakeTests.cmake
@@ -6,7 +6,7 @@
 ##############################################################################
 
 # Remove any output file left over from previous test run
-ADD_TEST (
+add_test (
     NAME NCDUMP-clearall-objects
     COMMAND    ${CMAKE_COMMAND}
         -E remove 
@@ -15,15 +15,14 @@ ADD_TEST (
         test1.cdl
         test2.cdl
 )
-IF (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (NCDUMP-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-ELSE (NOT "${last_test}" STREQUAL "")
-  SET_TESTS_PROPERTIES (NCDUMP-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
-ENDIF (NOT "${last_test}" STREQUAL "")
-SET (last_test "NCDUMP-clearall-objects")
+if (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (NCDUMP-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+else (NOT "${last_test}" STREQUAL "")
+  set_tests_properties (NCDUMP-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
+endif (NOT "${last_test}" STREQUAL "")
+set (last_test "NCDUMP-clearall-objects")
 
-#-- Copy all the data files from the test directory into the source directory
-#MESSAGE (STATUS " Copying ${HDF4_MFHDF_NCDUMP_SOURCE_DIR}/test0.cdl to ${PROJECT_BINARY_DIR}/")
+#message (STATUS " Copying ${HDF4_MFHDF_NCDUMP_SOURCE_DIR}/test0.cdl to ${PROJECT_BINARY_DIR}/")
 ADD_CUSTOM_COMMAND (
     TARGET     ncdump
     POST_BUILD
@@ -31,15 +30,15 @@ ADD_CUSTOM_COMMAND (
     ARGS       -E copy_if_different ${HDF4_MFHDF_NCDUMP_SOURCE_DIR}/test0.cdl ${PROJECT_BINARY_DIR}/test0.cdl
 )
 
-IF (NCGEN_UTILITY)
-  ADD_TEST (
+if (NCGEN_UTILITY)
+  add_test (
       NAME NCDUMP-test0.nc
       COMMAND $<TARGET_FILE:ncgen> -o test0.nc -n test0.cdl
   )
-  SET_TESTS_PROPERTIES (NCDUMP-test0.nc PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  SET (last_test "NCDUMP-test0.nc")
+  set_tests_properties (NCDUMP-test0.nc PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  set (last_test "NCDUMP-test0.nc")
 
-  ADD_TEST (
+  add_test (
       NAME NCDUMP-test1.cdl
       COMMAND "${CMAKE_COMMAND}"
           -D "TEST_PROGRAM=$<TARGET_FILE:ncdump>"
@@ -48,19 +47,19 @@ IF (NCGEN_UTILITY)
           -D "TEST_OUTPUT=test1.cdl"
           -D "TEST_EXPECT=0"
           -D "TEST_SKIP_COMPARE=TRUE"
-          -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+          -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
   )
-  SET_TESTS_PROPERTIES (NCDUMP-test1.cdl PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  SET (last_test "NCDUMP-test1.cdl")
+  set_tests_properties (NCDUMP-test1.cdl PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  set (last_test "NCDUMP-test1.cdl")
 
-  ADD_TEST (
+  add_test (
       NAME NCDUMP-test1.nc
       COMMAND $<TARGET_FILE:ncgen> -o test1.nc -n test1.cdl
   )
-  SET_TESTS_PROPERTIES (NCDUMP-test1.nc PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  SET (last_test "NCDUMP-test1.nc")
+  set_tests_properties (NCDUMP-test1.nc PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  set (last_test "NCDUMP-test1.nc")
 
-  ADD_TEST (
+  add_test (
       NAME NCDUMP-test2.cdl
       COMMAND "${CMAKE_COMMAND}"
           -D "TEST_PROGRAM=$<TARGET_FILE:ncdump>"
@@ -69,8 +68,8 @@ IF (NCGEN_UTILITY)
           -D "TEST_OUTPUT=test2.cdl"
           -D "TEST_EXPECT=0"
           -D "TEST_REFERENCE=test1.cdl"
-          -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+          -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
   )
-  SET_TESTS_PROPERTIES (NCDUMP-test2.cdl PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  SET (last_test "NCDUMP-test2.cdl")
-ENDIF (NCGEN_UTILITY)
+  set_tests_properties (NCDUMP-test2.cdl PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  set (last_test "NCDUMP-test2.cdl")
+endif (NCGEN_UTILITY)
diff --git a/mfhdf/ncdump/Makefile.am b/mfhdf/ncdump/Makefile.am
index af388be..45811ff 100644
--- a/mfhdf/ncdump/Makefile.am
+++ b/mfhdf/ncdump/Makefile.am
@@ -5,11 +5,11 @@
 include $(top_srcdir)/config/commence.am
 
 ## Setup the different includes and preprocessor #defines we need.
-INCLUDES=-I$(top_srcdir)/hdf/src        \
+ncdump_INCLUDES=-I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 DEFINES=-DNDEBUG -DHDF
-AM_CPPFLAGS=$(INCLUDES) $(DEFINES)
+AM_CPPFLAGS=$(ncdump_INCLUDES) $(DEFINES)
 
 ## Add ncdump specific linker flags here
 ncdump_LDFLAGS = $(LT_STATIC_EXEC) $(AM_LDFLAGS)
diff --git a/mfhdf/ncdump/Makefile.in b/mfhdf/ncdump/Makefile.in
index b50ba0a..d8aed14 100644
--- a/mfhdf/ncdump/Makefile.in
+++ b/mfhdf/ncdump/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -18,23 +18,51 @@
 #############################################################################
 
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -53,11 +81,11 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
 	$(srcdir)/testncdump.sh.in $(top_srcdir)/bin/depcomp \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am
+	$(top_srcdir)/bin/test-driver
 bin_PROGRAMS = ncdump$(EXEEXT)
 TESTS = $(TEST_SCRIPT)
 subdir = mfhdf/ncdump
@@ -74,22 +102,47 @@ PROGRAMS = $(bin_PROGRAMS)
 am_ncdump_OBJECTS = dumplib.$(OBJEXT) ncdump.$(OBJEXT) \
 	vardata.$(OBJEXT)
 ncdump_OBJECTS = $(am_ncdump_OBJECTS)
-ncdump_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(ncdump_LDFLAGS) \
-	$(LDFLAGS) -o $@
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
+ncdump_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(ncdump_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 SOURCES = $(ncdump_SOURCES)
 DIST_SOURCES = $(ncdump_SOURCES)
 am__can_run_installinfo = \
@@ -127,15 +180,202 @@ am__uninstall_files_from_dir = { \
 man1dir = $(mandir)/man1
 NROFF = nroff
 MANS = $(man1_MANS)
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
+TEST_SUITE_LOG = test-suite.log
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -220,6 +460,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -303,12 +544,12 @@ ACLOCAL_AMFLAGS = "-I m4"
 #############################################################################
 #############################################################################
 CHECK_CLEANFILES = *.chkexe *.chklog test0.nc nctest0.cdl
-INCLUDES = -I$(top_srcdir)/hdf/src        \
+ncdump_INCLUDES = -I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 
 DEFINES = -DNDEBUG -DHDF
-AM_CPPFLAGS = $(INCLUDES) $(DEFINES)
+AM_CPPFLAGS = $(ncdump_INCLUDES) $(DEFINES)
 ncdump_LDFLAGS = $(LT_STATIC_EXEC) $(AM_LDFLAGS)
 
 #############################################################################
@@ -341,7 +582,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
-.SUFFIXES: .c .lo .o .obj
+.SUFFIXES: .c .lo .log .o .obj .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -384,10 +625,12 @@ install-binPROGRAMS: $(bin_PROGRAMS)
 	fi; \
 	for p in $$list; do echo "$$p $$p"; done | \
 	sed 's/$(EXEEXT)$$//' | \
-	while read p p1; do if test -f $$p || test -f $$p1; \
-	  then echo "$$p"; echo "$$p"; else :; fi; \
+	while read p p1; do if test -f $$p \
+	 || test -f $$p1 \
+	  ; then echo "$$p"; echo "$$p"; else :; fi; \
 	done | \
-	sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \
+	sed -e 'p;s,.*/,,;n;h' \
+	    -e 's|.*|.|' \
 	    -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
 	sed 'N;N;N;s,\n, ,g' | \
 	$(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
@@ -408,7 +651,8 @@ uninstall-binPROGRAMS:
 	@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
 	files=`for p in $$list; do echo "$$p"; done | \
 	  sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
-	      -e 's/$$/$(EXEEXT)/' `; \
+	      -e 's/$$/$(EXEEXT)/' \
+	`; \
 	test -n "$$list" || exit 0; \
 	echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
 	cd "$(DESTDIR)$(bindir)" && rm -f $$files
@@ -421,9 +665,10 @@ clean-binPROGRAMS:
 	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
 	echo " rm -f" $$list; \
 	rm -f $$list
+
 ncdump$(EXEEXT): $(ncdump_OBJECTS) $(ncdump_DEPENDENCIES) $(EXTRA_ncdump_DEPENDENCIES) 
 	@rm -f ncdump$(EXEEXT)
-	$(ncdump_LINK) $(ncdump_OBJECTS) $(ncdump_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(ncdump_LINK) $(ncdump_OBJECTS) $(ncdump_LDADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -436,25 +681,25 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/vardata.Po at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -503,26 +748,15 @@ uninstall-man1:
 	      -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \
 	dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir)
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -534,15 +768,11 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -551,9 +781,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -569,20 +800,152 @@ cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all $(check_SCRIPTS)
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
-	@list='$(MANS)'; if test -n "$$list"; then \
-	  list=`for p in $$list; do \
-	    if test -f $$p; then d=; else d="$(srcdir)/"; fi; \
-	    if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \
-	  if test -n "$$list" && \
-	    grep 'ab help2man is required to generate this page' $$list >/dev/null; then \
-	    echo "error: found man pages containing the 'missing help2man' replacement text:" >&2; \
-	    grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/         /' >&2; \
-	    echo "       to fix them, install help2man, remove and regenerate the man pages;" >&2; \
-	    echo "       typically 'make maintainer-clean' will remove them" >&2; \
-	    exit 1; \
-	  else :; fi; \
-	else :; fi
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	list='$(DISTFILES)'; \
@@ -641,6 +1004,9 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 
@@ -726,21 +1092,21 @@ uninstall-man: uninstall-man1
 
 .MAKE: check-am install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am all-local check check-TESTS check-am \
-	clean clean-binPROGRAMS clean-generic clean-libtool cscopelist \
-	ctags distclean distclean-compile distclean-generic \
-	distclean-libtool distclean-tags distdir dvi dvi-am html \
-	html-am info info-am install install-am install-binPROGRAMS \
-	install-data install-data-am install-dvi install-dvi-am \
-	install-exec install-exec-am install-html install-html-am \
-	install-info install-info-am install-man install-man1 \
-	install-pdf install-pdf-am install-ps install-ps-am \
-	install-strip installcheck installcheck-am installdirs \
-	maintainer-clean maintainer-clean-generic mostlyclean \
-	mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
-	mostlyclean-local pdf pdf-am ps ps-am tags uninstall \
-	uninstall-am uninstall-binPROGRAMS uninstall-man \
-	uninstall-man1
+.PHONY: CTAGS GTAGS TAGS all all-am all-local check check-TESTS \
+	check-am clean clean-binPROGRAMS clean-generic clean-libtool \
+	cscopelist-am ctags ctags-am distclean distclean-compile \
+	distclean-generic distclean-libtool distclean-tags distdir dvi \
+	dvi-am html html-am info info-am install install-am \
+	install-binPROGRAMS install-data install-data-am install-dvi \
+	install-dvi-am install-exec install-exec-am install-html \
+	install-html-am install-info install-info-am install-man \
+	install-man1 install-pdf install-pdf-am install-ps \
+	install-ps-am install-strip installcheck installcheck-am \
+	installdirs maintainer-clean maintainer-clean-generic \
+	mostlyclean mostlyclean-compile mostlyclean-generic \
+	mostlyclean-libtool mostlyclean-local pdf pdf-am ps ps-am \
+	recheck tags tags-am uninstall uninstall-am \
+	uninstall-binPROGRAMS uninstall-man uninstall-man1
 
 
 # lib/progs/tests targets recurse into subdirectories. build-* targets
diff --git a/mfhdf/ncdump/ncdump.c b/mfhdf/ncdump/ncdump.c
index aa68645..f6a69a7 100644
--- a/mfhdf/ncdump/ncdump.c
+++ b/mfhdf/ncdump/ncdump.c
@@ -1,7 +1,7 @@
 /*********************************************************************
  *   Copyright 1993, University Corporation for Atmospheric Research
  *   See netcdf/README file for copying and redistribution conditions.
- *   $Id: ncdump.c 6036 2014-01-20 17:28:01Z acheng $
+ *   $Id: ncdump.c 6178 2015-01-21 23:32:52Z bmribler $
  *********************************************************************/
 
 #include <stdio.h>
@@ -534,15 +534,29 @@ do_ncdump(char *path, struct fspec* specp)
 				continue;
 
 			if (var.ndims == 0 || var.dims[0] != xdimid || dims[xdimid].size != 0) {
+				int ret = 0;
+
 				/* Collect variable's dim sizes */
 				for (id = 0; id < var.ndims; id++)
 					vdims[id] = dims[var.dims[id]].size;
 
-				if (vardata(&var, vdims, ncid, varid, specp) == -1) {
+				 /* if (vardata(&var, vdims, ncid, varid, specp) == -1) 
+ */ 
+				ret = vardata(&var, vdims, ncid, varid, specp);
+				/* Keep the original failure detection until further improvement */
+				if (ret == -1) {
 					error("can't output data for variable %s", var.name);
 					(void) ncclose(ncid);
 					return;
 				}
+				/* This failure indicates that vardata failed
+				   because ncvarget fails.  (HDFFR-1468)
+				   -BMR, 2015/01/20) */
+				if (ret == ERR_READFAIL) {
+					error("Reading failed for variable %s, possibly the data is corrupted.", var.name);
+					(void) ncclose(ncid);
+					return;
+				}
 			}
 		}
 	}
diff --git a/mfhdf/ncdump/ncdump.h b/mfhdf/ncdump/ncdump.h
index 0f77cda..95ec6a8 100644
--- a/mfhdf/ncdump/ncdump.h
+++ b/mfhdf/ncdump/ncdump.h
@@ -1,10 +1,12 @@
 /*********************************************************************
  *   Copyright 1993, UCAR/Unidata
  *   See netcdf/COPYRIGHT file for copying and redistribution conditions.
- *   $Id: ncdump.h 4928 2007-09-06 21:48:49Z epourmal $
+ *   $Id: ncdump.h 6178 2015-01-21 23:32:52Z bmribler $
  *********************************************************************/
 
 #define  Printf  (void) printf
+#define  ERR_READFAIL	-2	/* Used to return by vardata() to indicate that
+				   ncvarget() fails to read the data */
 
 typedef enum {false=0, true=1} bool;
 
diff --git a/mfhdf/ncdump/testncdump.sh.in b/mfhdf/ncdump/testncdump.sh.in
old mode 100755
new mode 100644
diff --git a/mfhdf/ncdump/vardata.c b/mfhdf/ncdump/vardata.c
index aea6ce0..a639c9a 100644
--- a/mfhdf/ncdump/vardata.c
+++ b/mfhdf/ncdump/vardata.c
@@ -1,7 +1,7 @@
 /*********************************************************************
  *   Copyright 1993, UCAR/Unidata
  *   See netcdf/COPYRIGHT file for copying and redistribution conditions.
- *   $Id: vardata.c 4998 2007-11-16 03:14:03Z epourmal $
+ *   $Id: vardata.c 6178 2015-01-21 23:32:52Z bmribler $
  *********************************************************************/
 
 #include <stdio.h>
@@ -495,6 +495,7 @@ vardata(vp, vdims, ncid, varid, fsp)
     long nrows;
     int vrank = vp->ndims;
     char *fixed_var;
+    int ret = 0, err_code = 0;
 
     /* printf format used to print each value */
     const char *fmt = get_fmt(ncid, varid, vp->type);
@@ -574,7 +575,20 @@ vardata(vp, vdims, ncid, varid, fsp)
 	    long toget = left < gulp ? left : gulp;
 	    if (vrank > 0)
 	      edg[vrank-1] = toget;
-	    (void) ncvarget (ncid, varid, cor, edg, (void *) vals);
+
+	    /* ncvarget was casted to (void), thus ncdump misinformed users
+               that the reading succeeded even though the data was corrupted and
+               reading in fact failed (HDFFR-1468.)  Now when ncvarget fails,
+               break out of the while loop and set error code to indicate this
+               failure. -BMR, 2015/01/19 */
+	    ret = ncvarget (ncid, varid, cor, edg, (void *) vals);
+	    if (ret == -1)
+	    {
+		err_code = ERR_READFAIL;  /* to be returned to caller to
+					     indicate that ncvarget fails */
+		break;
+	    }
+
 	    if (fsp->full_data_cmnts)
 	      pr_cvals(vp, toget, fmt, left > toget, lastrow, (void *) vals,
 		       fsp, cor);
@@ -584,14 +598,20 @@ vardata(vp, vdims, ncid, varid, fsp)
 	    if (vrank > 0)
 	      cor[vrank-1] += toget;
 	}
-	if (vrank > 0)
-	  cor[vrank-1] = corsav;
-	if (ir < nrows-1)
-	  if (!upcorner(vdims,vp->ndims,cor,add))
-	    error("vardata: odometer overflowed!");
-	set_indent(2);
+	/* No failure occurs */
+	if (ret >= 0)
+	{
+	    if (vrank > 0)
+	      cor[vrank-1] = corsav;
+	    if (ir < nrows-1)
+	      if (!upcorner(vdims,vp->ndims,cor,add))
+	        error("vardata: odometer overflowed!");
+	    set_indent(2);
+	}
     }
 
     free(fixed_var);
-    return 0;
+    return(err_code);
+    /* Previously, it was "return 0;"  If this function is revised, this
+       return statement may be changed appropriately. (HDFFR-1468) */
 }
diff --git a/mfhdf/ncgen/CMakeLists.txt b/mfhdf/ncgen/CMakeLists.txt
index cb2690d..7fc3a79 100644
--- a/mfhdf/ncgen/CMakeLists.txt
+++ b/mfhdf/ncgen/CMakeLists.txt
@@ -9,20 +9,20 @@ INCLUDE_DIRECTORIES (
     ${CMAKE_CURRENT_SOURCE_DIR}
 )
 
-ADD_DEFINITIONS (-DHDF)
+add_definitions (-DHDF)
 
-IF (WIN32 AND NOT CYGWIN)
+if (WIN32)
   ADD_DEFINITIONS(-DDOS_FS)
-ENDIF (WIN32 AND NOT CYGWIN)
+endif (WIN32)
 
-IF (HDF4_BUILD_XDR_LIB)
-  IF (WIN32 AND NOT CYGWIN)
-    ADD_DEFINITIONS (-DNO_SYS_XDR_INC)
-  ENDIF (WIN32 AND NOT CYGWIN)
+if (HDF4_BUILD_XDR_LIB)
+  if (WIN32)
+    add_definitions (-DNO_SYS_XDR_INC)
+  endif (WIN32)
   INCLUDE_DIRECTORIES (${HDF4_MFHDF_XDR_DIR})
-ENDIF (HDF4_BUILD_XDR_LIB)
+endif (HDF4_BUILD_XDR_LIB)
 
-SET (ncgen_SRCS
+set (ncgen_SRCS
     ${HDF4_MFHDF_NCGEN_SOURCE_DIR}/close.c
     ${HDF4_MFHDF_NCGEN_SOURCE_DIR}/escapes.c
     ${HDF4_MFHDF_NCGEN_SOURCE_DIR}/generate.c
@@ -33,22 +33,22 @@ SET (ncgen_SRCS
     ${HDF4_MFHDF_NCGEN_SOURCE_DIR}/main.c
     ${HDF4_MFHDF_NCGEN_SOURCE_DIR}/ncgentab.c
 )
-IF (WIN32 AND NOT CYGWIN)
-  SET (ncgen_SRCS ${ncgen_SRCS} ${HDF4_SOURCE_DIR}/mfhdf/util/getopt.c)
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  set (ncgen_SRCS ${ncgen_SRCS} ${HDF4_SOURCE_DIR}/mfhdf/util/getopt.c)
+endif (WIN32)
  
 ADD_EXECUTABLE (ncgen ${ncgen_SRCS})
 TARGET_C_PROPERTIES (ncgen " " " ")
-IF (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (ncgen ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET} )
-ELSE (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (ncgen ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDIF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (ncgen ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET} )
+else (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (ncgen ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endif (HDF4_BUILD_XDR_LIB)
 TARGET_NAMING (ncgen ${LIB_TYPE})
 
-IF (BUILD_TESTING)
-  INCLUDE (CMakeTests.cmake)
-ENDIF (BUILD_TESTING)
+if (BUILD_TESTING)
+  include (CMakeTests.cmake)
+endif (BUILD_TESTING)
 
 ##############################################################################
 ##############################################################################
diff --git a/mfhdf/ncgen/CMakeTests.cmake b/mfhdf/ncgen/CMakeTests.cmake
index c271390..6acd309 100644
--- a/mfhdf/ncgen/CMakeTests.cmake
+++ b/mfhdf/ncgen/CMakeTests.cmake
@@ -6,7 +6,7 @@
 ##############################################################################
 
   # Remove any output file left over from previous test run
-  ADD_TEST (
+  add_test (
       NAME NCGEN-clearall-objects
       COMMAND    ${CMAKE_COMMAND}
           -E remove 
@@ -25,15 +25,14 @@
           test1.nc
           test2.cdl
   )
-  IF (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (NCGEN-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  ELSE (NOT "${last_test}" STREQUAL "")
-    SET_TESTS_PROPERTIES (NCGEN-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
-  ENDIF (NOT "${last_test}" STREQUAL "")
-  SET (last_test "NCGEN-clearall-objects")
+  if (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (NCGEN-clearall-objects PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  else (NOT "${last_test}" STREQUAL "")
+    set_tests_properties (NCGEN-clearall-objects PROPERTIES LABELS ${PROJECT_NAME})
+  endif (NOT "${last_test}" STREQUAL "")
+  set (last_test "NCGEN-clearall-objects")
 
-  #-- Copy all the data files from the test directory into the source directory
-  #MESSAGE (STATUS " Copying ${HDF4_MFHDF_NCGEN_SOURCE_DIR}/test0.cdl to ${PROJECT_BINARY_DIR}/")
+  #message (STATUS " Copying ${HDF4_MFHDF_NCGEN_SOURCE_DIR}/test0.cdl to ${PROJECT_BINARY_DIR}/")
   ADD_CUSTOM_COMMAND (
       TARGET     ncgen
       POST_BUILD
@@ -42,14 +41,14 @@
   )
 
 #-- Adding test for ncgen
-ADD_TEST (
+add_test (
     NAME NCGEN-test0.nc
     COMMAND $<TARGET_FILE:ncgen> -b -o test0.nc test0.cdl
 )
-SET_TESTS_PROPERTIES (NCGEN-test0.nc PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-SET (last_test "NCGEN-test0.nc")
+set_tests_properties (NCGEN-test0.nc PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+set (last_test "NCGEN-test0.nc")
 
-ADD_TEST (
+add_test (
     NAME NCGEN-test1.cdl
     COMMAND "${CMAKE_COMMAND}"
         -D "TEST_PROGRAM=$<TARGET_FILE:ncdump>"
@@ -58,19 +57,19 @@ ADD_TEST (
         -D "TEST_OUTPUT=test1.cdl"
         -D "TEST_EXPECT=0"
         -D "TEST_SKIP_COMPARE=TRUE"
-        -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+        -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
 )
-SET_TESTS_PROPERTIES (NCGEN-test1.cdl PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-SET (last_test "NCGEN-test1.cdl")
+set_tests_properties (NCGEN-test1.cdl PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+set (last_test "NCGEN-test1.cdl")
 
-ADD_TEST (
+add_test (
     NAME NCGEN-test1.nc
     COMMAND $<TARGET_FILE:ncgen> -b test1.cdl
 )
-SET_TESTS_PROPERTIES (NCGEN-test1.nc PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-SET (last_test "NCGEN-test1.nc")
+set_tests_properties (NCGEN-test1.nc PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+set (last_test "NCGEN-test1.nc")
 
-ADD_TEST (
+add_test (
     NAME NCGEN-test2.cdl
     COMMAND "${CMAKE_COMMAND}"
         -D "TEST_PROGRAM=$<TARGET_FILE:ncdump>"
@@ -79,10 +78,10 @@ ADD_TEST (
         -D "TEST_OUTPUT=test2.cdl"
         -D "TEST_EXPECT=0"
         -D "TEST_REFERENCE=test1.cdl"
-        -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+        -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
 )
-SET_TESTS_PROPERTIES (NCGEN-test2.cdl PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-SET (last_test "NCGEN-test2.cdl")
+set_tests_properties (NCGEN-test2.cdl PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+set (last_test "NCGEN-test2.cdl")
 
 #
 #ctest0$(EXEEXT):        ncgen$(EXEEXT) $(srcdir)/test0.cdl
@@ -90,7 +89,7 @@ SET (last_test "NCGEN-test2.cdl")
 #    $(COMPILE) -c -o ctest0$(EXEEXT).o test0.c
 #    $(LINK) ctest0$(EXEEXT).o $(ctest0_LDADD) $(LDFLAGS) $(SHLIBLOC) $(LIBS)
 
-ADD_TEST (
+add_test (
     NAME NCGEN-ctest0
     COMMAND "${CMAKE_COMMAND}"
         -D "TEST_PROGRAM=$<TARGET_FILE:ncgen>"
@@ -99,10 +98,10 @@ ADD_TEST (
         -D "TEST_OUTPUT=test0.c"
         -D "TEST_EXPECT=0"
         -D "TEST_SKIP_COMPARE=TRUE"
-        -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+        -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
 )
-SET_TESTS_PROPERTIES (NCGEN-ctest0 PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-SET (last_test "NCGEN-ctest0")
+set_tests_properties (NCGEN-ctest0 PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+set (last_test "NCGEN-ctest0")
 #
 ## Test the "-c" option of ncgen
 #c-check:    b-check ctest0
@@ -114,12 +113,12 @@ SET (last_test "NCGEN-ctest0")
 #      echo "*** ncgen -c test failed  ***";                             \
 #    fi
 
-IF (HDF4_BUILD_FORTRAN)
+if (HDF4_BUILD_FORTRAN)
 #
 #ftest0$(EXEEXT):        ncgen$(EXEEXT) test0.cdl netcdf.inc
 #    $(TESTS_ENVIRONMENT) ./ncgen -f -o ftest0.nc $(srcdir)/test0.cdl > test0.f
 #    $(F77) $(FFLAGS) -o $@ test0.f $(LDFLAGS) $(SHLIBLOC) $(LIBS)
-  ADD_TEST (
+  add_test (
       NAME NCGEN-ftest0
       COMMAND "${CMAKE_COMMAND}"
           -D "TEST_PROGRAM=$<TARGET_FILE:ncgen>"
@@ -128,10 +127,10 @@ IF (HDF4_BUILD_FORTRAN)
           -D "TEST_OUTPUT=test0.f"
           -D "TEST_EXPECT=0"
           -D "TEST_SKIP_COMPARE=TRUE"
-          -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+          -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
   )
-  SET_TESTS_PROPERTIES (NCGEN-ftest0 PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
-  SET (last_test "NCGEN-ftest0")
+  set_tests_properties (NCGEN-ftest0 PROPERTIES DEPENDS ${last_test} LABELS ${PROJECT_NAME})
+  set (last_test "NCGEN-ftest0")
 # Test the "-f" option of ncgen
 #f-check:    b-check ftest0
 #    $(TESTS_ENVIRONMENT) ./ftest0
@@ -141,4 +140,4 @@ IF (HDF4_BUILD_FORTRAN)
 #    else                                                                \
 #      echo "*** ncgen -f test failed (but roundoff differences are OK) ***"; \
 #    fi
-ENDIF (HDF4_BUILD_FORTRAN)
+endif (HDF4_BUILD_FORTRAN)
diff --git a/mfhdf/ncgen/Makefile.am b/mfhdf/ncgen/Makefile.am
index a07c7a9..95e3221 100644
--- a/mfhdf/ncgen/Makefile.am
+++ b/mfhdf/ncgen/Makefile.am
@@ -11,11 +11,11 @@ else
 endif
 
 ## Setup the different includes and preprocessor #defines we need.
-INCLUDES=-I$(top_srcdir)/hdf/src        \
+ncgen_INCLUDES=-I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 DEFINES=-DNDEBUG -DHDF
-AM_CPPFLAGS=$(INCLUDES) $(DEFINES)
+AM_CPPFLAGS=$(ncgen_INCLUDES) $(DEFINES)
 
 ## Add ncgen specific linker flags here
 ncgen_LDFLAGS = $(LT_STATIC_EXEC) $(AM_LDFLAGS)
diff --git a/mfhdf/ncgen/Makefile.in b/mfhdf/ncgen/Makefile.in
index 60d773f..9ec64eb 100644
--- a/mfhdf/ncgen/Makefile.in
+++ b/mfhdf/ncgen/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -18,23 +18,51 @@
 #############################################################################
 
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -53,11 +81,11 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
 	$(srcdir)/testncgen.sh.in $(top_srcdir)/bin/depcomp \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am
+	$(top_srcdir)/bin/test-driver README
 bin_PROGRAMS = ncgen$(EXEEXT)
 @HDF_BUILD_FORTRAN_FALSE@@HDF_BUILD_NETCDF_TRUE at noinst_PROGRAMS = ctest0$(EXEEXT)
 @HDF_BUILD_FORTRAN_TRUE@@HDF_BUILD_NETCDF_TRUE at noinst_PROGRAMS = ctest0$(EXEEXT) \
@@ -81,6 +109,10 @@ PROGRAMS = $(bin_PROGRAMS) $(noinst_PROGRAMS)
 am_ctest0_OBJECTS =
 ctest0_OBJECTS = $(am_ctest0_OBJECTS)
 ctest0_DEPENDENCIES = $(LIBMFHDF) $(LIBHDF)
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
 am_ftest0_OBJECTS =
 ftest0_OBJECTS = $(am_ftest0_OBJECTS)
 ftest0_LDADD = $(LDADD)
@@ -89,22 +121,43 @@ am_ncgen_OBJECTS = close.$(OBJEXT) escapes.$(OBJEXT) \
 	init.$(OBJEXT) load.$(OBJEXT) main.$(OBJEXT) \
 	ncgentab.$(OBJEXT)
 ncgen_OBJECTS = $(am_ncgen_OBJECTS)
-ncgen_LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(ncgen_LDFLAGS) \
-	$(LDFLAGS) -o $@
+ncgen_LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(ncgen_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 SOURCES = $(ctest0_SOURCES) $(ftest0_SOURCES) $(ncgen_SOURCES)
 DIST_SOURCES = $(ctest0_SOURCES) $(ftest0_SOURCES) $(ncgen_SOURCES)
 am__can_run_installinfo = \
@@ -142,15 +195,202 @@ am__uninstall_files_from_dir = { \
 man1dir = $(mandir)/man1
 NROFF = nroff
 MANS = $(man1_MANS)
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
+TEST_SUITE_LOG = test-suite.log
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -235,6 +475,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -324,12 +565,12 @@ CHECK_CLEANFILES = *.chkexe *.chklog ctest1.cdl ftest1.cdl test0.nc \
 	test1.cdl test1.nc test2.cdl
 @HDF_BUILD_SHARED_FALSE at SHLIBLOC = $(top_builddir)/mfhdf/libsrc/.libs/libmfhdf.a $(top_builddir)/hdf/src/.libs/libdf.a
 @HDF_BUILD_SHARED_TRUE at SHLIBLOC = $(top_builddir)/mfhdf/libsrc/.libs/libmfhdf.$(SHARED_EXTENSION) $(top_builddir)/hdf/src/.libs/libdf.$(SHARED_EXTENSION)
-INCLUDES = -I$(top_srcdir)/hdf/src        \
+ncgen_INCLUDES = -I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 
 DEFINES = -DNDEBUG -DHDF
-AM_CPPFLAGS = $(INCLUDES) $(DEFINES)
+AM_CPPFLAGS = $(ncgen_INCLUDES) $(DEFINES)
 ncgen_LDFLAGS = $(LT_STATIC_EXEC) $(AM_LDFLAGS)
 ncgen_SOURCES = close.c escapes.c generate.c genlib.c getfill.c init.c      \
                 load.c main.c ncgentab.c
@@ -373,7 +614,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
-.SUFFIXES: .c .lo .o .obj
+.SUFFIXES: .c .lo .log .o .obj .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -416,10 +657,12 @@ install-binPROGRAMS: $(bin_PROGRAMS)
 	fi; \
 	for p in $$list; do echo "$$p $$p"; done | \
 	sed 's/$(EXEEXT)$$//' | \
-	while read p p1; do if test -f $$p || test -f $$p1; \
-	  then echo "$$p"; echo "$$p"; else :; fi; \
+	while read p p1; do if test -f $$p \
+	 || test -f $$p1 \
+	  ; then echo "$$p"; echo "$$p"; else :; fi; \
 	done | \
-	sed -e 'p;s,.*/,,;n;h' -e 's|.*|.|' \
+	sed -e 'p;s,.*/,,;n;h' \
+	    -e 's|.*|.|' \
 	    -e 'p;x;s,.*/,,;s/$(EXEEXT)$$//;$(transform);s/$$/$(EXEEXT)/' | \
 	sed 'N;N;N;s,\n, ,g' | \
 	$(AWK) 'BEGIN { files["."] = ""; dirs["."] = 1 } \
@@ -440,7 +683,8 @@ uninstall-binPROGRAMS:
 	@list='$(bin_PROGRAMS)'; test -n "$(bindir)" || list=; \
 	files=`for p in $$list; do echo "$$p"; done | \
 	  sed -e 'h;s,^.*/,,;s/$(EXEEXT)$$//;$(transform)' \
-	      -e 's/$$/$(EXEEXT)/' `; \
+	      -e 's/$$/$(EXEEXT)/' \
+	`; \
 	test -n "$$list" || exit 0; \
 	echo " ( cd '$(DESTDIR)$(bindir)' && rm -f" $$files ")"; \
 	cd "$(DESTDIR)$(bindir)" && rm -f $$files
@@ -471,15 +715,18 @@ clean-noinstPROGRAMS:
 	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
 	echo " rm -f" $$list; \
 	rm -f $$list
+
 @HDF_BUILD_FORTRAN_FALSE at ftest0$(EXEEXT): $(ftest0_OBJECTS) $(ftest0_DEPENDENCIES) $(EXTRA_ftest0_DEPENDENCIES) 
 @HDF_BUILD_FORTRAN_FALSE@	@rm -f ftest0$(EXEEXT)
- at HDF_BUILD_FORTRAN_FALSE@	$(LINK) $(ftest0_OBJECTS) $(ftest0_LDADD) $(LIBS)
+ at HDF_BUILD_FORTRAN_FALSE@	$(AM_V_CCLD)$(LINK) $(ftest0_OBJECTS) $(ftest0_LDADD) $(LIBS)
+
 @HDF_BUILD_NETCDF_FALSE at ftest0$(EXEEXT): $(ftest0_OBJECTS) $(ftest0_DEPENDENCIES) $(EXTRA_ftest0_DEPENDENCIES) 
 @HDF_BUILD_NETCDF_FALSE@	@rm -f ftest0$(EXEEXT)
- at HDF_BUILD_NETCDF_FALSE@	$(LINK) $(ftest0_OBJECTS) $(ftest0_LDADD) $(LIBS)
+ at HDF_BUILD_NETCDF_FALSE@	$(AM_V_CCLD)$(LINK) $(ftest0_OBJECTS) $(ftest0_LDADD) $(LIBS)
+
 ncgen$(EXEEXT): $(ncgen_OBJECTS) $(ncgen_DEPENDENCIES) $(EXTRA_ncgen_DEPENDENCIES) 
 	@rm -f ncgen$(EXEEXT)
-	$(ncgen_LINK) $(ncgen_OBJECTS) $(ncgen_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(ncgen_LINK) $(ncgen_OBJECTS) $(ncgen_LDADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -498,25 +745,25 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/ncgentab.Po at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -565,26 +812,15 @@ uninstall-man1:
 	      -e 's,\.[0-9a-z]*$$,,;$(transform);G;s,\n,.,'`; \
 	dir='$(DESTDIR)$(man1dir)'; $(am__uninstall_files_from_dir)
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -596,15 +832,11 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -613,9 +845,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -631,20 +864,152 @@ cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all $(check_PROGRAMS) $(check_SCRIPTS)
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
-	@list='$(MANS)'; if test -n "$$list"; then \
-	  list=`for p in $$list; do \
-	    if test -f $$p; then d=; else d="$(srcdir)/"; fi; \
-	    if test -f "$$d$$p"; then echo "$$d$$p"; else :; fi; done`; \
-	  if test -n "$$list" && \
-	    grep 'ab help2man is required to generate this page' $$list >/dev/null; then \
-	    echo "error: found man pages containing the 'missing help2man' replacement text:" >&2; \
-	    grep -l 'ab help2man is required to generate this page' $$list | sed 's/^/         /' >&2; \
-	    echo "       to fix them, install help2man, remove and regenerate the man pages;" >&2; \
-	    echo "       typically 'make maintainer-clean' will remove them" >&2; \
-	    exit 1; \
-	  else :; fi; \
-	else :; fi
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	list='$(DISTFILES)'; \
@@ -703,6 +1068,9 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 
@@ -789,21 +1157,22 @@ uninstall-man: uninstall-man1
 
 .MAKE: check-am install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am all-local check check-TESTS check-am \
-	clean clean-binPROGRAMS clean-checkPROGRAMS clean-generic \
-	clean-libtool clean-noinstPROGRAMS cscopelist ctags distclean \
-	distclean-compile distclean-generic distclean-libtool \
-	distclean-tags distdir dvi dvi-am html html-am info info-am \
-	install install-am install-binPROGRAMS install-data \
-	install-data-am install-dvi install-dvi-am install-exec \
-	install-exec-am install-html install-html-am install-info \
-	install-info-am install-man install-man1 install-pdf \
-	install-pdf-am install-ps install-ps-am install-strip \
-	installcheck installcheck-am installdirs maintainer-clean \
-	maintainer-clean-generic mostlyclean mostlyclean-compile \
-	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
-	pdf-am ps ps-am tags uninstall uninstall-am \
-	uninstall-binPROGRAMS uninstall-man uninstall-man1
+.PHONY: CTAGS GTAGS TAGS all all-am all-local check check-TESTS \
+	check-am clean clean-binPROGRAMS clean-checkPROGRAMS \
+	clean-generic clean-libtool clean-noinstPROGRAMS cscopelist-am \
+	ctags ctags-am distclean distclean-compile distclean-generic \
+	distclean-libtool distclean-tags distdir dvi dvi-am html \
+	html-am info info-am install install-am install-binPROGRAMS \
+	install-data install-data-am install-dvi install-dvi-am \
+	install-exec install-exec-am install-html install-html-am \
+	install-info install-info-am install-man install-man1 \
+	install-pdf install-pdf-am install-ps install-ps-am \
+	install-strip installcheck installcheck-am installdirs \
+	maintainer-clean maintainer-clean-generic mostlyclean \
+	mostlyclean-compile mostlyclean-generic mostlyclean-libtool \
+	mostlyclean-local pdf pdf-am ps ps-am recheck tags tags-am \
+	uninstall uninstall-am uninstall-binPROGRAMS uninstall-man \
+	uninstall-man1
 
 
 @HDF_BUILD_FORTRAN_TRUE@@HDF_BUILD_NETCDF_TRUE at netcdf.inc:
diff --git a/mfhdf/ncgen/main.c b/mfhdf/ncgen/main.c
index c5bde7d..15ece31 100644
--- a/mfhdf/ncgen/main.c
+++ b/mfhdf/ncgen/main.c
@@ -1,7 +1,7 @@
 /*********************************************************************
  *   Copyright 1993, UCAR/Unidata
  *   See netcdf/COPYRIGHT file for copying and redistribution conditions.
- *   $Id: main.c 6036 2014-01-20 17:28:01Z acheng $
+ *   $Id: main.c 6173 2015-01-20 07:39:51Z bmribler $
  *********************************************************************/
 
 #include <stdio.h>
@@ -27,8 +27,17 @@ extern FILE *yyin, *yyout;
 
 void usage()
 {
-    derror("Usage: %s [-V] [ -b ] [ -c ] [ -f ] [ -o outfile]  [ file ... ]",
-	   progname);
+    /* derror("Usage: %s [-V] [ -b ] [ -c ] [ -f ] [ -o outfile]  [ file ... ]",
+	   progname); */
+
+    /* Replaced the above line with the more detailed lines below.
+       -BMR, HDFFR-1459, 2015/01/19 */
+    fprintf(stderr, "Usage: %s [-V] [ -b ] [ -c ] [ -f ] [ -o outfile] [ file ... ]\n", progname);
+    fprintf(stderr, "  [-V]\t\t   Display version of the HDF4 library and exit\n");
+    fprintf(stderr, "  [-b]\t\t   For binary netCDF output, '.nc' extension\n");
+    fprintf(stderr, "  [-c]\t\t   For C output\n");
+    fprintf(stderr, "  [-f]\t\t   For Fortran output\n");
+    fprintf(stderr, "  [-o <outfile>]   Explicitly specify output file name\n");
     exit(8);
 }
 
diff --git a/mfhdf/ncgen/testncgen.sh.in b/mfhdf/ncgen/testncgen.sh.in
old mode 100755
new mode 100644
diff --git a/mfhdf/nctest/CMakeLists.txt b/mfhdf/nctest/CMakeLists.txt
index 486fd2c..261e9e5 100644
--- a/mfhdf/nctest/CMakeLists.txt
+++ b/mfhdf/nctest/CMakeLists.txt
@@ -4,20 +4,20 @@ PROJECT (HDF4_MFHDF_NCTEST)
 INCLUDE_DIRECTORIES (${HDF4_HDFSOURCE_DIR})
 INCLUDE_DIRECTORIES (${HDF4_MFHDFSOURCE_DIR})
 
-ADD_DEFINITIONS (-DHDF)
+add_definitions (-DHDF)
 
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS)
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  add_definitions (-DDOS_FS)
+endif (WIN32)
 
-IF (HDF4_BUILD_XDR_LIB)
-  IF (WIN32 AND NOT CYGWIN)
-    ADD_DEFINITIONS (-DNO_SYS_XDR_INC)
-  ENDIF (WIN32 AND NOT CYGWIN)
+if (HDF4_BUILD_XDR_LIB)
+  if (WIN32)
+    add_definitions (-DNO_SYS_XDR_INC)
+  endif (WIN32)
   INCLUDE_DIRECTORIES (${HDF4_MFHDF_XDR_DIR})
-ENDIF (HDF4_BUILD_XDR_LIB)
+endif (HDF4_BUILD_XDR_LIB)
 
-SET (nctest_SRCS
+set (nctest_SRCS
     ${HDF4_MFHDF_NCTEST_SOURCE_DIR}/add.c
     ${HDF4_MFHDF_NCTEST_SOURCE_DIR}/atttests.c
     ${HDF4_MFHDF_NCTEST_SOURCE_DIR}/cdftests.c
@@ -42,22 +42,21 @@ SET (nctest_SRCS
   
 ADD_EXECUTABLE (nctest ${nctest_SRCS})
 TARGET_C_PROPERTIES (nctest " " " ")
-IF (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (nctest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET} )
-ELSE (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (nctest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDIF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (nctest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET} )
+else (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (nctest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endif (HDF4_BUILD_XDR_LIB)
 TARGET_NAMING (nctest ${LIB_TYPE})
  
-#-- Copy all the dat files from the test directory into the source directory
-SET (HDF4_NC_TEST_FILES
+set (HDF4_NC_TEST_FILES
     test_unlim.cdl
     test_unlim.nc
 )
  
-FOREACH (h4_file ${HDF4_NC_TEST_FILES})
-  SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
-  #MESSAGE (STATUS " Copying ${HDF4_MFHDF_NCTEST_SOURCE_DIR}/${h4_file} to ${PROJECT_BINARY_DIR}/")
+foreach (h4_file ${HDF4_NC_TEST_FILES})
+  set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+  #message (STATUS " Copying ${HDF4_MFHDF_NCTEST_SOURCE_DIR}/${h4_file} to ${PROJECT_BINARY_DIR}/")
   ADD_CUSTOM_COMMAND (
       TARGET     nctest 
       POST_BUILD
@@ -65,6 +64,6 @@ FOREACH (h4_file ${HDF4_NC_TEST_FILES})
       ARGS       -E copy_if_different ${HDF4_MFHDF_NCTEST_SOURCE_DIR}/${h4_file} ${dest}
   )
       
-ENDFOREACH (h4_file ${HDF4_NC_TEST_FILES})
+endforeach (h4_file ${HDF4_NC_TEST_FILES})
 
-INCLUDE (CMakeTests.cmake)
+include (CMakeTests.cmake)
diff --git a/mfhdf/nctest/CMakeTests.cmake b/mfhdf/nctest/CMakeTests.cmake
index c5e0dc4..e7e0123 100644
--- a/mfhdf/nctest/CMakeTests.cmake
+++ b/mfhdf/nctest/CMakeTests.cmake
@@ -6,7 +6,7 @@
 ##############################################################################
 
 # Remove any output file left over from previous test run
-ADD_TEST (
+add_test (
     NAME NC_TEST-clearall-objects
     COMMAND    ${CMAKE_COMMAND}
         -E remove 
@@ -15,5 +15,5 @@ ADD_TEST (
 )
 
 #-- Adding test for nctest
-ADD_TEST (NAME NC_TEST-nctest COMMAND $<TARGET_FILE:nctest>)
-SET_TESTS_PROPERTIES (NC_TEST-nctest PROPERTIES DEPENDS NC_TEST-clearall-objects LABELS ${PROJECT_NAME})
+add_test (NAME NC_TEST-nctest COMMAND $<TARGET_FILE:nctest>)
+set_tests_properties (NC_TEST-nctest PROPERTIES DEPENDS NC_TEST-clearall-objects LABELS ${PROJECT_NAME})
diff --git a/mfhdf/nctest/Makefile.am b/mfhdf/nctest/Makefile.am
index a46252f..cf4fc50 100644
--- a/mfhdf/nctest/Makefile.am
+++ b/mfhdf/nctest/Makefile.am
@@ -5,11 +5,11 @@
 include $(top_srcdir)/config/commence.am
 
 ## Setup the different includes and preprocessor #defines we need.
-INCLUDES=-I$(top_srcdir)/hdf/src        \
+nctest_INCLUDES=-I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 DEFINES=-DNDEBUG -DHDF
-AM_CPPFLAGS=$(INCLUDES) $(DEFINES)
+AM_CPPFLAGS=$(nctest_INCLUDES) $(DEFINES)
 
 #############################################################################
 ##                          Programs to build                              ##
diff --git a/mfhdf/nctest/Makefile.in b/mfhdf/nctest/Makefile.in
index 0bb5103..4e60508 100644
--- a/mfhdf/nctest/Makefile.in
+++ b/mfhdf/nctest/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -17,23 +17,51 @@
 #############################################################################
 #############################################################################
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -52,10 +80,10 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
-	$(top_srcdir)/bin/depcomp $(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
+	$(top_srcdir)/bin/depcomp $(top_srcdir)/bin/test-driver README
 check_PROGRAMS = nctest$(EXEEXT)
 TESTS = $(am__EXEEXT_1)
 subdir = mfhdf/nctest
@@ -75,19 +103,44 @@ am_nctest_OBJECTS = add.$(OBJEXT) atttests.$(OBJEXT) \
 	varput.$(OBJEXT) varputg.$(OBJEXT) vardef.$(OBJEXT) \
 	vartests.$(OBJEXT) vputget.$(OBJEXT) vputgetg.$(OBJEXT)
 nctest_OBJECTS = $(am_nctest_OBJECTS)
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 SOURCES = $(nctest_SOURCES)
 DIST_SOURCES = $(nctest_SOURCES)
 am__can_run_installinfo = \
@@ -95,16 +148,232 @@ am__can_run_installinfo = \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+  test -z "$$files" \
+    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+         $(am__cd) "$$dir" && rm -f $$files; }; \
+  }
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
 am__EXEEXT_1 = nctest$(EXEEXT)
+TEST_SUITE_LOG = test-suite.log
+LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -189,6 +458,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -272,12 +542,12 @@ ACLOCAL_AMFLAGS = "-I m4"
 #############################################################################
 #############################################################################
 CHECK_CLEANFILES = *.chkexe *.chklog test2.nc test.nc
-INCLUDES = -I$(top_srcdir)/hdf/src        \
+nctest_INCLUDES = -I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc   \
          -I$(top_builddir)/mfhdf/libsrc
 
 DEFINES = -DNDEBUG -DHDF
-AM_CPPFLAGS = $(INCLUDES) $(DEFINES)
+AM_CPPFLAGS = $(nctest_INCLUDES) $(DEFINES)
 
 #############################################################################
 #############################################################################
@@ -313,7 +583,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
-.SUFFIXES: .c .lo .o .obj
+.SUFFIXES: .c .lo .log .o .obj .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -354,9 +624,10 @@ clean-checkPROGRAMS:
 	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
 	echo " rm -f" $$list; \
 	rm -f $$list
+
 nctest$(EXEEXT): $(nctest_OBJECTS) $(nctest_DEPENDENCIES) $(EXTRA_nctest_DEPENDENCIES) 
 	@rm -f nctest$(EXEEXT)
-	$(LINK) $(nctest_OBJECTS) $(nctest_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(nctest_OBJECTS) $(nctest_LDADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -386,25 +657,25 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/vputgetg.Po at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -412,26 +683,15 @@ mostlyclean-libtool:
 clean-libtool:
 	-rm -rf .libs _libs
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -443,15 +703,11 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -460,9 +716,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -478,6 +735,158 @@ cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all $(check_PROGRAMS)
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+nctest.log: nctest$(EXEEXT)
+	@p='nctest$(EXEEXT)'; \
+	b='nctest'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -534,6 +943,9 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 
@@ -618,19 +1030,19 @@ uninstall-am:
 
 .MAKE: check-am install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am all-local check check-TESTS check-am \
-	clean clean-checkPROGRAMS clean-generic clean-libtool \
-	cscopelist ctags distclean distclean-compile distclean-generic \
-	distclean-libtool distclean-tags distdir dvi dvi-am html \
-	html-am info info-am install install-am install-data \
-	install-data-am install-dvi install-dvi-am install-exec \
-	install-exec-am install-html install-html-am install-info \
-	install-info-am install-man install-pdf install-pdf-am \
-	install-ps install-ps-am install-strip installcheck \
-	installcheck-am installdirs maintainer-clean \
+.PHONY: CTAGS GTAGS TAGS all all-am all-local check check-TESTS \
+	check-am clean clean-checkPROGRAMS clean-generic clean-libtool \
+	cscopelist-am ctags ctags-am distclean distclean-compile \
+	distclean-generic distclean-libtool distclean-tags distdir dvi \
+	dvi-am html html-am info info-am install install-am \
+	install-data install-data-am install-dvi install-dvi-am \
+	install-exec install-exec-am install-html install-html-am \
+	install-info install-info-am install-man install-pdf \
+	install-pdf-am install-ps install-ps-am install-strip \
+	installcheck installcheck-am installdirs maintainer-clean \
 	maintainer-clean-generic mostlyclean mostlyclean-compile \
 	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
-	pdf-am ps ps-am tags uninstall uninstall-am
+	pdf-am ps ps-am recheck tags tags-am uninstall uninstall-am
 
 
 # lib/progs/tests targets recurse into subdirectories. build-* targets
diff --git a/mfhdf/nctest/driver.c b/mfhdf/nctest/driver.c
index 676f952..9199af2 100644
--- a/mfhdf/nctest/driver.c
+++ b/mfhdf/nctest/driver.c
@@ -1,7 +1,7 @@
 /*********************************************************************
  *   Copyright 1993, UCAR/Unidata
  *   See netcdf/COPYRIGHT file for copying and redistribution conditions.
- *   $Id: driver.c 6043 2014-01-21 21:09:03Z acheng $
+ *   $Id: driver.c 6180 2015-01-22 06:00:33Z bmribler $
  *********************************************************************/
 
 #include "h4config.h"
@@ -29,6 +29,7 @@ FILE *dbg_file;
 #endif
 
 #include <stdlib.h>
+#include <string.h> /* to remove warnings, HDFFR-1434 */
 
 #ifdef PROTOTYPE
 int main(int argc, char *argv[])
diff --git a/mfhdf/nctest/val.c b/mfhdf/nctest/val.c
index 52b6415..0a90fca 100644
--- a/mfhdf/nctest/val.c
+++ b/mfhdf/nctest/val.c
@@ -1,7 +1,7 @@
 /*********************************************************************
  *   Copyright 1993, UCAR/Unidata
  *   See netcdf/COPYRIGHT file for copying and redistribution conditions.
- *   $Id: val.c 4998 2007-11-16 03:14:03Z epourmal $
+ *   $Id: val.c 6141 2014-10-21 19:56:48Z bmribler $
  *********************************************************************/
 
 #include <stdio.h>
@@ -80,7 +80,7 @@ val_fill_zero(type, len, vals)
     union {
 	char *cp;
 	short *sp;
-	long *lp;
+	nclong *lp;
 	float *fp;
 	double *dp;
     } gp;
@@ -98,9 +98,9 @@ val_fill_zero(type, len, vals)
 	  *gp.sp++ = (short) 0;
 	break;
       case NC_LONG:
-	gp.lp = (long *) vals;
+	gp.lp = (nclong *) vals;
 	for (iel = 0; iel < len; iel++)
-	  *gp.lp++ = (long) 0;
+	  *gp.lp++ = (nclong) 0;
 	break;
       case NC_FLOAT:
 	gp.fp = (float *) vals;
diff --git a/mfhdf/test/CMakeLists.txt b/mfhdf/test/CMakeLists.txt
index 0d45560..96972ca 100644
--- a/mfhdf/test/CMakeLists.txt
+++ b/mfhdf/test/CMakeLists.txt
@@ -4,20 +4,20 @@ PROJECT (HDF4_MFHDF_TEST)
 INCLUDE_DIRECTORIES (${HDF4_HDFSOURCE_DIR})
 INCLUDE_DIRECTORIES (${HDF4_MFHDFSOURCE_DIR})
 
-ADD_DEFINITIONS (-DHDF)
+add_definitions (-DHDF)
 
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS)
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  add_definitions (-DDOS_FS)
+endif (WIN32)
 
-IF (HDF4_BUILD_XDR_LIB)
-  IF (WIN32 AND NOT CYGWIN)
-    ADD_DEFINITIONS (-DNO_SYS_XDR_INC)
-  ENDIF (WIN32 AND NOT CYGWIN)
+if (HDF4_BUILD_XDR_LIB)
+  if (WIN32)
+    add_definitions (-DNO_SYS_XDR_INC)
+  endif (WIN32)
   INCLUDE_DIRECTORIES (${HDF4_MFHDF_XDR_DIR})
-ENDIF (HDF4_BUILD_XDR_LIB)
+endif (HDF4_BUILD_XDR_LIB)
 
-SET (hdftest_SRCS
+set (hdftest_SRCS
     ${HDF4_MFHDF_TEST_SOURCE_DIR}/hdftest.c
     ${HDF4_MFHDF_TEST_SOURCE_DIR}/tchunk.c
     ${HDF4_MFHDF_TEST_SOURCE_DIR}/tcomp.c
@@ -39,74 +39,74 @@ SET (hdftest_SRCS
 )
 
 #-- Adding test for hdftest
-ADD_EXECUTABLE (hdftest ${hdftest_SRCS})
+add_executable (hdftest ${hdftest_SRCS})
 TARGET_NAMING (hdftest ${LIB_TYPE})
 TARGET_C_PROPERTIES (hdftest " " " ")
-IF (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (hdftest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET} ${LINK_LIBS})
-ELSE (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (hdftest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDIF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (hdftest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${HDF4_MF_XDR_LIB_TARGET} ${LINK_LIBS})
+else (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (hdftest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endif (HDF4_BUILD_XDR_LIB)
 
 #-- Copy all the dat files from the test directory into the source directory
-SET (HDF4_REFERENCE_TEST_FILES
+set (HDF4_REFERENCE_TEST_FILES
     sds_szipped.dat
     smallslice.0000.nc
     test1.nc
 )
 
-FOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
-   SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+foreach (h4_file ${HDF4_REFERENCE_TEST_FILES})
+   set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
    #MESSAGE(STATUS " Copying ${HDF4_MFHDF_TEST_DIR}/${h4_file} to ${PROJECT_BINARY_DIR}/")
-   ADD_CUSTOM_COMMAND (
+   add_custom_command (
      TARGET     hdftest
      POST_BUILD
      COMMAND    ${CMAKE_COMMAND}
      ARGS       -E copy_if_different ${HDF4_MFHDF_TEST_DIR}/${h4_file} ${dest}
-     )
-ENDFOREACH (h4_file ${HDF4_REFERENCE_TEST_FILES})
+   )
+endforeach (h4_file ${HDF4_REFERENCE_TEST_FILES})
 
 #-- Adding test for cdftest
-ADD_EXECUTABLE (cdftest ${HDF4_MFHDF_TEST_SOURCE_DIR}/cdftest.c)
+add_executable (cdftest ${HDF4_MFHDF_TEST_SOURCE_DIR}/cdftest.c)
 TARGET_NAMING (cdftest ${LIB_TYPE})
 TARGET_C_PROPERTIES (cdftest " " " ")
-IF (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (cdftest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-ELSE (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (cdftest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDIF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (cdftest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+else (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (cdftest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endif (HDF4_BUILD_XDR_LIB)
 
 #-- Copy all the dat files from the test directory into the source directory
-SET (HDF4_REFERENCE2_TEST_FILES
+set (HDF4_REFERENCE2_TEST_FILES
     testout.sav
 )
 
-FOREACH (h4_file ${HDF4_REFERENCE2_TEST_FILES})
-   SET (dest "${PROJECT_BINARY_DIR}/${h4_file}")
+foreach (h4_file ${HDF4_REFERENCE2_TEST_FILES})
+   set (dest "${PROJECT_BINARY_DIR}/${h4_file}")
    #MESSAGE(STATUS " Copying ${HDF4_MFHDF_TEST_DIR}/${h4_file} to ${PROJECT_BINARY_DIR}/")
-   ADD_CUSTOM_COMMAND (
+   add_custom_command (
      TARGET     cdftest
      POST_BUILD
      COMMAND    ${CMAKE_COMMAND}
      ARGS       -E copy_if_different ${HDF4_MFHDF_TEST_DIR}/${h4_file} ${dest}
-     )
-ENDFOREACH (h4_file ${HDF4_REFERENCE2_TEST_FILES})
+   )
+endforeach (h4_file ${HDF4_REFERENCE2_TEST_FILES})
 
 #-- Adding test for hdfnctest
-SET (hdfnctest_SRCS
+set (hdfnctest_SRCS
     ${HDF4_MFHDF_TEST_SOURCE_DIR}/hdfnctest.c
     ${HDF4_MFHDF_TEST_SOURCE_DIR}/tunlim.c
     ${HDF4_MFHDF_TEST_SOURCE_DIR}/tncunlim.c
     ${HDF4_MFHDF_TEST_SOURCE_DIR}/tncvargetfill.c
 )
 
-ADD_EXECUTABLE (hdfnctest ${hdfnctest_SRCS})
+add_executable (hdfnctest ${hdfnctest_SRCS})
 TARGET_NAMING (hdfnctest ${LIB_TYPE})
 TARGET_C_PROPERTIES (hdfnctest " " " ")
-IF (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (hdfnctest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
-ELSE (HDF4_BUILD_XDR_LIB)
-  TARGET_LINK_LIBRARIES (hdfnctest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
-ENDIF (HDF4_BUILD_XDR_LIB)
+if (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (hdfnctest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+else (HDF4_BUILD_XDR_LIB)
+  target_link_libraries (hdfnctest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS})
+endif (HDF4_BUILD_XDR_LIB)
 
-INCLUDE (CMakeTests.cmake)
+include (CMakeTests.cmake)
diff --git a/mfhdf/test/CMakeTests.cmake b/mfhdf/test/CMakeTests.cmake
index 15690bd..bf368bb 100644
--- a/mfhdf/test/CMakeTests.cmake
+++ b/mfhdf/test/CMakeTests.cmake
@@ -11,7 +11,7 @@
 ##############################################################################
 ##############################################################################
 # Remove any output file left over from previous test run
-ADD_TEST (
+add_test (
     NAME MFHDF_TEST-clearall-objects
     COMMAND    ${CMAKE_COMMAND}
         -E remove 
@@ -71,54 +71,54 @@ ADD_TEST (
         tdfansdg.hdf
 )
 
-ADD_TEST (NAME hdftest COMMAND $<TARGET_FILE:hdftest>)
-SET (passRegex "HDF-SD test passes")
-SET_PROPERTY (TEST hdftest PROPERTY PASS_REGULAR_EXPRESSION "${passRegex}")
-SET_TESTS_PROPERTIES (hdftest PROPERTIES DEPENDS MFHDF_TEST-clearall-objects LABELS ${PROJECT_NAME})
+add_test (NAME hdftest COMMAND $<TARGET_FILE:hdftest>)
+set (passRegex "HDF-SD test passes")
+set_property (TEST hdftest PROPERTY PASS_REGULAR_EXPRESSION "${passRegex}")
+set_tests_properties (hdftest PROPERTIES DEPENDS MFHDF_TEST-clearall-objects LABELS ${PROJECT_NAME})
 
-ADD_TEST (NAME cdftest COMMAND "${CMAKE_COMMAND}"
+add_test (NAME cdftest COMMAND "${CMAKE_COMMAND}"
             -D "TEST_PROGRAM=$<TARGET_FILE:cdftest>"
             -D "TEST_ARGS:STRING="
             -D "TEST_FOLDER=${PROJECT_BINARY_DIR}"
             -D "TEST_OUTPUT=cdfout.new"
             -D "TEST_EXPECT=0"
             -D "TEST_REFERENCE=testout.sav"
-            -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+            -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
 )
-SET_TESTS_PROPERTIES (cdftest PROPERTIES DEPENDS hdftest LABELS ${PROJECT_NAME})
+set_tests_properties (cdftest PROPERTIES DEPENDS hdftest LABELS ${PROJECT_NAME})
 
-ADD_TEST (NAME hdfnctest COMMAND $<TARGET_FILE:hdfnctest>)
-SET (NCpassRegex "HDF-nc test passes")
-SET_PROPERTY (TEST hdfnctest PROPERTY PASS_REGULAR_EXPRESSION "${NCpassRegex}")
-SET_TESTS_PROPERTIES (hdfnctest PROPERTIES DEPENDS cdftest LABELS ${PROJECT_NAME})
+add_test (NAME hdfnctest COMMAND $<TARGET_FILE:hdfnctest>)
+set (NCpassRegex "HDF-nc test passes")
+set_property (TEST hdfnctest PROPERTY PASS_REGULAR_EXPRESSION "${NCpassRegex}")
+set_tests_properties (hdfnctest PROPERTIES DEPENDS cdftest LABELS ${PROJECT_NAME})
 
 #-- Adding test for xdrtest
-IF (HDF4_BUILD_XDR_LIB)
-  ADD_EXECUTABLE (xdrtest ${HDF4_MFHDF_XDR_DIR}/xdrtest.c)
+if (HDF4_BUILD_XDR_LIB)
+  add_executable (xdrtest ${HDF4_MFHDF_XDR_DIR}/xdrtest.c)
   TARGET_NAMING (xdrtest ${LIB_TYPE})
   TARGET_C_PROPERTIES (xdrtest " " " ")
-  TARGET_LINK_LIBRARIES (xdrtest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
+  target_link_libraries (xdrtest ${HDF4_MF_LIB_TARGET} ${HDF4_SRC_LIB_TARGET} ${LINK_LIBS} ${HDF4_MF_XDR_LIB_TARGET})
 
-  IF (CYGWIN)
-    ADD_CUSTOM_COMMAND (
+  if (CYGWIN)
+    add_custom_command (
         TARGET     xdrtest 
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_MFHDF_XDR_DIR}/xdrtest.cyg ${PROJECT_BINARY_DIR}/xdrtest.out
     )
-  ELSE (CYGWIN)
-    ADD_CUSTOM_COMMAND (
+  else (CYGWIN)
+    add_custom_command (
         TARGET     xdrtest 
         POST_BUILD
         COMMAND    ${CMAKE_COMMAND}
         ARGS       -E copy_if_different ${HDF4_MFHDF_XDR_DIR}/xdrtest.out ${PROJECT_BINARY_DIR}/xdrtest.out
     )
-  ENDIF (CYGWIN)
+  endif (CYGWIN)
 
-  IF (HDF4_ENABLE_USING_MEMCHECKER)
-    ADD_TEST (NAME xdrtest COMMAND $<TARGET_FILE:xdrtest>)
-  ELSE (HDF4_ENABLE_USING_MEMCHECKER)
-    ADD_TEST (
+  if (HDF4_ENABLE_USING_MEMCHECKER)
+    add_test (NAME xdrtest COMMAND $<TARGET_FILE:xdrtest>)
+  else (HDF4_ENABLE_USING_MEMCHECKER)
+    add_test (
         NAME xdrtest
         COMMAND "${CMAKE_COMMAND}"
             -D "TEST_PROGRAM=$<TARGET_FILE:xdrtest>"
@@ -127,8 +127,8 @@ IF (HDF4_BUILD_XDR_LIB)
             -D "TEST_OUTPUT=xdrtest.tst"
             -D "TEST_EXPECT=0"
             -D "TEST_REFERENCE=xdrtest.out"
-            -P "${HDF4_RESOURCES_DIR}/runTest.cmake"
+            -P "${HDF_RESOURCES_EXT_DIR}/runTest.cmake"
     )
-  ENDIF (HDF4_ENABLE_USING_MEMCHECKER)
-  SET_TESTS_PROPERTIES (xdrtest PROPERTIES DEPENDS hdfnctest LABELS ${PROJECT_NAME})
-ENDIF (HDF4_BUILD_XDR_LIB)
+  endif (HDF4_ENABLE_USING_MEMCHECKER)
+  set_tests_properties (xdrtest PROPERTIES DEPENDS hdfnctest LABELS ${PROJECT_NAME})
+endif (HDF4_BUILD_XDR_LIB)
diff --git a/mfhdf/test/Makefile.am b/mfhdf/test/Makefile.am
index c9bc063..fa92771 100644
--- a/mfhdf/test/Makefile.am
+++ b/mfhdf/test/Makefile.am
@@ -5,11 +5,11 @@
 include $(top_srcdir)/config/commence.am
 
 ## Setup the different includes and preprocessor #defines we need.
-INCLUDES=-I$(top_srcdir)/hdf/src        \
+test_INCLUDES=-I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc	\
 	 -I$(top_builddir)/mfhdf/libsrc
 DEFINES=-DNDEBUG -DHDF
-AM_CPPFLAGS=$(INCLUDES) $(DEFINES)
+AM_CPPFLAGS=$(test_INCLUDES) $(DEFINES)
 
 #############################################################################
 ##                              Testing                                    ##
diff --git a/mfhdf/test/Makefile.in b/mfhdf/test/Makefile.in
index a6ceaf3..8007c1d 100644
--- a/mfhdf/test/Makefile.in
+++ b/mfhdf/test/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -17,23 +17,51 @@
 #############################################################################
 #############################################################################
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -52,11 +80,11 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
 	$(srcdir)/testmfhdf.sh.in $(top_srcdir)/bin/depcomp \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am
+	$(top_srcdir)/bin/test-driver
 check_PROGRAMS = cdftest$(EXEEXT) hdfnctest$(EXEEXT) hdftest$(EXEEXT)
 TESTS = $(am__EXEEXT_1) $(TEST_SCRIPT)
 subdir = mfhdf/test
@@ -71,6 +99,10 @@ CONFIG_CLEAN_VPATH_FILES =
 am_cdftest_OBJECTS = cdftest.$(OBJEXT)
 cdftest_OBJECTS = $(am_cdftest_OBJECTS)
 cdftest_DEPENDENCIES = $(LIBMFHDF) $(LIBHDF)
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
 am_hdfnctest_OBJECTS = hdfnctest.$(OBJEXT) tutils.$(OBJEXT) \
 	tncvargetfill.$(OBJEXT) tunlim.$(OBJEXT) tncunlim.$(OBJEXT)
 hdfnctest_OBJECTS = $(am_hdfnctest_OBJECTS)
@@ -84,19 +116,40 @@ am_hdftest_OBJECTS = hdftest.$(OBJEXT) tutils.$(OBJEXT) \
 	tdatasizes.$(OBJEXT)
 hdftest_OBJECTS = $(am_hdftest_OBJECTS)
 hdftest_DEPENDENCIES = $(LIBMFHDF) $(LIBHDF)
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 SOURCES = $(cdftest_SOURCES) $(hdfnctest_SOURCES) $(hdftest_SOURCES)
 DIST_SOURCES = $(cdftest_SOURCES) $(hdfnctest_SOURCES) \
 	$(hdftest_SOURCES)
@@ -105,16 +158,232 @@ am__can_run_installinfo = \
     n|no|NO) false;; \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+    $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+    *) f=$$p;; \
+  esac;
+am__strip_dir = f=`echo $$p | sed -e 's|^.*/||'`;
+am__install_max = 40
+am__nobase_strip_setup = \
+  srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*|]/\\\\&/g'`
+am__nobase_strip = \
+  for p in $$list; do echo "$$p"; done | sed -e "s|$$srcdirstrip/||"
+am__nobase_list = $(am__nobase_strip_setup); \
+  for p in $$list; do echo "$$p $$p"; done | \
+  sed "s| $$srcdirstrip/| |;"' / .*\//!s/ .*/ ./; s,\( .*\)/[^/]*$$,\1,' | \
+  $(AWK) 'BEGIN { files["."] = "" } { files[$$2] = files[$$2] " " $$1; \
+    if (++n[$$2] == $(am__install_max)) \
+      { print $$2, files[$$2]; n[$$2] = 0; files[$$2] = "" } } \
+    END { for (dir in files) print dir, files[dir] }'
+am__base_list = \
+  sed '$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;$$!N;s/\n/ /g' | \
+  sed '$$!N;$$!N;$$!N;$$!N;s/\n/ /g'
+am__uninstall_files_from_dir = { \
+  test -z "$$files" \
+    || { test ! -d "$$dir" && test ! -f "$$dir" && test ! -r "$$dir"; } \
+    || { echo " ( cd '$$dir' && rm -f" $$files ")"; \
+         $(am__cd) "$$dir" && rm -f $$files; }; \
+  }
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
 am__EXEEXT_1 = cdftest$(EXEEXT) hdfnctest$(EXEEXT) hdftest$(EXEEXT)
+TEST_SUITE_LOG = test-suite.log
+LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -199,6 +468,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -284,12 +554,12 @@ ACLOCAL_AMFLAGS = "-I m4"
 CHECK_CLEANFILES = *.chkexe *.chklog *.new *.hdf *.cdf *.cdl netcdf.h \
 	This* onedimmultivars.nc onedimonevar.nc multidimvar.nc \
 	SD_externals
-INCLUDES = -I$(top_srcdir)/hdf/src        \
+test_INCLUDES = -I$(top_srcdir)/hdf/src        \
          -I$(top_srcdir)/mfhdf/libsrc	\
 	 -I$(top_builddir)/mfhdf/libsrc
 
 DEFINES = -DNDEBUG -DHDF
-AM_CPPFLAGS = $(INCLUDES) $(DEFINES)
+AM_CPPFLAGS = $(test_INCLUDES) $(DEFINES)
 
 #############################################################################
 #############################################################################
@@ -330,7 +600,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
-.SUFFIXES: .c .lo .o .obj
+.SUFFIXES: .c .lo .log .o .obj .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -373,15 +643,18 @@ clean-checkPROGRAMS:
 	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
 	echo " rm -f" $$list; \
 	rm -f $$list
+
 cdftest$(EXEEXT): $(cdftest_OBJECTS) $(cdftest_DEPENDENCIES) $(EXTRA_cdftest_DEPENDENCIES) 
 	@rm -f cdftest$(EXEEXT)
-	$(LINK) $(cdftest_OBJECTS) $(cdftest_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(cdftest_OBJECTS) $(cdftest_LDADD) $(LIBS)
+
 hdfnctest$(EXEEXT): $(hdfnctest_OBJECTS) $(hdfnctest_DEPENDENCIES) $(EXTRA_hdfnctest_DEPENDENCIES) 
 	@rm -f hdfnctest$(EXEEXT)
-	$(LINK) $(hdfnctest_OBJECTS) $(hdfnctest_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(hdfnctest_OBJECTS) $(hdfnctest_LDADD) $(LIBS)
+
 hdftest$(EXEEXT): $(hdftest_OBJECTS) $(hdftest_DEPENDENCIES) $(EXTRA_hdftest_DEPENDENCIES) 
 	@rm -f hdftest$(EXEEXT)
-	$(LINK) $(hdftest_OBJECTS) $(hdftest_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(hdftest_OBJECTS) $(hdftest_LDADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -414,25 +687,25 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/tutils.Po at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -440,26 +713,15 @@ mostlyclean-libtool:
 clean-libtool:
 	-rm -rf .libs _libs
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -471,15 +733,11 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -488,9 +746,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -506,6 +765,172 @@ cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all $(check_PROGRAMS) $(check_SCRIPTS)
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+cdftest.log: cdftest$(EXEEXT)
+	@p='cdftest$(EXEEXT)'; \
+	b='cdftest'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+hdfnctest.log: hdfnctest$(EXEEXT)
+	@p='hdfnctest$(EXEEXT)'; \
+	b='hdfnctest'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+hdftest.log: hdftest$(EXEEXT)
+	@p='hdftest$(EXEEXT)'; \
+	b='hdftest'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -562,6 +987,9 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 
@@ -646,19 +1074,19 @@ uninstall-am:
 
 .MAKE: check-am install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am all-local check check-TESTS check-am \
-	clean clean-checkPROGRAMS clean-generic clean-libtool \
-	cscopelist ctags distclean distclean-compile distclean-generic \
-	distclean-libtool distclean-tags distdir dvi dvi-am html \
-	html-am info info-am install install-am install-data \
-	install-data-am install-dvi install-dvi-am install-exec \
-	install-exec-am install-html install-html-am install-info \
-	install-info-am install-man install-pdf install-pdf-am \
-	install-ps install-ps-am install-strip installcheck \
-	installcheck-am installdirs maintainer-clean \
+.PHONY: CTAGS GTAGS TAGS all all-am all-local check check-TESTS \
+	check-am clean clean-checkPROGRAMS clean-generic clean-libtool \
+	cscopelist-am ctags ctags-am distclean distclean-compile \
+	distclean-generic distclean-libtool distclean-tags distdir dvi \
+	dvi-am html html-am info info-am install install-am \
+	install-data install-data-am install-dvi install-dvi-am \
+	install-exec install-exec-am install-html install-html-am \
+	install-info install-info-am install-man install-pdf \
+	install-pdf-am install-ps install-ps-am install-strip \
+	installcheck installcheck-am installdirs maintainer-clean \
 	maintainer-clean-generic mostlyclean mostlyclean-compile \
 	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
-	pdf-am ps ps-am tags uninstall uninstall-am
+	pdf-am ps ps-am recheck tags tags-am uninstall uninstall-am
 
 
 # lib/progs/tests targets recurse into subdirectories. build-* targets
diff --git a/mfhdf/test/tdatainfo.c b/mfhdf/test/tdatainfo.c
index 50bfd11..c49c184 100644
--- a/mfhdf/test/tdatainfo.c
+++ b/mfhdf/test/tdatainfo.c
@@ -37,7 +37,7 @@
 #include <unistd.h>
 #endif
 
-#if WIN32
+#ifdef _WIN32
 #define snprintf sprintf_s
 #define ssize_t int32
 #endif 
diff --git a/mfhdf/test/testmfhdf.sh.in b/mfhdf/test/testmfhdf.sh.in
old mode 100755
new mode 100644
diff --git a/mfhdf/xdr/CMakeLists.txt b/mfhdf/xdr/CMakeLists.txt
index 5f9ca90..20855ac 100644
--- a/mfhdf/xdr/CMakeLists.txt
+++ b/mfhdf/xdr/CMakeLists.txt
@@ -1,14 +1,14 @@
 cmake_minimum_required (VERSION 2.8.10)
 PROJECT (HDF4_MFHDF_XDR C CXX)
 
-SET (HDF4_MFHDF_XDR_SRCS
+set (HDF4_MFHDF_XDR_SRCS
     ${HDF4_MFHDF_XDR_SOURCE_DIR}/xdr.c
     ${HDF4_MFHDF_XDR_SOURCE_DIR}/xdrfloat.c
     ${HDF4_MFHDF_XDR_SOURCE_DIR}/xdrstdio.c
     ${HDF4_MFHDF_XDR_SOURCE_DIR}/xdrarray.c
 )
 
-SET (HDF4_MFHDF_XDR_HDRS
+set (HDF4_MFHDF_XDR_HDRS
     ${HDF4_MFHDF_XDR_SOURCE_DIR}/xdr.h
     ${HDF4_MFHDF_XDR_SOURCE_DIR}/types.h
 )
@@ -16,28 +16,28 @@ SET (HDF4_MFHDF_XDR_HDRS
 INCLUDE_DIRECTORIES (${HDF4_HDFSOURCE_DIR})
 INCLUDE_DIRECTORIES (${HDF4_MFHDF_XDR_DIR})
 
-ADD_DEFINITIONS (-DHDF)
+add_definitions (-DHDF)
 
-IF (WIN32 AND NOT CYGWIN)
-  ADD_DEFINITIONS (-DDOS_FS -DNO_SYS_XDR_INC)
-ENDIF (WIN32 AND NOT CYGWIN)
+if (WIN32)
+  add_definitions (-DDOS_FS -DNO_SYS_XDR_INC)
+endif (WIN32)
 
-IF (MSVC)
-  ADD_LIBRARY (${HDF4_MF_XDR_LIB_TARGET} ${LIB_TYPE} ${HDF4_MFHDF_XDR_SRCS} ${HDF4_MFHDF_XDR_HDRS})
-  TARGET_LINK_LIBRARIES (${HDF4_MF_XDR_LIB_TARGET} "ws2_32.lib")
-ELSE (MSVC)
-  ADD_LIBRARY (${HDF4_MF_XDR_LIB_TARGET} ${LIB_TYPE} ${HDF4_MFHDF_XDR_SRCS} ${HDF4_MFHDF_XDR_HDRS} )
-ENDIF (MSVC)
+if (MSVC OR MINGW)
+  add_library (${HDF4_MF_XDR_LIB_TARGET} ${LIB_TYPE} ${HDF4_MFHDF_XDR_SRCS} ${HDF4_MFHDF_XDR_HDRS})
+  target_link_libraries (${HDF4_MF_XDR_LIB_TARGET} "ws2_32.lib")
+else (MSVC OR MINGW)
+  add_library (${HDF4_MF_XDR_LIB_TARGET} ${LIB_TYPE} ${HDF4_MFHDF_XDR_SRCS} ${HDF4_MFHDF_XDR_HDRS} )
+endif (MSVC OR MINGW)
 TARGET_C_PROPERTIES (${HDF4_MF_XDR_LIB_TARGET} " " " ")
-SET_GLOBAL_VARIABLE (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_MF_XDR_LIB_TARGET}")
+set_global_variable (HDF4_LIBRARIES_TO_EXPORT "${HDF4_LIBRARIES_TO_EXPORT};${HDF4_MF_XDR_LIB_TARGET}")
 H4_SET_LIB_OPTIONS (${HDF4_MF_XDR_LIB_TARGET} ${HDF4_MF_XDR_LIB_NAME} ${LIB_TYPE})
 
 #-----------------------------------------------------------------------------
 # Add library to CMake Install : Installs lib and cmake config info
 #-----------------------------------------------------------------------------
-IF (BUILD_SHARED_LIBS)
+if (BUILD_SHARED_LIBS)
   INSTALL_TARGET_PDB (${HDF4_MF_XDR_LIB_TARGET} ${HDF4_INSTALL_LIB_DIR} libraries)
-ENDIF (BUILD_SHARED_LIBS)
+endif (BUILD_SHARED_LIBS)
   
 INSTALL (
     TARGETS 
diff --git a/mfhdf/xdr/Makefile.am b/mfhdf/xdr/Makefile.am
index 72e6b75..eb93bcb 100644
--- a/mfhdf/xdr/Makefile.am
+++ b/mfhdf/xdr/Makefile.am
@@ -7,7 +7,7 @@
 include $(top_srcdir)/config/commence.am
 
 ## Setup the different includes and preprocessor #defines we need.
-INCLUDES=-I$(top_srcdir)/hdf/src
+AM_CPPFLAGS=-I$(top_srcdir)/hdf/src
 
 # XDR Library
 lib_LTLIBRARIES = libxdr.la
diff --git a/mfhdf/xdr/Makefile.in b/mfhdf/xdr/Makefile.in
index 131c7b2..2385193 100644
--- a/mfhdf/xdr/Makefile.in
+++ b/mfhdf/xdr/Makefile.in
@@ -1,7 +1,7 @@
-# Makefile.in generated by automake 1.12.3 from Makefile.am.
+# Makefile.in generated by automake 1.14.1 from Makefile.am.
 # @configure_input@
 
-# Copyright (C) 1994-2012 Free Software Foundation, Inc.
+# Copyright (C) 1994-2013 Free Software Foundation, Inc.
 
 # This Makefile.in is free software; the Free Software Foundation
 # gives unlimited permission to copy and/or distribute it,
@@ -20,23 +20,51 @@
 
 
 VPATH = @srcdir@
-am__make_dryrun = \
-  { \
-    am__dry=no; \
+am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
+am__make_running_with_option = \
+  case $${target_option-} in \
+      ?) ;; \
+      *) echo "am__make_running_with_option: internal error: invalid" \
+              "target option '$${target_option-}' specified" >&2; \
+         exit 1;; \
+  esac; \
+  has_opt=no; \
+  sane_makeflags=$$MAKEFLAGS; \
+  if $(am__is_gnu_make); then \
+    sane_makeflags=$$MFLAGS; \
+  else \
     case $$MAKEFLAGS in \
       *\\[\ \	]*) \
-        echo 'am--echo: ; @echo "AM"  OK' | $(MAKE) -f - 2>/dev/null \
-          | grep '^AM OK$$' >/dev/null || am__dry=yes;; \
-      *) \
-        for am__flg in $$MAKEFLAGS; do \
-          case $$am__flg in \
-            *=*|--*) ;; \
-            *n*) am__dry=yes; break;; \
-          esac; \
-        done;; \
+        bs=\\; \
+        sane_makeflags=`printf '%s\n' "$$MAKEFLAGS" \
+          | sed "s/$$bs$$bs[$$bs $$bs	]*//g"`;; \
     esac; \
-    test $$am__dry = yes; \
-  }
+  fi; \
+  skip_next=no; \
+  strip_trailopt () \
+  { \
+    flg=`printf '%s\n' "$$flg" | sed "s/$$1.*$$//"`; \
+  }; \
+  for flg in $$sane_makeflags; do \
+    test $$skip_next = yes && { skip_next=no; continue; }; \
+    case $$flg in \
+      *=*|--*) continue;; \
+        -*I) strip_trailopt 'I'; skip_next=yes;; \
+      -*I?*) strip_trailopt 'I';; \
+        -*O) strip_trailopt 'O'; skip_next=yes;; \
+      -*O?*) strip_trailopt 'O';; \
+        -*l) strip_trailopt 'l'; skip_next=yes;; \
+      -*l?*) strip_trailopt 'l';; \
+      -[dEDm]) skip_next=yes;; \
+      -[JT]) skip_next=yes;; \
+    esac; \
+    case $$flg in \
+      *$$target_option*) has_opt=yes; break;; \
+    esac; \
+  done; \
+  test $$has_opt = yes
+am__make_dryrun = (target_option=n; $(am__make_running_with_option))
+am__make_keepgoing = (target_option=k; $(am__make_running_with_option))
 pkgdatadir = $(datadir)/@PACKAGE@
 pkgincludedir = $(includedir)/@PACKAGE@
 pkglibdir = $(libdir)/@PACKAGE@
@@ -55,11 +83,11 @@ PRE_UNINSTALL = :
 POST_UNINSTALL = :
 build_triplet = @build@
 host_triplet = @host@
-DIST_COMMON = README $(include_HEADERS) $(srcdir)/Makefile.am \
-	$(srcdir)/Makefile.in $(top_srcdir)/bin/depcomp \
-	$(top_srcdir)/bin/mkinstalldirs \
-	$(top_srcdir)/config/commence.am \
-	$(top_srcdir)/config/conclude.am
+DIST_COMMON = $(top_srcdir)/config/commence.am \
+	$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
+	$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
+	$(top_srcdir)/bin/depcomp $(include_HEADERS) \
+	$(top_srcdir)/bin/test-driver README
 check_PROGRAMS = xdrtest$(EXEEXT)
 TESTS = $(am__EXEEXT_1)
 subdir = mfhdf/xdr
@@ -103,22 +131,47 @@ LTLIBRARIES = $(lib_LTLIBRARIES)
 libxdr_la_LIBADD =
 am_libxdr_la_OBJECTS = xdr.lo xdrfloat.lo xdrstdio.lo xdrarray.lo
 libxdr_la_OBJECTS = $(am_libxdr_la_OBJECTS)
+AM_V_lt = $(am__v_lt_ at AM_V@)
+am__v_lt_ = $(am__v_lt_ at AM_DEFAULT_V@)
+am__v_lt_0 = --silent
+am__v_lt_1 = 
 am_xdrtest_OBJECTS = xdrtest.$(OBJEXT)
 xdrtest_OBJECTS = $(am_xdrtest_OBJECTS)
 xdrtest_LDADD = $(LDADD)
+AM_V_P = $(am__v_P_ at AM_V@)
+am__v_P_ = $(am__v_P_ at AM_DEFAULT_V@)
+am__v_P_0 = false
+am__v_P_1 = :
+AM_V_GEN = $(am__v_GEN_ at AM_V@)
+am__v_GEN_ = $(am__v_GEN_ at AM_DEFAULT_V@)
+am__v_GEN_0 = @echo "  GEN     " $@;
+am__v_GEN_1 = 
+AM_V_at = $(am__v_at_ at AM_V@)
+am__v_at_ = $(am__v_at_ at AM_DEFAULT_V@)
+am__v_at_0 = @
+am__v_at_1 = 
 DEFAULT_INCLUDES = -I. at am__isrc@ -I$(top_builddir)/hdf/src
 depcomp = $(SHELL) $(top_srcdir)/bin/depcomp
 am__depfiles_maybe = depfiles
 am__mv = mv -f
 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
 	$(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
-LTCOMPILE = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=compile $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
-	$(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
+LTCOMPILE = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=compile $(CC) $(DEFS) \
+	$(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+	$(AM_CFLAGS) $(CFLAGS)
+AM_V_CC = $(am__v_CC_ at AM_V@)
+am__v_CC_ = $(am__v_CC_ at AM_DEFAULT_V@)
+am__v_CC_0 = @echo "  CC      " $@;
+am__v_CC_1 = 
 CCLD = $(CC)
-LINK = $(LIBTOOL) --tag=CC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) \
-	--mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) \
-	$(LDFLAGS) -o $@
+LINK = $(LIBTOOL) $(AM_V_lt) --tag=CC $(AM_LIBTOOLFLAGS) \
+	$(LIBTOOLFLAGS) --mode=link $(CCLD) $(AM_CFLAGS) $(CFLAGS) \
+	$(AM_LDFLAGS) $(LDFLAGS) -o $@
+AM_V_CCLD = $(am__v_CCLD_ at AM_V@)
+am__v_CCLD_ = $(am__v_CCLD_ at AM_DEFAULT_V@)
+am__v_CCLD_0 = @echo "  CCLD    " $@;
+am__v_CCLD_1 = 
 SOURCES = $(libxdr_la_SOURCES) $(xdrtest_SOURCES)
 DIST_SOURCES = $(libxdr_la_SOURCES) $(xdrtest_SOURCES)
 am__can_run_installinfo = \
@@ -127,16 +180,205 @@ am__can_run_installinfo = \
     *) (install-info --version) >/dev/null 2>&1;; \
   esac
 HEADERS = $(include_HEADERS)
+am__tagged_files = $(HEADERS) $(SOURCES) $(TAGS_FILES) $(LISP)
+# Read a list of newline-separated strings from the standard input,
+# and print each of them once, without duplicates.  Input order is
+# *not* preserved.
+am__uniquify_input = $(AWK) '\
+  BEGIN { nonempty = 0; } \
+  { items[$$0] = 1; nonempty = 1; } \
+  END { if (nonempty) { for (i in items) print i; }; } \
+'
+# Make sure the list of sources is unique.  This is necessary because,
+# e.g., the same source file might be shared among _SOURCES variables
+# for different programs/libraries.
+am__define_uniq_tagged_files = \
+  list='$(am__tagged_files)'; \
+  unique=`for i in $$list; do \
+    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+  done | $(am__uniquify_input)`
 ETAGS = etags
 CTAGS = ctags
 am__tty_colors_dummy = \
   mgn= red= grn= lgn= blu= brg= std=; \
   am__color_tests=no
-am__tty_colors = $(am__tty_colors_dummy)
+am__tty_colors = { \
+  $(am__tty_colors_dummy); \
+  if test "X$(AM_COLOR_TESTS)" = Xno; then \
+    am__color_tests=no; \
+  elif test "X$(AM_COLOR_TESTS)" = Xalways; then \
+    am__color_tests=yes; \
+  elif test "X$$TERM" != Xdumb && { test -t 1; } 2>/dev/null; then \
+    am__color_tests=yes; \
+  fi; \
+  if test $$am__color_tests = yes; then \
+    red=''; \
+    grn=''; \
+    lgn=''; \
+    blu=''; \
+    mgn=''; \
+    brg=''; \
+    std=''; \
+  fi; \
+}
+am__recheck_rx = ^[ 	]*:recheck:[ 	]*
+am__global_test_result_rx = ^[ 	]*:global-test-result:[ 	]*
+am__copy_in_global_log_rx = ^[ 	]*:copy-in-global-log:[ 	]*
+# A command that, given a newline-separated list of test names on the
+# standard input, print the name of the tests that are to be re-run
+# upon "make recheck".
+am__list_recheck_tests = $(AWK) '{ \
+  recheck = 1; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+        { \
+          if ((getline line2 < ($$0 ".log")) < 0) \
+	    recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[nN][Oo]/) \
+        { \
+          recheck = 0; \
+          break; \
+        } \
+      else if (line ~ /$(am__recheck_rx)[yY][eE][sS]/) \
+        { \
+          break; \
+        } \
+    }; \
+  if (recheck) \
+    print $$0; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# A command that, given a newline-separated list of test names on the
+# standard input, create the global log from their .trs and .log files.
+am__create_global_log = $(AWK) ' \
+function fatal(msg) \
+{ \
+  print "fatal: making $@: " msg | "cat >&2"; \
+  exit 1; \
+} \
+function rst_section(header) \
+{ \
+  print header; \
+  len = length(header); \
+  for (i = 1; i <= len; i = i + 1) \
+    printf "="; \
+  printf "\n\n"; \
+} \
+{ \
+  copy_in_global_log = 1; \
+  global_test_result = "RUN"; \
+  while ((rc = (getline line < ($$0 ".trs"))) != 0) \
+    { \
+      if (rc < 0) \
+         fatal("failed to read from " $$0 ".trs"); \
+      if (line ~ /$(am__global_test_result_rx)/) \
+        { \
+          sub("$(am__global_test_result_rx)", "", line); \
+          sub("[ 	]*$$", "", line); \
+          global_test_result = line; \
+        } \
+      else if (line ~ /$(am__copy_in_global_log_rx)[nN][oO]/) \
+        copy_in_global_log = 0; \
+    }; \
+  if (copy_in_global_log) \
+    { \
+      rst_section(global_test_result ": " $$0); \
+      while ((rc = (getline line < ($$0 ".log"))) != 0) \
+      { \
+        if (rc < 0) \
+          fatal("failed to read from " $$0 ".log"); \
+        print line; \
+      }; \
+      printf "\n"; \
+    }; \
+  close ($$0 ".trs"); \
+  close ($$0 ".log"); \
+}'
+# Restructured Text title.
+am__rst_title = { sed 's/.*/   &   /;h;s/./=/g;p;x;s/ *$$//;p;g' && echo; }
+# Solaris 10 'make', and several other traditional 'make' implementations,
+# pass "-e" to $(SHELL), and POSIX 2008 even requires this.  Work around it
+# by disabling -e (using the XSI extension "set +e") if it's set.
+am__sh_e_setup = case $$- in *e*) set +e;; esac
+# Default flags passed to test drivers.
+am__common_driver_flags = \
+  --color-tests "$$am__color_tests" \
+  --enable-hard-errors "$$am__enable_hard_errors" \
+  --expect-failure "$$am__expect_failure"
+# To be inserted before the command running the test.  Creates the
+# directory for the log if needed.  Stores in $dir the directory
+# containing $f, in $tst the test, in $log the log.  Executes the
+# developer- defined test setup AM_TESTS_ENVIRONMENT (if any), and
+# passes TESTS_ENVIRONMENT.  Set up options for the wrapper that
+# will run the test scripts (or their associated LOG_COMPILER, if
+# thy have one).
+am__check_pre = \
+$(am__sh_e_setup);					\
+$(am__vpath_adj_setup) $(am__vpath_adj)			\
+$(am__tty_colors);					\
+srcdir=$(srcdir); export srcdir;			\
+case "$@" in						\
+  */*) am__odir=`echo "./$@" | sed 's|/[^/]*$$||'`;;	\
+    *) am__odir=.;; 					\
+esac;							\
+test "x$$am__odir" = x"." || test -d "$$am__odir" 	\
+  || $(MKDIR_P) "$$am__odir" || exit $$?;		\
+if test -f "./$$f"; then dir=./;			\
+elif test -f "$$f"; then dir=;				\
+else dir="$(srcdir)/"; fi;				\
+tst=$$dir$$f; log='$@'; 				\
+if test -n '$(DISABLE_HARD_ERRORS)'; then		\
+  am__enable_hard_errors=no; 				\
+else							\
+  am__enable_hard_errors=yes; 				\
+fi; 							\
+case " $(XFAIL_TESTS) " in				\
+  *[\ \	]$$f[\ \	]* | *[\ \	]$$dir$$f[\ \	]*) \
+    am__expect_failure=yes;;				\
+  *)							\
+    am__expect_failure=no;;				\
+esac; 							\
+$(AM_TESTS_ENVIRONMENT) $(TESTS_ENVIRONMENT)
+# A shell command to get the names of the tests scripts with any registered
+# extension removed (i.e., equivalently, the names of the test logs, with
+# the '.log' extension removed).  The result is saved in the shell variable
+# '$bases'.  This honors runtime overriding of TESTS and TEST_LOGS.  Sadly,
+# we cannot use something simpler, involving e.g., "$(TEST_LOGS:.log=)",
+# since that might cause problem with VPATH rewrites for suffix-less tests.
+# See also 'test-harness-vpath-rewrite.sh' and 'test-trs-basic.sh'.
+am__set_TESTS_bases = \
+  bases='$(TEST_LOGS)'; \
+  bases=`for i in $$bases; do echo $$i; done | sed 's/\.log$$//'`; \
+  bases=`echo $$bases`
+RECHECK_LOGS = $(TEST_LOGS)
+AM_RECURSIVE_TARGETS = check recheck
 am__EXEEXT_1 = xdrtest$(EXEEXT)
+TEST_SUITE_LOG = test-suite.log
+LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+LOG_COMPILE = $(LOG_COMPILER) $(AM_LOG_FLAGS) $(LOG_FLAGS)
+am__set_b = \
+  case '$@' in \
+    */*) \
+      case '$*' in \
+        */*) b='$*';; \
+          *) b=`echo '$@' | sed 's/\.log$$//'`; \
+       esac;; \
+    *) \
+      b='$*';; \
+  esac
+am__test_logs1 = $(TESTS:=.log)
+am__test_logs2 = $(am__test_logs1:@EXEEXT at .log=.log)
+TEST_LOGS = $(am__test_logs2:.sh.log=.log)
+SH_LOG_DRIVER = $(SHELL) $(top_srcdir)/bin/test-driver
+SH_LOG_COMPILE = $(SH_LOG_COMPILER) $(AM_SH_LOG_FLAGS) $(SH_LOG_FLAGS)
 DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
 ACLOCAL = @ACLOCAL@
 AMTAR = @AMTAR@
+AM_DEFAULT_VERBOSITY = @AM_DEFAULT_VERBOSITY@
 AR = @AR@
 AUTOCONF = @AUTOCONF@
 AUTOHEADER = @AUTOHEADER@
@@ -221,6 +463,7 @@ SHELL = @SHELL@
 STATIC_EXEC = @STATIC_EXEC@
 STATIC_SHARED = @STATIC_SHARED@
 STRIP = @STRIP@
+SZIP_HAS_ENCODER = @SZIP_HAS_ENCODER@
 SZIP_INFO = @SZIP_INFO@
 TBL = @TBL@
 TEST_FORTRAN_NETCDF = @TEST_FORTRAN_NETCDF@
@@ -301,7 +544,7 @@ ACLOCAL_AMFLAGS = "-I m4"
 # .chkexe files are used to mark tests that have run successfully.
 # .chklog files are output from those tests.
 CHECK_CLEANFILES = *.chkexe *.chklog
-INCLUDES = -I$(top_srcdir)/hdf/src
+AM_CPPFLAGS = -I$(top_srcdir)/hdf/src
 
 # XDR Library
 lib_LTLIBRARIES = libxdr.la
@@ -330,7 +573,7 @@ TEST_SCRIPT_CHKSH = $(TEST_SCRIPT:=.chkexe_)
 all: all-am
 
 .SUFFIXES:
-.SUFFIXES: .c .lo .o .obj
+.SUFFIXES: .c .lo .log .o .obj .sh .sh$(EXEEXT) .trs
 $(srcdir)/Makefile.in: @MAINTAINER_MODE_TRUE@ $(srcdir)/Makefile.am $(top_srcdir)/config/commence.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
 	@for dep in $?; do \
 	  case '$(am__configure_deps)' in \
@@ -362,6 +605,7 @@ $(top_srcdir)/configure: @MAINTAINER_MODE_TRUE@ $(am__configure_deps)
 $(ACLOCAL_M4): @MAINTAINER_MODE_TRUE@ $(am__aclocal_m4_deps)
 	cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
 $(am__aclocal_m4_deps):
+
 install-libLTLIBRARIES: $(lib_LTLIBRARIES)
 	@$(NORMAL_INSTALL)
 	@list='$(lib_LTLIBRARIES)'; test -n "$(libdir)" || list=; \
@@ -396,8 +640,9 @@ clean-libLTLIBRARIES:
 	  echo rm -f $${locs}; \
 	  rm -f $${locs}; \
 	}
+
 libxdr.la: $(libxdr_la_OBJECTS) $(libxdr_la_DEPENDENCIES) $(EXTRA_libxdr_la_DEPENDENCIES) 
-	$(LINK) -rpath $(libdir) $(libxdr_la_OBJECTS) $(libxdr_la_LIBADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) -rpath $(libdir) $(libxdr_la_OBJECTS) $(libxdr_la_LIBADD) $(LIBS)
 
 clean-checkPROGRAMS:
 	@list='$(check_PROGRAMS)'; test -n "$$list" || exit 0; \
@@ -407,9 +652,10 @@ clean-checkPROGRAMS:
 	list=`for p in $$list; do echo "$$p"; done | sed 's/$(EXEEXT)$$//'`; \
 	echo " rm -f" $$list; \
 	rm -f $$list
+
 xdrtest$(EXEEXT): $(xdrtest_OBJECTS) $(xdrtest_DEPENDENCIES) $(EXTRA_xdrtest_DEPENDENCIES) 
 	@rm -f xdrtest$(EXEEXT)
-	$(LINK) $(xdrtest_OBJECTS) $(xdrtest_LDADD) $(LIBS)
+	$(AM_V_CCLD)$(LINK) $(xdrtest_OBJECTS) $(xdrtest_LDADD) $(LIBS)
 
 mostlyclean-compile:
 	-rm -f *.$(OBJEXT)
@@ -424,25 +670,25 @@ distclean-compile:
 @AMDEP_TRUE@@am__include@ @am__quote at ./$(DEPDIR)/xdrtest.Po at am__quote@
 
 .c.o:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ $<
 
 .c.obj:
- at am__fastdepCC_TRUE@	$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(COMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Po
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=no @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(COMPILE) -c `$(CYGPATH_W) '$<'`
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(COMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
 
 .c.lo:
- at am__fastdepCC_TRUE@	$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
- at am__fastdepCC_TRUE@	$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
- at AMDEP_TRUE@@am__fastdepCC_FALSE@	source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
+ at am__fastdepCC_TRUE@	$(AM_V_CC)$(LTCOMPILE) -MT $@ -MD -MP -MF $(DEPDIR)/$*.Tpo -c -o $@ $<
+ at am__fastdepCC_TRUE@	$(AM_V_at)$(am__mv) $(DEPDIR)/$*.Tpo $(DEPDIR)/$*.Plo
+ at AMDEP_TRUE@@am__fastdepCC_FALSE@	$(AM_V_CC)source='$<' object='$@' libtool=yes @AMDEPBACKSLASH@
 @AMDEP_TRUE@@am__fastdepCC_FALSE@	DEPDIR=$(DEPDIR) $(CCDEPMODE) $(depcomp) @AMDEPBACKSLASH@
- at am__fastdepCC_FALSE@	$(LTCOMPILE) -c -o $@ $<
+ at am__fastdepCC_FALSE@	$(AM_V_CC at am__nodep@)$(LTCOMPILE) -c -o $@ $<
 
 mostlyclean-libtool:
 	-rm -f *.lo
@@ -471,26 +717,15 @@ uninstall-includeHEADERS:
 	files=`for p in $$list; do echo $$p; done | sed -e 's|^.*/||'`; \
 	dir='$(DESTDIR)$(includedir)'; $(am__uninstall_files_from_dir)
 
-ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
-	list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
-	mkid -fID $$unique
-tags: TAGS
-
-TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
+ID: $(am__tagged_files)
+	$(am__define_uniq_tagged_files); mkid -fID $$unique
+tags: tags-am
+TAGS: tags
+
+tags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
 	set x; \
 	here=`pwd`; \
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+	$(am__define_uniq_tagged_files); \
 	shift; \
 	if test -z "$(ETAGS_ARGS)$$*$$unique"; then :; else \
 	  test -n "$$unique" || unique=$$empty_fix; \
@@ -502,15 +737,11 @@ TAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
 	      $$unique; \
 	  fi; \
 	fi
-ctags: CTAGS
-CTAGS:  $(HEADERS) $(SOURCES)  $(TAGS_DEPENDENCIES) \
-		$(TAGS_FILES) $(LISP)
-	list='$(SOURCES) $(HEADERS)  $(LISP) $(TAGS_FILES)'; \
-	unique=`for i in $$list; do \
-	    if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
-	  done | \
-	  $(AWK) '{ files[$$0] = 1; nonempty = 1; } \
-	      END { if (nonempty) { for (i in files) print i; }; }'`; \
+ctags: ctags-am
+
+CTAGS: ctags
+ctags-am: $(TAGS_DEPENDENCIES) $(am__tagged_files)
+	$(am__define_uniq_tagged_files); \
 	test -z "$(CTAGS_ARGS)$$unique" \
 	  || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
 	     $$unique
@@ -519,9 +750,10 @@ GTAGS:
 	here=`$(am__cd) $(top_builddir) && pwd` \
 	  && $(am__cd) $(top_srcdir) \
 	  && gtags -i $(GTAGS_ARGS) "$$here"
+cscopelist: cscopelist-am
 
-cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
-	list='$(SOURCES) $(HEADERS) $(LISP)'; \
+cscopelist-am: $(am__tagged_files)
+	list='$(am__tagged_files)'; \
 	case "$(srcdir)" in \
 	  [\\/]* | ?:[\\/]*) sdir="$(srcdir)" ;; \
 	  *) sdir=$(subdir)/$(srcdir) ;; \
@@ -537,6 +769,158 @@ cscopelist:  $(HEADERS) $(SOURCES) $(LISP)
 distclean-tags:
 	-rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
 
+# Recover from deleted '.trs' file; this should ensure that
+# "rm -f foo.log; make foo.trs" re-run 'foo.test', and re-create
+# both 'foo.log' and 'foo.trs'.  Break the recipe in two subshells
+# to avoid problems with "make -n".
+.log.trs:
+	rm -f $< $@
+	$(MAKE) $(AM_MAKEFLAGS) $<
+
+# Leading 'am--fnord' is there to ensure the list of targets does not
+# expand to empty, as could happen e.g. with make check TESTS=''.
+am--fnord $(TEST_LOGS) $(TEST_LOGS:.log=.trs): $(am__force_recheck)
+am--force-recheck:
+	@:
+
+$(TEST_SUITE_LOG): $(TEST_LOGS)
+	@$(am__set_TESTS_bases); \
+	am__f_ok () { test -f "$$1" && test -r "$$1"; }; \
+	redo_bases=`for i in $$bases; do \
+	              am__f_ok $$i.trs && am__f_ok $$i.log || echo $$i; \
+	            done`; \
+	if test -n "$$redo_bases"; then \
+	  redo_logs=`for i in $$redo_bases; do echo $$i.log; done`; \
+	  redo_results=`for i in $$redo_bases; do echo $$i.trs; done`; \
+	  if $(am__make_dryrun); then :; else \
+	    rm -f $$redo_logs && rm -f $$redo_results || exit 1; \
+	  fi; \
+	fi; \
+	if test -n "$$am__remaking_logs"; then \
+	  echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
+	       "recursion detected" >&2; \
+	else \
+	  am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
+	fi; \
+	if $(am__make_dryrun); then :; else \
+	  st=0;  \
+	  errmsg="fatal: making $(TEST_SUITE_LOG): failed to create"; \
+	  for i in $$redo_bases; do \
+	    test -f $$i.trs && test -r $$i.trs \
+	      || { echo "$$errmsg $$i.trs" >&2; st=1; }; \
+	    test -f $$i.log && test -r $$i.log \
+	      || { echo "$$errmsg $$i.log" >&2; st=1; }; \
+	  done; \
+	  test $$st -eq 0 || exit 1; \
+	fi
+	@$(am__sh_e_setup); $(am__tty_colors); $(am__set_TESTS_bases); \
+	ws='[ 	]'; \
+	results=`for b in $$bases; do echo $$b.trs; done`; \
+	test -n "$$results" || results=/dev/null; \
+	all=`  grep "^$$ws*:test-result:"           $$results | wc -l`; \
+	pass=` grep "^$$ws*:test-result:$$ws*PASS"  $$results | wc -l`; \
+	fail=` grep "^$$ws*:test-result:$$ws*FAIL"  $$results | wc -l`; \
+	skip=` grep "^$$ws*:test-result:$$ws*SKIP"  $$results | wc -l`; \
+	xfail=`grep "^$$ws*:test-result:$$ws*XFAIL" $$results | wc -l`; \
+	xpass=`grep "^$$ws*:test-result:$$ws*XPASS" $$results | wc -l`; \
+	error=`grep "^$$ws*:test-result:$$ws*ERROR" $$results | wc -l`; \
+	if test `expr $$fail + $$xpass + $$error` -eq 0; then \
+	  success=true; \
+	else \
+	  success=false; \
+	fi; \
+	br='==================='; br=$$br$$br$$br$$br; \
+	result_count () \
+	{ \
+	    if test x"$$1" = x"--maybe-color"; then \
+	      maybe_colorize=yes; \
+	    elif test x"$$1" = x"--no-color"; then \
+	      maybe_colorize=no; \
+	    else \
+	      echo "$@: invalid 'result_count' usage" >&2; exit 4; \
+	    fi; \
+	    shift; \
+	    desc=$$1 count=$$2; \
+	    if test $$maybe_colorize = yes && test $$count -gt 0; then \
+	      color_start=$$3 color_end=$$std; \
+	    else \
+	      color_start= color_end=; \
+	    fi; \
+	    echo "$${color_start}# $$desc $$count$${color_end}"; \
+	}; \
+	create_testsuite_report () \
+	{ \
+	  result_count $$1 "TOTAL:" $$all   "$$brg"; \
+	  result_count $$1 "PASS: " $$pass  "$$grn"; \
+	  result_count $$1 "SKIP: " $$skip  "$$blu"; \
+	  result_count $$1 "XFAIL:" $$xfail "$$lgn"; \
+	  result_count $$1 "FAIL: " $$fail  "$$red"; \
+	  result_count $$1 "XPASS:" $$xpass "$$red"; \
+	  result_count $$1 "ERROR:" $$error "$$mgn"; \
+	}; \
+	{								\
+	  echo "$(PACKAGE_STRING): $(subdir)/$(TEST_SUITE_LOG)" |	\
+	    $(am__rst_title);						\
+	  create_testsuite_report --no-color;				\
+	  echo;								\
+	  echo ".. contents:: :depth: 2";				\
+	  echo;								\
+	  for b in $$bases; do echo $$b; done				\
+	    | $(am__create_global_log);					\
+	} >$(TEST_SUITE_LOG).tmp || exit 1;				\
+	mv $(TEST_SUITE_LOG).tmp $(TEST_SUITE_LOG);			\
+	if $$success; then						\
+	  col="$$grn";							\
+	 else								\
+	  col="$$red";							\
+	  test x"$$VERBOSE" = x || cat $(TEST_SUITE_LOG);		\
+	fi;								\
+	echo "$${col}$$br$${std}"; 					\
+	echo "$${col}Testsuite summary for $(PACKAGE_STRING)$${std}";	\
+	echo "$${col}$$br$${std}"; 					\
+	create_testsuite_report --maybe-color;				\
+	echo "$$col$$br$$std";						\
+	if $$success; then :; else					\
+	  echo "$${col}See $(subdir)/$(TEST_SUITE_LOG)$${std}";		\
+	  if test -n "$(PACKAGE_BUGREPORT)"; then			\
+	    echo "$${col}Please report to $(PACKAGE_BUGREPORT)$${std}";	\
+	  fi;								\
+	  echo "$$col$$br$$std";					\
+	fi;								\
+	$$success || exit 1
+recheck: all $(check_PROGRAMS)
+	@test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
+	@set +e; $(am__set_TESTS_bases); \
+	bases=`for i in $$bases; do echo $$i; done \
+	         | $(am__list_recheck_tests)` || exit 1; \
+	log_list=`for i in $$bases; do echo $$i.log; done`; \
+	log_list=`echo $$log_list`; \
+	$(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_LOG) \
+	        am__force_recheck=am--force-recheck \
+	        TEST_LOGS="$$log_list"; \
+	exit $$?
+xdrtest.log: xdrtest$(EXEEXT)
+	@p='xdrtest$(EXEEXT)'; \
+	b='xdrtest'; \
+	$(am__check_pre) $(LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_LOG_DRIVER_FLAGS) $(LOG_DRIVER_FLAGS) -- $(LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+.sh.log:
+	@p='$<'; \
+	$(am__set_b); \
+	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+	--log-file $$b.log --trs-file $$b.trs \
+	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+	"$$tst" $(AM_TESTS_FD_REDIRECT)
+ at am__EXEEXT_TRUE@.sh$(EXEEXT).log:
+ at am__EXEEXT_TRUE@	@p='$<'; \
+ at am__EXEEXT_TRUE@	$(am__set_b); \
+ at am__EXEEXT_TRUE@	$(am__check_pre) $(SH_LOG_DRIVER) --test-name "$$f" \
+ at am__EXEEXT_TRUE@	--log-file $$b.log --trs-file $$b.trs \
+ at am__EXEEXT_TRUE@	$(am__common_driver_flags) $(AM_SH_LOG_DRIVER_FLAGS) $(SH_LOG_DRIVER_FLAGS) -- $(SH_LOG_COMPILE) \
+ at am__EXEEXT_TRUE@	"$$tst" $(AM_TESTS_FD_REDIRECT)
+
 distdir: $(DISTFILES)
 	@srcdirstrip=`echo "$(srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
 	topsrcdirstrip=`echo "$(top_srcdir)" | sed 's/[].[^$$\\*]/\\\\&/g'`; \
@@ -596,6 +980,9 @@ install-strip:
 	    "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'" install; \
 	fi
 mostlyclean-generic:
+	-test -z "$(TEST_LOGS)" || rm -f $(TEST_LOGS)
+	-test -z "$(TEST_LOGS:.log=.trs)" || rm -f $(TEST_LOGS:.log=.trs)
+	-test -z "$(TEST_SUITE_LOG)" || rm -f $(TEST_SUITE_LOG)
 
 clean-generic:
 
@@ -679,20 +1066,21 @@ uninstall-am: uninstall-includeHEADERS uninstall-libLTLIBRARIES
 
 .MAKE: check-am install-am install-strip
 
-.PHONY: CTAGS GTAGS all all-am all-local check check-TESTS check-am \
-	clean clean-checkPROGRAMS clean-generic clean-libLTLIBRARIES \
-	clean-libtool cscopelist ctags distclean distclean-compile \
-	distclean-generic distclean-libtool distclean-tags distdir dvi \
-	dvi-am html html-am info info-am install install-am \
-	install-data install-data-am install-dvi install-dvi-am \
-	install-exec install-exec-am install-html install-html-am \
+.PHONY: CTAGS GTAGS TAGS all all-am all-local check check-TESTS \
+	check-am clean clean-checkPROGRAMS clean-generic \
+	clean-libLTLIBRARIES clean-libtool cscopelist-am ctags \
+	ctags-am distclean distclean-compile distclean-generic \
+	distclean-libtool distclean-tags distdir dvi dvi-am html \
+	html-am info info-am install install-am install-data \
+	install-data-am install-dvi install-dvi-am install-exec \
+	install-exec-am install-html install-html-am \
 	install-includeHEADERS install-info install-info-am \
 	install-libLTLIBRARIES install-man install-pdf install-pdf-am \
 	install-ps install-ps-am install-strip installcheck \
 	installcheck-am installdirs maintainer-clean \
 	maintainer-clean-generic mostlyclean mostlyclean-compile \
 	mostlyclean-generic mostlyclean-libtool mostlyclean-local pdf \
-	pdf-am ps ps-am tags uninstall uninstall-am \
+	pdf-am ps ps-am recheck tags tags-am uninstall uninstall-am \
 	uninstall-includeHEADERS uninstall-libLTLIBRARIES
 
 
diff --git a/mfhdf/xdr/xdrstdio.c b/mfhdf/xdr/xdrstdio.c
index 3c0d4fc..bee5d8d 100644
--- a/mfhdf/xdr/xdrstdio.c
+++ b/mfhdf/xdr/xdrstdio.c
@@ -15,10 +15,10 @@ static char sccsid[] = "@(#)xdr_stdio.c 1.16 87/08/11 Copyr 1984 Sun Micro";
 
 #include <stdio.h>
 #include "types.h"
-#if !(defined MSDOS || defined WINNT || defined _WIN32)
+#if !(defined MSDOS || defined WINNT || defined _WIN32 || defined __MINGW32__)
 #        include <netinet/in.h>     /* for htonl() */
 #else
-#     if !(defined WINNT) & !defined _WIN32
+#     if !(defined WINNT) & !defined _WIN32 & !defined __MINGW32__
            extern long ntohl(long i_in);
            extern long htonl(long i_in);
            extern short ntohs(short i_in);
diff --git a/release_notes/HISTORY.txt b/release_notes/HISTORY.txt
index 0a1e96a..b0ae8cd 100644
--- a/release_notes/HISTORY.txt
+++ b/release_notes/HISTORY.txt
@@ -16,6 +16,7 @@
 
 List of the HDF4 releases
 
+4.2.10         February	 2014
 4.2.9          February	 2013
 4.2.8          August	 2012
 4.2.7          February	 2012
@@ -42,6 +43,307 @@ List of the HDF4 releases
 
 ==========================================================================    
 
+%%%4.2.10%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+HDF version 4.2.10 released on 2014-02-09
+==============================================
+
+INTRODUCTION
+
+This document describes the differences between HDF 4.2.9 and HDF 4.2.10.
+It is written for people who are familiar with previous releases of HDF 
+and wish to migrate to HDF 4.2.10.
+
+The HDF 4.2.10 documentation can be found on the The HDF Group's website
+at:
+    http://www.hdfgroup.org/doc.html
+
+Previous versions of the documentation are available from the FTP server:
+
+    ftp://ftp.hdfgroup.org/HDF/Documentation/
+
+First-time HDF users are encouraged to read the HDF FAQ, which can be
+reached from the HDF product home page:
+  
+    http://hdfgroup.org/products/hdf4/
+
+If you have any questions or comments, please see the HDF Support page:
+
+    http://hdfgroup.org/services/support.html
+
+CONTENTS
+
+- New features and changes
+  -- Configuration
+- Support for new platforms and compilers
+- Bugs fixed since HDF 4.2.9
+  -- Configuration
+  -- Library
+  -- Utilities
+- Documentation
+- Platforms tested
+- Known problems
+
+
+New features and changes
+========================
+   Configuration
+   ============= 
+   CMake - Added support to create dmg bundles on Mac.
+     (ADB 2013/9/12)
+   CMake - Added support to use Windows /MT option.
+     (ADB 2013/6/10)
+     
+
+Support for new platforms and compilers
+=======================================
+    - Visual Studio 2012 w/ Intel Fortran 13 on Windows 7 and Windows 8
+    - Mac OS X Mavericks with clang and gfortran
+
+
+Bugs fixed since HDF 4.2.9
+=========================
+   Configuration
+   =============
+   - Removed the requirement of yacc/lex like tools. The ncgenXXX.* files
+     generated files from yacc and lex input files are pre-created in the
+     source code to build the ncgen tool. The msoft*.[ch] files were for
+     Windows build but was out of dated. Cmake uses the pre-created files
+     instead. See known problem below. (AKC 2014/02/02 HDFFR-1419)
+
+   - Removed old Macintosh platform codes that are not used any more.
+     (AKC 2014/01/21 HDFFR-1340)
+
+   - Changed Mac platforms to use the Apple supported clang compiler as the
+     default C compiler. (AKC 2014/01/15 HDFFR-1318)
+
+   - Removed the following individual platform specific files and have them to
+     be produced by configure using corresponding *.in files.
+     mfhdf/libsrc/config/netcdf-XXX.h    by mfhdf/libsrc/netcdf.h.in
+     mfhdf/fortran/config/ftest-XXX.f    by mfhdf/fortran/ftest.f.in
+     mfhdf/fortran/config/jackets-XXX.c  by mfhdf/fortran/jackets.c.in
+     mfhdf/fortran/config/netcdf-XXX.inc by mfhdf/fortran/netcdf.inc.in
+     (AKC 2013/12/31 HDFFR-1320/476)
+
+   - The following platforms are old and no longer available. Removed their
+     support code from the configure files:
+     alpha, convex, dec, fujivp, hpux, ia64, irix32, irix4, irix5, irix6, mac,
+     solarisx86, sun, t3e, unicos. (AKC 2013/12/26 HDFFR-1320)
+
+   - Removed -Xc (strict ansi standard) from the default CFLAGS of Solaris
+     since the latest Sun Compiler version 5.11 and 5.12 have a conflict with
+     the system header file. Since the current versions of C compiler should be
+     at least ANSI (aka C89) compliant, the removal of -Xc should be safe. This
+     also fixes a previous known problem of needing to use -xc99 to build HDF4.
+     (AKC 2013/12/20 HDFFR-1361)
+
+   - CMake - Changed name of TGZ_PATH to TGZPATH.
+           (ADB 2013/9/12)
+   - CMake - Removed extra flag POSIX_SOURCE as it caused failures on Apple Mac
+     builds. (ADB 2013/8/7)
+
+   Library
+   ========= 
+   - SDsetblocksize and VSsetblocksize would not change the block size if
+     the sds/vdata did not use linked-block before it was closed.  The
+     problem is now fixed.  (BMR 2013/1/15 - HDFFR-1357)
+
+   - Patches from user are applied to the C test to correct an overflow variable
+     and to the Fortran source for some missing declarations.
+     (BMR/EP 2014/1/15 - HDFFR-1367)
+
+   - Examples GR_write_chunks.c and GR_read_chunks.c were added. 
+     (BMR 2014/12/30 - HDFFR-1402)
+
+
+   Utilities
+   ========= 
+   - ncdump displayed garbage in place of fill-values when a variable had
+     unlimited dimension and had been written with less number of records
+     than the largest number of records in the file.  This is now fixed.
+     (BMR 2014/12/16 - HDFFR-1390)
+
+
+Documentation
+=============
+   - None
+
+
+Platforms tested
+================
+
+This version has been tested in the following platforms:
+
+   Linux 2.6.32-358.18.1         gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-3)
+   .el6.ppc64 #1                 GNU Fortran (GCC) 4.4.7 20120313 (Red Hat 4.4.7-3)
+   SMP ppc64 GNU/Linux           IBM XL Fortran for Linux, V13.1 (64-bit mode)
+   (ostrich)
+
+   Linux 2.6.18-308.13.1.el5 #1  gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-52)
+      SMP i686 i386              GNU Fortran (GCC) 4.1.2 20080704
+   (jam)                             (Red Hat 4.1.2-52)
+                                 pgcc and pgf90 13.7-0 32-bit target 
+                                 on x86 Linux -tp penryn
+                                 Intel(R) C Compiler, Version 13.1.3 20130607
+                                 Intel(R) Fortran Compiler, Version 13.1.3
+
+   Linux 2.6.18-308.24.1.el5 #1  gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-54)
+      SMP x86_64 GNU/Linux       GNU Fortran (GCC) 4.1.2 20080704 
+   (koala)                           (Red Hat 4.1.2-54)
+                                 icc (ICC) 13.1.3 20130607
+                                 ifort (IFORT) 13.1.3 20130607
+                                 pgcc and pgf90 13.7-0 64-bit target 
+                                 on x86-64 Linux -tp nehalem
+
+   Linux 2.6.32-431.el6.x86_64   gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-4)
+      #1 SMP x86_64 GNU/Linux    GNU Fortran (GCC) 4.4.7 20120313 
+   (platypus)                        (Red Hat 4.4.7-4)
+                                 icc (ICC) 13.1.3 20130607
+                                 ifort (IFORT) 13.1.3 20130607
+   
+   SunOS 5.11 32- and 64-bit     Sun C 5.12 SunOS_sparc 2011/11/16 
+   (emu)                              (see "Known problem" section)
+                                 Sun Fortran 95 8.6 SunOS_sparc 2011/11/16
+
+   Windows 7                     Visual Studio 2008 w/ Intel Fortran 11.1 (cmake)
+                                 Visual Studio 2010 w/ Intel Fortran 12 (cmake)
+                                 Visual Studio 2012 w/ Intel Fortran 13 (cmake)
+                                 Cygwin(CYGWIN_NT-6.1 1.7.25(0.270/5/3) gcc(4.7.3) compiler and gfortran)
+                                 (cmake and autotools)
+
+   Windows 7 x64                 Visual Studio 2008 w/ Intel Fortran 11.1 (cmake)
+                                 Visual Studio 2010 w/ Intel Fortran 12 (cmake)
+                                 Visual Studio 2012 w/ Intel Fortran 13 (cmake)
+
+   Windows 8                     Visual Studio 2012 w/ Intel Fortran 13 (cmake)
+
+   Windows 8 x64                 Visual Studio 2012 w/ Intel Fortran 13 (cmake)
+
+   Mac OS X Intel 10.6.8         Apple clang version 1.7 from Xcode 3.2.6
+   Darwin 10.8.0                 gfortran GNU Fortran (GCC) 4.6.2
+   (fred)                        icc and ifort Version 12.1.6 20120928
+                             
+   Mac OS X 10.7.5		 Apple clang version 3.0 from Xcode 4.6.1
+   Darwin 11.4.2                 gfortran GNU Fortran (GCC) 4.6.2
+   (duck)                        icc and ifort Version 13.0.3 20130606
+
+   Mac OS X 10.8.5               Apple clang version 4.2 from Xcode 4.6.1
+   Darwin 12.2.0                 gfortran GNU Fortran (GCC) 4.6.2
+   (wren)                        icc and ifort Version 13.0.3 20130606
+
+   Mac OS X 10.8.5               Apple clang version 5.0 from Xcode 5.0.2
+   Darwin 12.2.0                 gfortran GNU Fortran (GCC) 4.6.2
+   (swallow,kite)                icc and ifort Version 14.0.1 20131010
+
+   Mac OS X 10.9.1               Apple LLVM version 5.0 (clang-500.2.79)
+   Darwin 13.0.0                 (based on LLVM 3.3svn)
+                                 gfortran GNU Fortran (GCC) 4.6.2 
+         
+
+   Debian7.2.0 3.2.0-4-amd64 #1 SMP Debian 3.2.51-1 x86_64 GNU/Linux
+                                 gcc (Debian 4.7.2-5) 4.7.2
+                                 GNU Fortran (Debian 4.7.2-5) 4.7.2
+                                 (cmake and autotools)
+
+   Fedora20 3.11.10-301.fc20.x86_64 #1 SMP x86_64 x86_64 x86_64 GNU/Linux
+                                 gcc (GCC) 4.8.2 20131212 (Red Hat 4.8.2-7)
+                                 GNU Fortran (GCC) 4.8.2 20130603 (Red Hat 4.8.2-7)
+                                 (cmake and autotools)
+
+   SUSE 13.1 3.11.6-4-desktop #1 SMP PREEMPT x86_64 x86_64 x86_64 GNU/Linux
+                                 gcc (SUSE Linux) 4.8.1
+                                 GNU Fortran (SUSE Linux) 4.8.1
+                                 (cmake and autotools)
+
+   Ubuntu 13.10 3.11.0-13-generic #20-Ubuntu SMP x86_64 GNU/Linux
+                                 gcc (Ubuntu/Linaro 4.8.1-10ubuntu8) 4.8.1
+                                 GNU Fortran (Ubuntu/Linaro 4.8.1-10ubuntu8) 4.8.1
+                                 (cmake and autotools)
+
+
+Known problems
+==============
+o  CMake builds in Windows uses the same pre-generated ncgen*.[ch] files from
+   the yacc/lex input files. The generated file, ncgenyy.c, uses the <unistd.h>
+   header file that Windows does not support.  This must be blocked out in
+   order for Windows to use it. (AKC 2014-02-03 HDFFR-1424).
+
+o  CMake "make install" fails installing the tools:
+    Use CPack to create an install package.
+   ADB - 2014/02/03
+
+o  CMake does not install these man pages:
+	hdf.1, ncdump.1, ncgen.1
+   AKC/BMR - 2014/02/02
+
+o  For Mac OS X 10.7 Lion and on 10.8 Mountain Lion, several tests fail with
+   GCC, Intel and Clang compilers.  Currently, this situation is detected and
+   -O0 level optimization is used.  We will work on the issue for the next
+   release. (HDFFR-1318,1358) EIP - 2013/02/05
+
+o  On IBM PowerPC 64, hdftest fails when gcc 4.4.6 is used with -O3 optimization 
+   level. 
+
+o  When building in AIX systems, if CC is xlc with -qlanglvl=ansi, configure
+   will fail when checking for the jpeglib.h header due to the duplicated
+   macro definition of HAVE_STDLIB_H.  This is because some newer builds
+   of the jpeg library have HAVE_STDLIB_H defined in the jconfig.h header file.
+   Without the -qlanglvl=ansi, some older xlc versions (e.g., V7.0) still 
+   fail, but newer xlc versions (e.g., V9.0) pass.  AKC - 2010/02/17
+
+o  When building on Linux/UNIX platforms, the szip shared library files must
+   be in the system library path.  This can be done by adding a link to
+   the libsz.* files in the /usr/lib folder or by adding the library
+   location to the LD_LIBRARY_PATH environment variable.
+      Ex. export LD_LIBRARY_PATH=path_to_szip_lib:$LD_LIBRARY_PATH
+   Optionally, one can use the static szip library files by adding '-static'
+   to the CFLAGS environment variable.
+   
+o  Existing data written by an HDF4 Library prior to HDF 4.2r2:
+   When a one-dimensional SDS and a dimension scale have
+   the same name, subsequent accesses to the dimension scale or to the
+   SDS might produce undesired results because the libraries could not
+   distinguish between the two objects.  In the case of writing, data
+   might even be corrupted.  For example, SDS data might be written to a
+   dimension variable or vice versa. (bugzilla #624)
+
+   HDF4 Library Releases 4.2r2 and later make a distinction between an SDS
+   and a dimension variable.  However, as with older versions, these recent
+   versions are unable to detect such conflicts in files created by earlier 
+   releases.  It is therefore STRONGLY recommended to check for such name 
+   duplication before working with data created with a pre-4.2r2 library.
+
+   The functions SDgetnumvars_byname and SDnametoindices are provided
+   to help detect such name conflicts and select the correct object to
+   access, respectively; see the HDF Reference Manual entries for
+   further details.
+   FB - 2009/01/26
+   BMR - revised 2011/06/24
+
+o  N-bit compression is not supported with Fortran APIs.
+
+o  Using both fill-value and compression on SD datasets does not work.
+
+o  When using PGI compilers, make sure that the JPEG library is also compiled 
+   with a PGI C compiler; linking with a JPEG library built with gcc causes 
+   JPEG library tests to fail.  To bypass the problem:
+
+       x Set LIBS flag to $PGI_JPEG_INSTALL_DIR/lib/libjpeg.a
+         where $PGI_JPEG_INSTALL_DIR points to the installation directory
+         for the PGI-compiled JPEG library:
+
+         setenv LIBS $PGI_JPEG_INSTALL_DIR/lib/libjpeg.a
+
+       x Use the --with-jpeg=$PGI_JPEG_INSTALL_DIR configure flag to 
+         configure with the PGI-compiled JPEG library:
+
+         ./configure --with-jpeg=$PGI_JPEG_INSTALL_DIR --with-zlib....
+
+o  In order for the API SDgetdatasize to get the correct compressed size
+   of the data, the dataset needs to be closed (SDendaccess) or read
+   (SDreaddata) after being written and before SDgetdatasize is called.
+   BMR - 2008/11/22
+
+
 %%%4.2.9%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
 HDF version 4.2.9 released on 2013-02-07
 =============================================
diff --git a/release_notes/INSTALL b/release_notes/INSTALL
index 9ee8064..a55be5e 100644
--- a/release_notes/INSTALL
+++ b/release_notes/INSTALL
@@ -180,7 +180,7 @@ without using CMake should consult the USING_HDF4_VS.txt file.
 
 Additional Third-party Software Requirements:
 
-   1)  Flex and Bison programs are required to build the ncgen utility.
+   1)  Flex and Bison programs are required to regenerate the ncgen utility input files.
    
    2)  Recommended is the Win flex-bison project, a port of Flex & Bison tools 
        to the Windows platform. Download from:
diff --git a/release_notes/INSTALL_CMake.txt b/release_notes/INSTALL_CMake.txt
index c465a46..132038e 100644
--- a/release_notes/INSTALL_CMake.txt
+++ b/release_notes/INSTALL_CMake.txt
@@ -1,160 +1,247 @@
-************************************************************************
-* Build and Install the HDF4 C/C++ Library with CMake                  *
-************************************************************************
+*************************************************************************
+* Build and Install HDF5 C, C++, Fortran Libraries and tools with CMake *
+*************************************************************************
 
                      Table of Contents
                      
-Section I:   Quick Step Building HDF4 Libraries with CMake Script Mode 
-Section II:  Quick Step Building HDF4 Libraries with CMake Command Mode
-Section III: Preconditions
-Section IV:  Building HDF4 C/Fortran Libraries with CMake
-Section V:   All Options for HDF4 C/Fortran Libraries with CMake
-Section VI:  User-defined Options for HDF4 Libraries with CMake
-Section VII: APPENDIX
+Section I:    Preconditions
+Section II:   Quick Step Building HDF4 Libraries with CMake Script Mode 
+Section III:  Quick Step Building HDF4 Libraries with CMake Command Mode
+Section IV:   Further considerations                                                           
+Section V:    Options for building HDF4 Libraries with CMake command line
+Section VI:   CMake option defaults for HDF4
+Section VII:  User Defined Options for HDF4 Libraries with CMake
+Section VIII: Options for platform configuration files
 
 ************************************************************************
 
 
+========================================================================
+I. Preconditions
+========================================================================
+Obtaining HDF4 source code 
+   1. Create a directory for your development; for example, "myhdfstuff".
+
+   2. Obtain compressed (*.tar or *.zip) HDF4 source from
+        http://www.hdfgroup.org/ftp/HDF/HDF_Current/src/
+      and put it in "myhdfstuff".
+      Do not uncompress.
+
+CMake version
+   1. We suggest you obtain the latest CMake from the Kitware web site. 
+      The HDF 4.2."X" product requires a minimum CMake version 2.8.12,
+      where "X" is the current HDF4 release version.                     
+
 
 ========================================================================
-I. Quick Step Building HDF4 Libraries with CMake script mode
+II. Quick Step Building HDF4 Libraries with CMake Script Mode
 ========================================================================
 This short set of instructions is written for users who want to quickly 
-build the HDF4 Library and tools from the HDF4 source code package 
-using the CMake tools. HDF Group recommends using a ctest script to build
-HDF4.
+build the HDF4 C, C++, and Fortran shared libraries and tools
+from the HDF4 source code package using the CMake tools. This procedure 
+will use the default settings in the config/cmake/cacheinit.cmake file.
+HDF Group recommends using the ctest script mode to build HDF4.
 
-To build HDF4 with the SZIP, ZLIB and JPEG external libraries you will need to:
+The following files referenced below are available at the HDF web site:
+    http://www.hdfgroup.org/release4/cmakebuild.html
 
-    1. Create a directory for your development; myhdfstuff.
+CMake build script:
+    CTestScript.cmake
+
+External compression szip and zlib libraries:
+    JPEG8b.tar.gz
+    SZip.tar.gz
+    ZLib.tar.gz
     
-    2. Create a directory for the HDF4 source; hdf4.2.10 in myhdfstuff.
+Platform configuration files:
+    HDF4Windows64CMake.cmake
+    HDF4Windows32CMake.cmake
+    HDF4LinuxCMake.cmake
+    HDF4MacCMake.cmake
+
+To build HDF4 with the SZIP, ZLIB and JPEG external libraries you will need to:
 
-    3. Download the SZip.tar.gz, ZLib.tar.gz, and JPEG.tar.gz to your 
-       development directory, (See Section VII: APPENDIX for instructions). 
-       All are needed if building with external libraries; do not uncompress them.
+   1. Change to the development directory "myhdfstuff".
+    
+   2. Download the SZip.tar.gz, ZLib.tar.gz, and JPEG.tar.gz to "myhdfstuff".
+      Do not uncompress the files.
        
-    4. Download or create the CTestScript.cmake file in your development 
-       directory, (See Section VII: APPENDIX for instructions and an example).   
-          
-    5. Download or create a platform configuration file in your development 
-       directory, (See Section VII: APPENDIX for instructions and an example). 
-       This file calls CTestScript.cmake; the platform configuration file can 
-       be modified. CTestScript.cmake file should not be modified.    
+  3. Download the CTestScript.cmake file to "myhdfstuff".
+      CTestScript.cmake file should not be modified.    
+       
+   4. Download a platform configuration file to "myhdfstuff".
+      Do not modify the file unless you want to change default build 
+      environment.
 
-    6. From your development directory execute the CTest Script with the 
-       following options:
+   5. From the "myhdfstuff" directory execute the CTest Script with the 
+      following options:
 
-        ctest -S <configuration file>,<hdf4src> -C Release -VV -O hdf4.log
+         ctest -S <configuration file> -C Release -VV -O hdf4.log
 
-    7. This will create an install package in the myhdfstuff/hdf4.2.10/build folder.
+      The command above will configure, build, test, and create an install 
+      package in the myhdfstuff/hdf-4.2/build folder.
 
-    Where:
-        "configuration file" is the platform configuration file from step 5;
-          HDF4WindowsCMake.cmake, HDF4LinuxCMake.cmake, or HDF4MacCMake.cmake
-          can be downloaded from the HDF Group website.
-        "hdf4src" is the uncompressed HDF4 source code directory. No path 
-          should be specified.
+      The -S option uses the script version of ctest.
         
-        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 
+      configuration file.
         
-        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 verbose; use -V for less verbose.
         
-        The -VV option is for verbose; Use -V for less verbose.
-        
-        The "-O hdf4.log" option saves the output to a log file hdf4.log.
+      The "-O hdf4.log" option saves the output to a log file hdf5.log.
+
+   6. To install, "X" is the current release version
+ 
+      On Windows, execute:
+                HDF-4.2."X"-win32.exe or HDF-4.2."X"-win64.exe
+      By default this program will install the hdf4 library into the
+      "C:\Program Files" directory and will create the following 
+      directory structure:
+         HDF_Group
+         --HDF
+         ----4.2."X"
+         ------bin
+         ------include
+         ------lib
+         ------cmake
+
+      On Linux, change to the install destination directory 
+      (create it if doesn't exist) and execute:
+                <path-to>/myhdfstuff/hdf-4.2/build/HDF-4.2."X"-Linux.sh
+      After accepting the license, the script will prompt:
+        By default the HDF4 will be installed in:
+        "<current directory>/HDF-4.2."X"-Linux"
+        Do you want to include the subdirectory HDF5-1.8."X"-Linux?
+        Saying no will install in: "<current directory>" [Yn]: 
+      Note that the script will create the following directory structure
+      relative to the install point:
+         HDF_Group
+         --HDF
+         ----4.2."X"
+         ------bin
+         ------include
+         ------lib
+         ------share
+                
+      On Mac you will find HDF-4.2."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:      
+         HDF_Group
+         --HDF
+         ----4.2."X"
+         ------bin
+         ------include
+         ------lib
+         ------share
+      
+      By default the installation will create the bin, include, lib and cmake
+      folders in the <install destination directory>/HDF_Group/HDF/4.2.
 
 
 ========================================================================
-II. Quick Step Building HDF4 Libraries with CMake command line mode
+III. Quick Step Building HDF4 C Static Libraries and Tools with CMake
 ========================================================================
-This short set of instructions is written for users who want to quickly 
-build the HDF4 Library and tools from the HDF4 source code package 
-using the CMake command line tools.
+Notes: This short set of instructions is written for users who want to 
+       quickly build the just the HDF4 C static library and tools from 
+       the HDF4 source code package using the CMake command line tools.
        
-   A. Windows Quick Step Building HDF4 Libraries with CMake Using VS2010
+   Go through these steps:
 
-      Go through these steps:
+      1. Change to the development directory "myhdfstuff".
 
-      1. Locate the source files in:
-         c:\MyHDFstuff\hdf4
-      
-      2. Create a build folder at:
-         c:\MyHDFstuff\hdf4\build
-      
-      3. Open a command prompt at:
-         c:\MyHDFstuff\hdf4\build
-      
-      4. Configure the C library, tools, and tests with this command:
-         cmake -G "Visual Studio 10" -DHDF4_ALLOW_EXTERNAL_SUPPORT:STRING="SVN"
-            -DHDF4_PACKAGE_EXTLIBS:BOOL=ON -DHDF4_BUILD_TOOLS:BOOL=ON 
-            -DHDF4_BUILD_UTILS:BOOL=ON -DBUILD_TESTING:BOOL=ON 
-            -DCMAKE_INSTALL_PREFIX:PATH="." ..
-         The two dots on the end of the command is the location of the source.
-      
-      5. Build the C library, tools, and tests with this command:
-         cmake --build . --config Release
-      
-      6. Test the C library and tools with this command:
-         ctest . -C Release
-      
-      7. Create an install image with this command:
-         cpack -C Release CPackConfig.cmake
-      
-      8. Install with this command:
-         HDF4.2.x-win32.exe
-      
-   B. Linux Quick Step Building HDF4 Libraries with CMake Using GCC
+      2. Uncompress the HDF4 source file
       
-      Go through these steps:
+      3. Create a folder  "build" in the "myhdfstuff" directory.
       
-      1. Locate the source files in:
-         ~/MyHDFstuff/hdf4
+      4. Change into the "build" folder. 
       
-      2. Create a build folder at:
-         ~/MyHDFstuff/hdf4/build
-      
-      3. Open a command prompt at:
-         ~/MyHDFstuff/hdf4/build
-      
-      4. Configure the C library, tools, and tests with this command:
-         cmake -G "Unix Makefiles" -DHDF4_ALLOW_EXTERNAL_SUPPORT:STRING="SVN"
-            -DHDF4_PACKAGE_EXTLIBS:BOOL=ON -DHDF4_BUILD_TOOLS:BOOL=ON
-            -DHDF4_BUILD_UTILS:BOOL=ON -DBUILD_TESTING:BOOL=ON 
-            -DCMAKE_INSTALL_PREFIX:PATH="." ..
-         The two dots on the end of the command is the location of the source.
-      
-      5. Build the C library, tools, and tests with this command:
-         cmake --build . --config Release
-      
-      6. Test the C library and tools with this command:
-         ctest . -C Release
-      
-      7. Create an install image with this command:
-         cpack -C Release CPackConfig.cmake
+      5. Configure the C library, tools and tests with one of the following commands:
+
+         On Windows 32 bit
+           cmake -G "Visual Studio 11" -DCMAKE_BUILD_TYPE:STRING=Release -DBUILD_TESTING:BOOL=ON -DHDF4_BUILD_TOOLS:BOOL=ON ..\hdf-4.2."X"
+
+         On Windows 64 bit
+           cmake -G "Visual Studio 11 Win64" -DCMAKE_BUILD_TYPE:STRING=Release -DBUILD_TESTING:BOOL=ON -DHDF4_BUILD_TOOLS:BOOL=ON ..\hdf-4.2."X"
       
-      8. Install with this command:
-         HDF4.2.x-Linux.sh
+         On Linux and Mac
+           cmake -G "Unix Makefiles" -DCMAKE_BUILD_TYPE:STRING=Release -DBUILD_TESTING:BOOL=ON -DHDF4_BUILD_TOOLS:BOOL=ON ../hdf-4.2."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 
+         On Windows, execute:
+                HDF-4.2."X"-win32.exe or HDF-4.2."X"-win64.exe
+         By default this program will install the hdf4 library into the
+         "C:\Program Files" directory and will create the following 
+         directory structure:
+            HDF_Group
+            --HDF
+            ----4.2."X"
+            ------bin
+            ------include
+            ------lib
+            ------cmake
+
+         On Linux, change to the install destination directory 
+         (create if doesn't exist) and execute:
+                <path-to>/myhdfstuff/build/HDF-4.2."X"-Linux.sh
+         After accepting the license, the script will prompt:
+           By default the HDF4 will be installed in:
+           "<current directory>/HDF-4.2."X"-Linux"
+           Do you want to include the subdirectory HDF-4.2."X"-Linux?
+           Saying no will install in: "<current directory>" [Yn]: 
+         Note that the script will create the following directory structure
+         relative to the install point:
+            HDF_Group
+            --HDF
+            ----4.2."X"
+            ------bin
+            ------include
+            ------lib
+            ------share
+                
+         On Mac you will find HDF-4.2."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:      
+            HDF_Group
+            --HDF
+            ----4.2."X"
+            ------bin
+            ------include
+            ------lib
+            ------share
 
 
 ========================================================================
-III. Preconditions                                                           
+IV. Further considerations                                                           
 ========================================================================
 
-   1. We suggest you obtain the latest CMake for Windows from the Kitware
-      web site. The HDF 4.2.x product requires a minimum CMake version of 
-      2.8.10.
+   1. We suggest you obtain the latest CMake for windows from the Kitware
+      web site. The HDF 4.2."X" product requires a minimum CMake version 2.8.12.
                                                                          
-   2. HDF4 requires Zlib and JPEG. Szip is optional. Use one of the choices
-      below:
+   2. HDF4 requires Zlib and JPEG. Szip is optional:
       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. This will require telling CMake where the include 
-         and binary files are located.
-         
+         packages there. Add the following CMake options:
+            -DJPEG_LIBRARY:FILEPATH=some_location/lib/jpeg.lib
+            -DJPEG_INCLUDE_DIR:PATH=some_location/include
+            -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. 
+         Note that you can use either JPEG 6b or 8b.
+
       B. Use source packages from an SVN server by adding the following CMake 
          options:
          
@@ -162,52 +249,41 @@ III. Preconditions
             JPEG_SVN_URL:STRING="http://some_location/jpeg/trunk"
             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.
-         
-      C. (Preferred) Use source packages from a compressed file by adding the
-         following CMake options:
+         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 
+         CMake options:
             HDF4_ALLOW_EXTERNAL_SUPPORT:STRING="TGZ"
             JPEG_TGZ_NAME:STRING="jpeg_src.ext"
             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 
-         file and ext is the type of compression file. See the appendix at 
-         the bottom of this file for downloading the files.
-                                                                         
-   3. If you are building under CYGWIN set the following option;
-            HDF4_BUILD_XDR_LIB:BOOL=ON
+         file and ext is the type of compression file. Also set CMAKE_BUILD_TYPE
+         to the configuration type during configuration
                                     
-   4. 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:
-      
-      A. Compiler choice - use xcode by setting the ENV variables of CC and 
-         CXX.
-         
-      B. Shared Fortran is not supported, build static:
-      
+          Compiler choice - use xcode by setting the ENV variables of CC and CXX
+          Shared fortran is not supported, build static:
             BUILD_SHARED_LIBS:BOOL=OFF
-            
-      C. Additional options:
-      
+          Additional options:
             CMAKE_ANSI_CFLAGS:STRING=-fPIC
             CTEST_USE_LAUNCHERS:BOOL=ON
             CMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=OFF         
    
-   5. Windows developers should install NSIS to create an executable install image 
-      with CPack. Visual Studio Express users will not be able to package 
-      HDF4 into an executable install image executable. Use the HDF4_NO_PACKAGES option.
+   4. Windows developers should install NSIS to create an install image with CPack.
+      Visual Studio Express users will not be able to package HDF5 into
+      an install image executable.
    
-   6. Developers can copy the config/cmake/cacheinit.cmake file and alter 
-      the settings for the developers' environment. Then the only options 
-      needed on the command line are those options that are different. An 
-      example using the HDF default cache file is:
-      
-        cmake -C ../config/cmake/cacheinit.cmake -G "Visual Studio 10" \
-          -DHDF4_ENABLE_SZIP_SUPPORT:BOOL=OFF -DHDF4_BUILD_EXAMPLES:BOOL=OFF ..
+   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
+      default cache file:
+           cmake -C ../config/cmake/cacheinit.cmake -G "Visual Studio 11" \
+               -DHDF4_ENABLE_SZIP_SUPPORT:BOOL=OFF -DHDF4_ENABLE_EXAMPLES:BOOL=OFF \
+               -DCMAKE_BUILD_TYPE:STRING=Release ..
 
 Notes: CMake and HDF4
 
@@ -234,26 +310,24 @@ Notes: CMake and HDF4
 Notes: CMake in General
 
    1. More information about using CMake can be found at the KitWare site at 
-      www.cmake.org.
+         www.cmake.org.
          
    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.
 
 
-
 ========================================================================
-IV. Building HDF4 C/Fortran Libraries with CMake command line mode
+V. Options for Building HDF4 Libraries with the CMake Command Line
 ========================================================================
 
-This section provides more details on building the HDF4 C/Fortran Libraries
-with CMake using the CMake command line tools, go through these five steps:
+To build the HDF4 Libraries with CMake, go through these five steps:
 
    1. Run CMake
    2. Configure the cache settings
    3. Build HDF4
    4. Test HDF4
-   5. Packaging HDF4 (create install image)
+   5. Package HDF4 (create install image)
 
 These five steps are described in detail below.
 
@@ -261,9 +335,9 @@ These five steps are described in detail below.
 
    1. Run CMake
 
-      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 
+      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. 
@@ -277,32 +351,22 @@ These five steps are described in detail below.
       RECOMMENDED:
         Users can perform the configuration step without using the visual 
         cmake-gui program. We use the file cacheinit.cmake in the 
-        config/cmake folder for our testing. This file enables all of the 
-        basic options, and we turn specific options on or off for testing 
+        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 <sourcepath>/config/cmake/cacheinit.cmake -G "<generator>"  [-D<options>]  <sourcepath>
         
-        Where <sourcepath> is:
-            the relative path to the source folder.
-        
-        <generator> is:    
-            * Borland Makefiles
-            * MSYS Makefiles
+        Where <generator> is    
             * MinGW Makefiles
             * NMake Makefiles
             * Unix Makefiles
+            * Visual Studio 12
+            * Visual Studio 12 Win64
             * Visual Studio 11
             * Visual Studio 11 Win64
             * Visual Studio 10
             * Visual Studio 10 Win64
-            * Visual Studio 6
-            * Visual Studio 7
-            * Visual Studio 7 .NET 2003
-            * Visual Studio 8 2005
-            * Visual Studio 8 2005 Win64
-            * Visual Studio 9 2008
-            * Visual Studio 9 2008 Win64
 
         <options> is:
             * SZIP_INCLUDE_DIR:PATH=<path to szip includes directory>
@@ -318,62 +382,61 @@ These five steps are described in detail below.
             ########################
             # EXTERNAL cache entries
             ########################
-            SET (BUILD_SHARED_LIBS ON CACHE BOOL "Build Shared Libraries" FORCE)
-            SET (BUILD_TESTING ON CACHE BOOL "Build HDF4 Unit Testing" FORCE)
-            SET (HDF4_BUILD_EXAMPLES ON CACHE BOOL "Build HDF4 Library Examples" FORCE)
-            SET (HDF4_BUILD_FORTRAN ON CACHE BOOL "Build FORTRAN support" FORCE)
-            SET (HDF4_BUILD_TOOLS ON CACHE BOOL "Build HDF4 Tools" FORCE)
-            SET (HDF4_BUILD_UTILS ON CACHE BOOL "Build HDF4 Library Utilities" FORCE)
-            SET (HDF4_ENABLE_NETCDF ON CACHE BOOL "Build HDF4 versions of NetCDF-3 APIS" FORCE)
-            SET (HDF4_BUILD_XDR_LIB OFF CACHE BOOL "Build HDF4 XDR Library" FORCE)
-            SET (HDF4_ENABLE_PARALLEL OFF CACHE BOOL "Enable parallel build (requires MPI)" FORCE)
-            SET (MPIEXEC_MAX_NUMPROCS "3" CACHE STRING "Minimum number of processes for HDF parallel tests" FORCE)
-            SET (HDF4_ENABLE_JPEG_LIB_SUPPORT ON CACHE BOOL "Enable Jpeg library" FORCE)
-            SET (HDF4_ENABLE_Z_LIB_SUPPORT ON CACHE BOOL "Enable Zlib Filters" FORCE)
-            SET (HDF4_ENABLE_SZIP_SUPPORT ON CACHE BOOL "Use SZip Filter" FORCE)
-            SET (HDF4_ENABLE_SZIP_ENCODING ON CACHE BOOL "Use SZip Encoding" FORCE)
-            SET (HDF4_ENABLE_COVERAGE OFF CACHE BOOL "Enable code coverage for Libraries and Programs" FORCE)
-            SET (HDF4_DISABLE_COMPILER_WARNINGS OFF CACHE BOOL "Disable compiler warnings" FORCE)
-            SET (HDF4_PACKAGE_EXTLIBS OFF CACHE BOOL "(WINDOWS)CPACK - include external libraries" FORCE)
-            SET (HDF4_NO_PACKAGES OFF CACHE BOOL "CPACK - Disable packaging" FORCE)
-            SET (HDF4_ALLOW_EXTERNAL_SUPPORT "NO" CACHE STRING "Allow External Library Building" FORCE)
-            SET (ZLIB_SVN_URL "http://svn.hdfgroup.uiuc.edu/zlib/trunk" CACHE STRING "Use ZLib from HDF repository" FORCE)
-            SET (SZIP_SVN_URL "http://svn.hdfgroup.uiuc.edu/szip/trunk" CACHE STRING "Use SZip from HDF repository" FORCE)
-            SET (JPEG_SVN_URL "http://svn.hdfgroup.uiuc.edu/jpeg/branches/jpeg8b" CACHE STRING "Use JPEG from HDF repository" FORCE)
-            SET (ZLIB_TGZ_NAME "ZLib.tar.gz" CACHE STRING "Use ZLib from compressed file" FORCE)
-            SET (SZIP_TGZ_NAME "SZip.tar.gz" CACHE STRING "Use SZip from compressed file" FORCE)
-            SET (JPEG_TGZ_NAME "JPEG8b.tar.gz" CACHE STRING "Use JPEG from compressed file" FORCE)
+            set (BUILD_SHARED_LIBS ON CACHE BOOL "Build Shared Libraries" FORCE)
+            set (BUILD_TESTING ON CACHE BOOL "Build HDF4 Unit Testing" FORCE)
+            set (HDF4_BUILD_EXAMPLES ON CACHE BOOL "Build HDF4 Library Examples" FORCE)
+            set (HDF4_BUILD_FORTRAN ON CACHE BOOL "Build FORTRAN support" FORCE)
+            set (HDF4_BUILD_TOOLS ON CACHE BOOL "Build HDF4 Tools" FORCE)
+            set (HDF4_BUILD_UTILS ON CACHE BOOL "Build HDF4 Library Utilities" FORCE)
+            set (HDF4_ENABLE_NETCDF ON CACHE BOOL "Build HDF4 versions of NetCDF-3 APIS" FORCE)
+            set (HDF4_BUILD_XDR_LIB OFF CACHE BOOL "Build HDF4 XDR Library" FORCE)
+            set (HDF4_ENABLE_PARALLEL OFF CACHE BOOL "Enable parallel build (requires MPI)" FORCE)
+            set (MPIEXEC_MAX_NUMPROCS "3" CACHE STRING "Minimum number of processes for HDF parallel tests" FORCE)
+            set (HDF4_ENABLE_JPEG_LIB_SUPPORT ON CACHE BOOL "Enable Jpeg library" FORCE)
+            set (HDF4_ENABLE_Z_LIB_SUPPORT ON CACHE BOOL "Enable Zlib Filters" FORCE)
+            set (HDF4_ENABLE_SZIP_SUPPORT ON CACHE BOOL "Use SZip Filter" FORCE)
+            set (HDF4_ENABLE_SZIP_ENCODING ON CACHE BOOL "Use SZip Encoding" FORCE)
+            set (HDF4_ENABLE_COVERAGE OFF CACHE BOOL "Enable code coverage for Libraries and Programs" FORCE)
+            set (HDF4_DISABLE_COMPILER_WARNINGS OFF CACHE BOOL "Disable compiler warnings" FORCE)
+            set (HDF4_PACKAGE_EXTLIBS OFF CACHE BOOL "(WINDOWS)CPACK - include external libraries" FORCE)
+            set (HDF4_NO_PACKAGES OFF CACHE BOOL "CPACK - Disable packaging" FORCE)
+            set (HDF4_ALLOW_EXTERNAL_SUPPORT "NO" CACHE STRING "Allow External Library Building (NO SVN TGZ)" FORCE)
+            set_property (CACHE HDF4_ALLOW_EXTERNAL_SUPPORT PROPERTY STRINGS NO SVN TGZ)
+            set (ZLIB_SVN_URL "http://svn.hdfgroup.uiuc.edu/zlib/trunk" CACHE STRING "Use ZLib from HDF repository" FORCE)
+            set (SZIP_SVN_URL "http://svn.hdfgroup.uiuc.edu/szip/trunk" CACHE STRING "Use SZip from HDF repository" FORCE)
+            set (JPEG_SVN_URL "http://svn.hdfgroup.uiuc.edu/jpeg/branches/jpeg8b" CACHE STRING "Use JPEG from HDF repository" FORCE)
+            set (ZLIB_TGZ_NAME "ZLib.tar.gz" CACHE STRING "Use ZLib from compressed file" FORCE)
+            set (SZIP_TGZ_NAME "SZip.tar.gz" CACHE STRING "Use SZip from compressed file" FORCE)
+            set (JPEG_TGZ_NAME "JPEG8b.tar.gz" CACHE STRING "Use JPEG from compressed file" FORCE)
 
    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, to use Visual Studio 2012). CMake will read in the 
-           CMakeLists.txt files from the source directory and display options 
-           for the HDF4 project. After the first configure, you can adjust 
-           the cache settings and/or specify the locations of other programs.
+      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 HDF4 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. 
+           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 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.
+           On linux, if you are using the Unix Makefiles generator, the Makefiles will
+           be created in the build folder.
 
-      2.2  Recommended command line example on Windows in 
-           the C:\MyHDFstuff\hdf4\build directory:
+      2.2  Preferred command line example on Windows in c:\MyHDFstuff\hdf4\build directory:
       
-            cmake -C ../config/cmake/cacheinit.cmake -G "Visual Studio 10" \
-            -DHDF4_ENABLE_SZIP_SUPPORT:BOOL=OFF -DHDF4_ENABLE_Z_LIB_SUPPORT:BOOL=OFF ..
+               cmake -C ../config/cmake/cacheinit.cmake -G "Visual Studio 11" \
+               -DHDF4_ENABLE_SZIP_SUPPORT:BOOL=OFF -DHDF4_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 be sure that the following two options are correctly 
-           set/unset:
+      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:
            
            HDF4_NO_PACKAGES:BOOL=ON
            HDF4_USE_FOLDERS:BOOL=OFF
@@ -381,55 +444,50 @@ These five steps are described in detail below.
    3. Build HDF4
    
       On Windows, you can build HDF4 using either the Visual Studio Environment 
-      or the command line. The command line can be used on all platforms:
-      Windows, Linux, Unix, and Mac.
+      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 
-           Release, and then build the solution.
+           Release and build the solution.
              
       3.2.1  The external libraries (zlib, Szip, and jpeg) can be configured
            to allow building the libraries by downloading from an SVN repository.
            The option is 'HDF4_ALLOW_EXTERNAL_SUPPORT'; by adding the following
            configuration option:
-           
                -DHDF4_ALLOW_EXTERNAL_SUPPORT:STRING="SVN"
                
-           The options to control the SVN URL (config/cmake/cacheinit.cmake file) 
-           are:
-           
-               JPEG_SVN_URL:STRING="http://svn.hdfgroup.uiuc.edu/jpeg/branches/jpeg8b"
+           The options to control the SVN URL (config/cmake/cacheinit.cmake file) are:
+               JPEG_SVN_URL:STRING="http://svn.hdfgroup.uiuc.edu/jpeg8b/trunk"
                ZLIB_SVN_URL:STRING="http://svn.hdfgroup.uiuc.edu/zlib/trunk"
                SZIP_SVN_URL:STRING="http://svn.hdfgroup.uiuc.edu/szip/trunk"
-               
-           These should be changed to your location.
+           These should be changed to your location. Also define CMAKE_BUILD_TYPE
+           to be the configuration type.
            
       3.2.2  Or the external libraries (zlib, Szip, and jpeg) can be configured
            to allow building the libraries by using a compressed file.
            The option is 'HDF4_ALLOW_EXTERNAL_SUPPORT' and is enabled by 
            adding the following configuration option:
-           
                -DHDF4_ALLOW_EXTERNAL_SUPPORT:STRING="TGZ"
                
            The options to control the SVN URL (config/cmake/cacheinit.cmake 
            file) are:
-           
                JPEG_TGZ_NAME:STRING="jpeg_src.ext"
                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 
-            file such as .bz2, .tar, .tar.gz, .tgz, or .zip.
+            file such as .bz2, .tar, .tar.gz, .tgz, or .zip. Also define
+            CMAKE_BUILD_TYPE to be the configuration type.
 
    4. Test HDF4
 
@@ -443,50 +501,46 @@ These five steps are described in detail below.
 
    5. Packaging HDF4 (create an install image)
    
-      To package the build into a simple installer using the NullSoft 
-      installer NSIS on Windows, or into compressed files (.tar.gz, .sh, 
-      .zip), use the CPack tool.
+      To package the build into a simple installer using 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:
+      To package the build, navigate to your build directory and execute;
       
               cpack -C {Debug | Release} CPackConfig.cmake
       
-      NOTES: 
-      
-      See note 8 below for NSIS information. 
-      
-      Also, if you are using a Visual Studio Express version or do not 
-      want to enable the packaging components, set HDF4_NO_PACKAGES 
-      to ON (on the command line add -DHDF4_NO_PACKAGES:BOOL=ON)
+      NOTE: See note 8 of this document for NSIS information.
+            Also, if you are using a Visual Studio Express version or do not 
+            want to enable the packaging components, set HDF4_NO_PACKAGES 
+            to ON (on the command line add -DHDF4_NO_PACKAGES:BOOL=ON)
            
-   6. The files that support building HDF4 with CMake are all of the files 
-      in the config/cmake folder, the CMakeLists.txt and CMakeTests.cmake 
-      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 
-      requirements.
-
-   7. More information about using CMake can be found at the KitWare site at 
-      www.cmake.org.
+   6. The files that support building HDF4 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 
+      installation and needs.
 
-   8. 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. 
+   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. 
 
 
 
 ========================================================================
-V. All Options for HDF4 C/Fortran Libraries with CMake
+VI. CMake Option Defaults for HDF4
 ========================================================================
 
 In the options listed below, there are three columns of information: 
-Option Name, Option Description, and Option Default.
+Option Name, Option Description, and Option Default. 
+The config/cmake/cacheinit.cmake file overrides the following values.
 
 ---------------- General Build Options ---------------------
 BUILD_SHARED_LIBS  "Build Shared Libraries"    OFF
@@ -509,9 +563,9 @@ HDF4_ENABLE_PARALLEL           "Enable parallel build (requires MPI)"
 HDF4_NO_PACKAGES               "Do not include CPack Packaging"                               OFF
 HDF4_PACKAGE_EXTLIBS           "CPACK - include external libraries"                           OFF
 HDF4_USE_FOLDERS               "Enable folder grouping of projects in IDEs."                  OFF
-IF (APPLE) 
+if (APPLE) 
     HDF4_BUILD_WITH_INSTALL_NAME "Build with library install_name set to the installation path"  OFF
-IF (WIN32 AND NOT CYGWIN) 
+if (WIN32) 
     HDF_LEGACY_NAMING          "Use Legacy Names for Libraries and Programs" OFF
 
 ---------------- External Library Options ---------------------
@@ -522,409 +576,152 @@ HDF4_ENABLE_Z_LIB_SUPPORT    "Enable Zlib Filters"                    ON
 JPEG_USE_EXTERNAL            "Use External Library Building for JPEG" 0
 SZIP_USE_EXTERNAL            "Use External Library Building for SZIP" 0
 ZLIB_USE_EXTERNAL            "Use External Library Building for ZLIB" 0
-IF (HDF4_ENABLE_SZIP_SUPPORT) 
+if (HDF4_ENABLE_SZIP_SUPPORT) 
     HDF4_ENABLE_SZIP_ENCODING "Use SZip Encoding"      OFF
 
 
 
 ========================================================================
-VI. User-defined Options for HDF4 Libraries with CMake
+VII. User Defined Options for HDF4 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
+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. 
 
 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.
+build and test process.
 
 ========================================================================
-VII. APPENDIX
+VIII. Options for Platform Configuration Files
 ========================================================================
 
-Below are examples of the ctest scripts used by The HDF Group.
-The examples are for a Linux machine, but the same scripts can be used on 
+Below is the HDF4LinuxCmake.cmake ctest script with extra comments.
+The example is for a linux machine, but the same scripts can be used on 
 a Windows machine by adjusting the CTEST_CMAKE_GENERATOR option in the
-product specific script.
-
-NOTE: these files are available at the HDF web site:
-    http://www.hdfgroup.org/release4/cmakebuild.html
-
-    CTestScript.cmake
-    SZip.tar.gz
-    ZLib.tar.gz
-    JPEG.tar.gz
-    
-    HDF4WindowsCMake.cmake
-    HDF4LinuxCMake.cmake
-    HDF4MacCMake.cmake
-
-
-
-========================================================================
-CTestScript.cmake                                                       
-========================================================================
-
-The CTestScript.cmake script shown below is a common ctest script that 
-is used to build, test, and package HDF4 Library files.
-
-
-
-cmake_minimum_required(VERSION 2.8.10 FATAL_ERROR)
-########################################################
-# This dashboard is maintained by The HDF Group
-# For any comments please contact cdashhelp at hdfgroup.org
-#
-########################################################
-# ----------------------------------------------------------- 
-# -- Get environment
-# ----------------------------------------------------------- 
-if(NOT SITE_OS_NAME)
-  ## machine name not provided - attempt to discover with uname
-  ## -- set hostname
-  ## --------------------------
-  find_program(HOSTNAME_CMD NAMES hostname)
-  exec_program(${HOSTNAME_CMD} ARGS OUTPUT_VARIABLE HOSTNAME)
-  set(CTEST_SITE  "${HOSTNAME}${CTEST_SITE_EXT}")
-  find_program(UNAME NAMES uname)
-  macro(getuname name flag)
-    exec_program("${UNAME}" ARGS "${flag}" OUTPUT_VARIABLE "${name}")
-  endmacro(getuname)
- 
-  getuname(osname -s)
-  getuname(osrel  -r)
-  getuname(cpu    -m)
-  message("Dashboard script uname output: ${osname}-${osrel}-${cpu}\n")
-
-  set(CTEST_BUILD_NAME  "${osname}-${osrel}-${cpu}")
-  if(USE_AUTOTOOLS)
-    set(CTEST_BUILD_NAME  "AT-${CTEST_BUILD_NAME}")
-  endif(USE_AUTOTOOLS)
-  if(SITE_BUILDNAME_SUFFIX)
-    set(CTEST_BUILD_NAME  "${CTEST_BUILD_NAME}-${SITE_BUILDNAME_SUFFIX}")
-  endif(SITE_BUILDNAME_SUFFIX)
-  set(BUILD_OPTIONS "${ADD_BUILD_OPTIONS}")
-else(NOT SITE_OS_NAME)
-  ## machine name provided
-  ## --------------------------
-  if(CMAKE_HOST_UNIX)
-    set(CTEST_BUILD_NAME "${SITE_OS_NAME}-${SITE_OS_VERSION}-${SITE_OS_BITS}-${SITE_COMPILER_NAME}-${SITE_COMPILER_VERSION}")
-  else(CMAKE_HOST_UNIX)
-    set(CTEST_BUILD_NAME "${SITE_OS_NAME}-${SITE_OS_VERSION}-${SITE_COMPILER_NAME}")
-  endif(CMAKE_HOST_UNIX)
-  if(SITE_BUILDNAME_SUFFIX)
-    set(CTEST_BUILD_NAME ${CTEST_BUILD_NAME}-${SITE_BUILDNAME_SUFFIX})
-  endif(SITE_BUILDNAME_SUFFIX)
-  set(BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DSITE:STRING=${CTEST_SITE} -DBUILDNAME:STRING=${CTEST_BUILD_NAME}")
-endif(NOT SITE_OS_NAME)
- 
-#-----------------------------------------------------------------------------
-# MAC machines need special option
-#-----------------------------------------------------------------------------
-if(APPLE)
-  # Compiler choice
-  execute_process(COMMAND xcrun --find cc OUTPUT_VARIABLE XCODE_CC OUTPUT_STRIP_TRAILING_WHITESPACE)
-  execute_process(COMMAND xcrun --find c++ OUTPUT_VARIABLE XCODE_CXX OUTPUT_STRIP_TRAILING_WHITESPACE)
-  set(ENV{CC} "${XCODE_CC}")
-  set(ENV{CXX} "${XCODE_CXX}")
-
-  if(NOT NO_MAC_FORTRAN)
-    # Shared fortran is not supported, build static 
-    set(BUILD_OPTIONS "${BUILD_OPTIONS} -DBUILD_SHARED_LIBS:BOOL=OFF -DCMAKE_ANSI_CFLAGS:STRING=-fPIC")
-  else(NOT NO_MAC_FORTRAN)
-    set(BUILD_OPTIONS "${BUILD_OPTIONS} -DHDF5_BUILD_FORTRAN:BOOL=OFF")
-  endif(NOT NO_MAC_FORTRAN)
-
-  set(BUILD_OPTIONS "${BUILD_OPTIONS} -DCTEST_USE_LAUNCHERS:BOOL=ON -DCMAKE_BUILD_WITH_INSTALL_RPATH:BOOL=OFF")
-endif(APPLE)
-
-#-----------------------------------------------------------------------------
-## cygwin does not handle the find_package() call
-## --------------------------
-if(NOT SITE_CYGWIN})
-  find_package (Subversion)
-  set(CTEST_UPDATE_COMMAND "${Subversion_SVN_EXECUTABLE}")
-else(NOT SITE_CYGWIN})
-  set(CTEST_UPDATE_COMMAND "/usr/bin/svn")
-endif(NOT SITE_CYGWIN})
- 
-#-----------------------------------------------------------------------------
-set(NEED_REPOSITORY_CHECKOUT 0)
-set(CTEST_CMAKE_COMMAND "\"${CMAKE_COMMAND}\"")
-if(CTEST_USE_TAR_SOURCE)
-  ## Uncompress source if tar file provided
-  ## --------------------------
-  if(WIN32)
-    set(CTEST_7Z_COMMAND "C:/Program Files/7-Zip/7z.exe")
-    message("extracting... [${CTEST_7Z_COMMAND} x ${CTEST_USE_TAR_SOURCE}.zip]")
-    execute_process(COMMAND ${CTEST_7Z_COMMAND} x ${CTEST_USE_TAR_SOURCE}.zip RESULT_VARIABLE rv)
-  else(WIN32)
-    message("extracting... [${CTEST_CMAKE_COMMAND} -E tar -xvf ${CTEST_USE_TAR_SOURCE}.tar]")
-    execute_process(COMMAND tar -xvf ${CTEST_USE_TAR_SOURCE}.tar RESULT_VARIABLE rv)
-  endif(WIN32)
- 
-  if(NOT rv EQUAL 0)
-    message("extracting... [error-(${rv}) clean up]")
-    file(REMOVE_RECURSE "${CTEST_SOURCE_DIRECTORY}")
-    message(FATAL_ERROR "error: extract of ${CTEST_USE_TAR_SOURCE} failed")
-  endif(NOT rv EQUAL 0)
-     
-  file(RENAME ${CTEST_USE_TAR_SOURCE} ${CTEST_SOURCE_DIRECTORY})
-  set(LOCAL_SKIP_UPDATE "TRUE")
-else(CTEST_USE_TAR_SOURCE)
-  ## use subversion to get source
-  ## --------------------------
-  if(NOT EXISTS "${CTEST_SOURCE_DIRECTORY}")
-    set(NEED_REPOSITORY_CHECKOUT 1)
-  endif(NOT EXISTS "${CTEST_SOURCE_DIRECTORY}")
- 
-  if(${NEED_REPOSITORY_CHECKOUT})
-    set(CTEST_CHECKOUT_COMMAND
-      "${CTEST_UPDATE_COMMAND} co ${REPOSITORY_URL} \"${CTEST_SOURCE_DIRECTORY}\" -r HEAD")
-  else(${NEED_REPOSITORY_CHECKOUT})
-    set(CTEST_CHECKOUT_COMMAND "${CTEST_UPDATE_COMMAND} update")
-  endif(${NEED_REPOSITORY_CHECKOUT})
-endif(CTEST_USE_TAR_SOURCE)
- 
-#-----------------------------------------------------------------------------
-## Clear the build directory
-## --------------------------
-set(CTEST_START_WITH_EMPTY_BINARY_DIRECTORY TRUE)
-file(MAKE_DIRECTORY "${CTEST_BINARY_DIRECTORY}")
-#include(${CTEST_SOURCE_DIRECTORY}/CTestConfig.cmake)
-ctest_empty_binary_directory(${CTEST_BINARY_DIRECTORY})
-
-# Use multiple CPU cores to build
-include(ProcessorCount)
-ProcessorCount(N)
-if(NOT N EQUAL 0)
-  if(NOT WIN32)
-    set(CTEST_BUILD_FLAGS -j${N})
-  endif(NOT WIN32)
-  set(ctest_test_args ${ctest_test_args} PARALLEL_LEVEL ${N})
-endif()
- 
-#-----------------------------------------------------------------------------
-# Send the main script as a note.
-if(USE_AUTOTOOLS)
-  ## autotools builds need to use make and does not use the cacheinit.cmake file
-  ## -- make command
-  ## -----------------
-  find_program(MAKE NAMES make)
- 
-  list(APPEND CTEST_NOTES_FILES
-    "${CTEST_SCRIPT_DIRECTORY}/${CTEST_SCRIPT_NAME}"
-    "${CMAKE_CURRENT_LIST_FILE}"
-  )
-else(USE_AUTOTOOLS)
-  list(APPEND CTEST_NOTES_FILES
-    "${CTEST_SCRIPT_DIRECTORY}/${CTEST_SCRIPT_NAME}"
-    "${CMAKE_CURRENT_LIST_FILE}"
-    "${CTEST_SOURCE_DIRECTORY}/config/cmake/cacheinit.cmake"
-  )
-endif(USE_AUTOTOOLS)
- 
-#-----------------------------------------------------------------------------
-# Check for required variables.
-# --------------------------
-foreach(req
-    CTEST_CMAKE_GENERATOR
-    CTEST_SITE
-    CTEST_BUILD_NAME
-  )
-  if(NOT DEFINED ${req})
-    message(FATAL_ERROR "The containing script must set ${req}")
-  endif(NOT DEFINED ${req})
-endforeach(req)
- 
-#-----------------------------------------------------------------------------
-# Initialize the CTEST commands
-#------------------------------
-if(USE_AUTOTOOLS)
-  set(CTEST_CONFIGURE_COMMAND  "${CTEST_SOURCE_DIRECTORY}/configure ${ADD_BUILD_OPTIONS}")
-  set(CTEST_BUILD_COMMAND      "${MAKE} ${CTEST_BUILD_FLAGS}")
-  ## -- CTest Config
-  #configure_file($ENV{HOME}/CTestConfiguration/CTestConfig.cmake    ${CTEST_SOURCE_DIRECTORY}/CTestConfig.cmake)
-  configure_file(${CTEST_SOURCE_DIRECTORY}/config/cmake/CTestCustom.cmake ${CTEST_BINARY_DIRECTORY}/CTestCustom.cmake)
-  ## -- CTest Testfile
-#  configure_file(${CTEST_SCRIPT_DIRECTORY}/CTestTestfile.cmake ${CTEST_BINARY_DIRECTORY}/CTestTestfile.cmake)
-  file(WRITE ${CTEST_BINARY_DIRECTORY}/CTestTestfile.cmake "ADD_TEST(makecheck \"${MAKE}\" \"${CTEST_BUILD_FLAGS}\" \"-i\" \"check\")")
-else(USE_AUTOTOOLS)
-  if(LOCAL_MEMCHECK_TEST)
-    find_program(CTEST_MEMORYCHECK_COMMAND NAMES valgrind)
-    set (CTEST_CONFIGURE_COMMAND
-        "${CTEST_CMAKE_COMMAND} -C \"${CTEST_SOURCE_DIRECTORY}/config/cmake/mccacheinit.cmake\" -DCMAKE_BUILD_TYPE:STRING=${CTEST_BUILD_CONFIGURATION} ${BUILD_OPTIONS} \"-G${CTEST_CMAKE_GENERATOR}\" \"${CTEST_SOURCE_DIRECTORY}\""
-    )
-  else(LOCAL_MEMCHECK_TEST)
-    find_program(CTEST_COVERAGE_COMMAND NAMES gcov)
-    set (CTEST_CONFIGURE_COMMAND
-        "${CTEST_CMAKE_COMMAND} -C \"${CTEST_SOURCE_DIRECTORY}/config/cmake/cacheinit.cmake\" -DCMAKE_BUILD_TYPE:STRING=${CTEST_BUILD_CONFIGURATION} ${BUILD_OPTIONS} \"-G${CTEST_CMAKE_GENERATOR}\" \"${CTEST_SOURCE_DIRECTORY}\""
-    )
-  endif(LOCAL_MEMCHECK_TEST)
-endif(USE_AUTOTOOLS)
- 
-#-----------------------------------------------------------------------------
-## -- set output to english
-set($ENV{LC_MESSAGES}  "en_EN")
- 
-# Print summary information.
-foreach(v
-    CTEST_SITE
-    CTEST_BUILD_NAME
-    CTEST_SOURCE_DIRECTORY
-    CTEST_BINARY_DIRECTORY
-    CTEST_CMAKE_GENERATOR
-    CTEST_BUILD_CONFIGURATION
-    CTEST_GIT_COMMAND
-    CTEST_CHECKOUT_COMMAND
-    CTEST_CONFIGURE_COMMAND
-    CTEST_SCRIPT_DIRECTORY
-    CTEST_USE_LAUNCHERS
-  )
-  set(vars "${vars}  ${v}=[${${v}}]\n")
-endforeach(v)
-message("Dashboard script configuration:\n${vars}\n")
- 
-#-----------------------------------------------------------------------------
-#-----------------------------------------------------------------------------
-  ## NORMAL process
-  ## -- LOCAL_UPDATE updates the source folder from svn
-  ## -- LOCAL_SUBMIT reports to CDash server
-  ## -- LOCAL_SKIP_TEST skips the test process (only builds)
-  ## -- LOCAL_MEMCHECK_TEST executes the Valgrind testing
-  ## -- LOCAL_COVERAGE_TEST executes code coverage process
-  ## --------------------------
-  CTEST_START (${MODEL} TRACK ${MODEL})
-  if(LOCAL_UPDATE)
-    CTEST_UPDATE (SOURCE "${CTEST_SOURCE_DIRECTORY}")
-  endif(LOCAL_UPDATE)
-  CTEST_CONFIGURE (BUILD "${CTEST_BINARY_DIRECTORY}")
-  CTEST_READ_CUSTOM_FILES ("${CTEST_BINARY_DIRECTORY}")
-  if(LOCAL_SUBMIT)
-    CTEST_SUBMIT (PARTS Update Configure Notes)
-  endif(LOCAL_SUBMIT)
-   CTEST_BUILD (BUILD "${CTEST_BINARY_DIRECTORY}" APPEND)
-  if(LOCAL_SUBMIT)
-    CTEST_SUBMIT (PARTS Build)
-  endif(LOCAL_SUBMIT)
-  if(NOT LOCAL_SKIP_TEST)
-    if(NOT LOCAL_MEMCHECK_TEST)
-      CTEST_TEST (BUILD "${CTEST_BINARY_DIRECTORY}" APPEND ${ctest_test_args} RETURN_VALUE res)
-      if(LOCAL_SUBMIT)
-        CTEST_SUBMIT (PARTS Test)
-      endif(LOCAL_SUBMIT)
-    if(res GREATER 0)
-      message(FATAL_ERROR "Failed tests: ${res}\n")
-    endif(res GREATER 0)
-    else(NOT LOCAL_MEMCHECK_TEST)
-      CTEST_MEMCHECK (BUILD "${CTEST_BINARY_DIRECTORY}" APPEND ${ctest_test_args})
-      if(LOCAL_SUBMIT)
-        CTEST_SUBMIT (PARTS MemCheck)
-      endif(LOCAL_SUBMIT)
-    endif(NOT LOCAL_MEMCHECK_TEST)
-    if(LOCAL_COVERAGE_TEST)
-      CTEST_COVERAGE (BUILD "${CTEST_BINARY_DIRECTORY}" APPEND)
-      if(LOCAL_SUBMIT)
-        CTEST_SUBMIT (PARTS Coverage)
-      endif(LOCAL_SUBMIT)
-    endif(LOCAL_COVERAGE_TEST)
-  endif(NOT LOCAL_SKIP_TEST)
-  if(NOT LOCAL_MEMCHECK_TEST AND NOT LOCAL_NO_PACKAGE)
-    ##-----------------------------------------------
-    ## Package the product
-    ##-----------------------------------------------
-    execute_process(COMMAND cpack -C ${CTEST_BUILD_CONFIGURATION} -V
-      WORKING_DIRECTORY ${CTEST_BINARY_DIRECTORY}
-      RESULT_VARIABLE cpackResult
-      OUTPUT_VARIABLE cpackLog
-      ERROR_VARIABLE cpackLog.err
-    )
-    file(WRITE ${CTEST_BINARY_DIRECTORY}/cpack.log "${cpackLog.err}" "${cpackLog}")
-    if(cpackResult GREATER 0)
-      message(FATAL_ERROR "Failed packaging: ${cpackResult}\n")
-    endif(cpackResult GREATER 0)
-  endif(NOT LOCAL_MEMCHECK_TEST AND NOT LOCAL_NO_PACKAGE)
-#-----------------------------------------------------------------------------
- 
-message("DONE:CTestScript")
-
-
-========================================================================
-ctest
-========================================================================
-
-Below is an example of the ctest script used by The HDF Group. The
-CTestScript.cmake file used by this script is shown above. Adjust the values 
-as necessary. Note that the source folder is entered on the command line 
-and the build folder is created as a sub-folder.
-
+platform configuration script.
 
 
 ############################################################################
-# Product specific script, HDF4Static.cmake, that uses the 
-# CTestScript.cmake file (see above). Usage:
-# "ctest -S HDF4Static.cmake,hdf4 -C Release -O hdf4static.log"
-# where hdf4 is the source folder relative to the location of these scripts
+# Product specific script, HDF4LinuxCmake.cmake, that uses the 
+# CTestScript.cmake file. Usage:
+# "ctest -S HDF4LinuxCmake.cmake -C Release -O hdf4shared.log"
 ############################################################################
 cmake_minimum_required(VERSION 2.8.10 FATAL_ERROR)
-set(CTEST_SOURCE_NAME ${CTEST_SCRIPT_ARG})
+
+# this is the location of the source hardcoded to hdf-4.2.11
+set(CTEST_SOURCE_NAME hdf-4.2.11)
+# this is the location of the source with ctest parameter hdf4src
+# "ctest -S HDF4LinuxCmake.cmake,hdf4src -C Release -O hdf4static.log"
+#set(CTEST_SOURCE_NAME ${CTEST_SCRIPT_ARG})
+
+# this is the location of the build directory
 set(CTEST_BINARY_NAME ${CTEST_SOURCE_NAME}/build)
+
+# this is the directory the script is executed from
 set(CTEST_DASHBOARD_ROOT "${CTEST_SCRIPT_DIRECTORY}")
+
+# this is the full path of the source directory
 set(CTEST_SOURCE_DIRECTORY "${CTEST_DASHBOARD_ROOT}/${CTEST_SOURCE_NAME}")
+
+# this is the  full path of the build directory
 set(CTEST_BINARY_DIRECTORY "${CTEST_DASHBOARD_ROOT}/${CTEST_BINARY_NAME}")
-set(MODEL "Experimental")
 
-####### Following Line is one of [Release, RelWithDebInfo, Debug] #############
-set(CTEST_BUILD_CONFIGURATION "RelWithDebInfo")
-######### Following describes computer ############
-set(CTEST_CMAKE_GENERATOR "Unix Makefiles")
 
+###################################################################
+### Following Line is one of [Release, RelWithDebInfo, Debug] #####
+set(CTEST_BUILD_CONFIGURATION "Release")
+###################################################################
+
+###################################################################
+#########       Following describes compiler           ############
+# this is for linux
+set(CTEST_CMAKE_GENERATOR "Unix Makefiles")
+# this is for windows 32 bit
+#set(CTEST_CMAKE_GENERATOR "Visual Studio 11")
+# this is for windows 64 bit
+#set(CTEST_CMAKE_GENERATOR "Visual Studio 11 Win64")
+# Visual Studio 2013 is 12, Visual Studio 2012 is 11,  Visual Studio 2010 is 10
+###################################################################
+
+###################################################################
+#########       Following is for submission to CDash   ############
+###################################################################
+set(MODEL "Experimental")
+#########       Following describes computer           ############
 ##  Set the following to unique id your computer  ##
 set(CTEST_SITE "LINUX.XXXX")
-## following is optional to describe build ##
-set(SITE_BUILDNAME_SUFFIX "RWDI-SHARED")
-####################################################
+##    following is optional to describe build     ##
+set(SITE_BUILDNAME_SUFFIX "SHARED")
 
-##### Following controls CDash submission  #####
+#########   Following controls CDash submission          ##########
 #set(LOCAL_SUBMIT "TRUE")
-##### Following controls test process  #####
+#########   Following controls test process              ##########
 #set(LOCAL_SKIP_TEST "TRUE")
 #set(LOCAL_MEMCHECK_TEST "TRUE")
 #set(LOCAL_COVERAGE_TEST "TRUE")
-##### Following controls cpack command  #####
-set(LOCAL_NO_PACKAGE "TRUE")
-##### Following controls source update  #####
+#########   Following controls cpack command             ##########
+#set(LOCAL_NO_PACKAGE "TRUE")
+#########   Following controls source update             ##########
 #set(LOCAL_UPDATE "TRUE")
-set(REPOSITORY_URL "http://svn.hdfgroup.uiuc.edu/hdf4/branches/hdf4_2_10")
-#uncomment to use a compressed source file *.tgz
-#set(CTEST_USE_TAR_SOURCE "hdf-4.2.10")
-############################################
+#########   Following controls source repository         ##########
+#set(REPOSITORY_URL "http://svn.hdfgroup.uiuc.edu/hdf4/trunk")
+#comment to use a uncompressed source folder
+set(CTEST_USE_TAR_SOURCE "hdf-4.2.11")
+###################################################################
 
+###################################################################
 ####  Change default configuration of options in config/cmake/cacheinit.cmake file ###
-### uncomment and change the following line for more configuration options
-#set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DXXX:XXX=XXX")
+####  format: set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DXXX:YY=ZZZZ")
+
+### uncomment/comment and change the following lines for configuration options
+
 ### uncomment the following line to build static libraries
 #set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DBUILD_SHARED_LIBS:BOOL=OFF")
-### ext libs from svn
-#set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF4_ALLOW_EXTERNAL_SUPPORT:STRING=SVN")
+
+####      ext libraries       ####
 ### ext libs from tgz
 set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF4_ALLOW_EXTERNAL_SUPPORT:STRING=TGZ -DTGZPATH:PATH=${CTEST_SCRIPT_DIRECTORY}")
-### Create install package with external libraries (szip, zlib, szip)
+### ext libs from svn
+#set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF4_ALLOW_EXTERNAL_SUPPORT:STRING=SVN")
+### ext libs on system
+#set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DJPEG_LIBRARY:FILEPATH=some_location/lib/jpeg.lib -DJPEG_INCLUDE_DIR:PATH=some_location/include")
+#set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DZLIB_LIBRARY:FILEPATH=some_location/lib/zlib.lib -DZLIB_INCLUDE_DIR:PATH=some_location/include")
+#set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DSZIP_LIBRARY:FILEPATH=some_location/lib/szlib.lib -DSZIP_INCLUDE_DIR:PATH=some_location/include")
+
+####      fortran       ####
+### enable Fortran 2003
+#set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF4_ENABLE_F2003:BOOL=ON")
+### disable Fortran
+#set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF4_BUILD_FORTRAN:BOOL=OFF")
+
+### Create install package with external libraries (szip, zlib)
 set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF4_PACKAGE_EXTLIBS:BOOL=ON")
+
 ### disable test program builds
 #set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DBUILD_TESTING:BOOL=OFF")
+
 ### disable packaging
 #set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF4_NO_PACKAGES:BOOL=ON")
-############################################
 
-include(${CTEST_SCRIPT_DIRECTORY}/CTestScript.cmake)
+### disable building examples
+#set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DHDF4_BUILD_EXAMPLES:BOOL=OFF")
+
+### disable building tests
+#set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DBUILD_TESTING:BOOL=OFF")
+
+### change install prefix
+#set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DCMAKE_INSTALL_PREFIX:PATH=install")
+###################################################################
 
+include(${CTEST_SCRIPT_DIRECTORY}/CTestScript.cmake)
 
 
 ========================================================================
 For further assistance, send email to help at hdfgroup.org
 ========================================================================
 
-========================================================================
+
+
diff --git a/release_notes/INSTALL_CYGWIN.txt b/release_notes/INSTALL_CYGWIN.txt
index ac904d8..52a4719 100644
--- a/release_notes/INSTALL_CYGWIN.txt
+++ b/release_notes/INSTALL_CYGWIN.txt
@@ -10,7 +10,7 @@ NOTE: hdf4 can be built with CMake, see the INSTALL_CMake.txt file for more guid
 Preconditions:
 --------------
 
-1. Installed Cygwin 1.7.25 or higher
+1. Installed Cygwin 1.7.32 or higher
 
    To install the Cygwin net release, go to http://www.cygwin.com and 
    click on "setup-x86.exe" (32-bit installation) under the heading
@@ -34,7 +34,7 @@ Preconditions:
     
     The following compilers are supported by HDF4 and included in the Cygwin
     package system:
-       gcc (4.7.3), which includes:
+       gcc (4.8.3), which includes:
             gcc4-core    : C compiler
             gcc4-g++     : C++ compiler
             gcc4-fortran : fortran compiler
@@ -57,7 +57,7 @@ Preconditions:
     
     The following libraries are required to build HDF4:
     
-        libjpeg-devel   : JPEG library
+        libjpeg-devel   : JPEG library (either 6b or 8b)
         tirpc           : RPC library
         zlib            : Zlib compression library
 
@@ -79,10 +79,6 @@ Preconditions:
     see http://hdfgroup.org/doc_resource/SZIP/Commercial_szip.html
     for information regarding commercial use.   
 
-    The szip library is not distributed with the Cygwin packaging system.
-    However, a recent Cygwin binary can be found at:
-        ftp://ftp.hdfgroup.org/lib-external/szip/2.0/bin/cygwin/
-
     
     2.3 Additional Utilities
     
@@ -133,7 +129,7 @@ Notes: Use the configure command in the top level HDF4 directory.
          automatically find the library. In this case, the corresponding
          configure flag may be omitted.
        * Note that --prefix defines where the installation path is.
-         The default is set as <hdf4_build_directory>/NewHDF 
+         The default is set as <hdf4_build_directory>/hdf4 
 
 4. To Build and Test:
 
@@ -147,8 +143,11 @@ Notes: Use the configure command in the top level HDF4 directory.
 
 5. To Install:
 
-         make install
+        make install
+
+6. To test the installation:
 
+	make installcheck
 
 Acknowledgements:
 -----------------
diff --git a/release_notes/RELEASE.txt b/release_notes/RELEASE.txt
index 859cc5a..30c897c 100644
--- a/release_notes/RELEASE.txt
+++ b/release_notes/RELEASE.txt
@@ -1,19 +1,15 @@
-HDF version 4.2.10 released on 2014-02-09
-==============================================
+HDF version 4.2.11 released on 2015-02-09
+====================================================
 
 INTRODUCTION
 
-This document describes the differences between HDF 4.2.9 and HDF 4.2.10.
+This document describes the differences between HDF 4.2.10 and HDF 4.2.11.
 It is written for people who are familiar with previous releases of HDF 
-and wish to migrate to HDF 4.2.10.
+and wish to migrate to HDF 4.2.11.
 
-The HDF 4.2.10 documentation can be found on the The HDF Group's website
+The HDF 4.2.11 documentation can be found on the The HDF Group's website
 at:
-    http://www.hdfgroup.org/doc.html
-
-Previous versions of the documentation are available from the FTP server:
-
-    ftp://ftp.hdfgroup.org/HDF/Documentation/
+    http://www.hdfgroup.org/release4/doc/
 
 First-time HDF users are encouraged to read the HDF FAQ, which can be
 reached from the HDF product home page:
@@ -29,7 +25,7 @@ CONTENTS
 - New features and changes
   -- Configuration
 - Support for new platforms and compilers
-- Bugs fixed since HDF 4.2.9
+- Bugs fixed since HDF 4.2.10
   -- Configuration
   -- Library
   -- Utilities
@@ -42,84 +38,133 @@ New features and changes
 ========================
    Configuration
    ============= 
-   CMake - Added support to create dmg bundles on Mac.
-     (ADB 2013/9/12)
-   CMake - Added support to use Windows /MT option.
-     (ADB 2013/6/10)
+    - None
      
 
 Support for new platforms and compilers
 =======================================
-    - Visual Studio 2012 w/ Intel Fortran 13 on Windows 7 and Windows 8
-    - Mac OS X Mavericks with clang and gfortran
+    - None
 
 
-Bugs fixed since HDF 4.2.9
+Bugs fixed since HDF 4.2.10
 =========================
    Configuration
    =============
-   - Removed the requirement of yacc/lex like tools. The ncgenXXX.* files
-     generated files from yacc and lex input files are pre-created in the
-     source code to build the ncgen tool. The msoft*.[ch] files were for
-     Windows build but was out of dated. Cmake uses the pre-created files
-     instead. See known problem below. (AKC 2014/02/02 HDFFR-1419)
-
-   - Removed old Macintosh platform codes that are not used any more.
-     (AKC 2014/01/21 HDFFR-1340)
-
-   - Changed Mac platforms to use the Apple supported clang compiler as the
-     default C compiler. (AKC 2014/01/15 HDFFR-1318)
-
-   - Removed the following individual platform specific files and have them to
-     be produced by configure using corresponding *.in files.
-     mfhdf/libsrc/config/netcdf-XXX.h    by mfhdf/libsrc/netcdf.h.in
-     mfhdf/fortran/config/ftest-XXX.f    by mfhdf/fortran/ftest.f.in
-     mfhdf/fortran/config/jackets-XXX.c  by mfhdf/fortran/jackets.c.in
-     mfhdf/fortran/config/netcdf-XXX.inc by mfhdf/fortran/netcdf.inc.in
-     (AKC 2013/12/31 HDFFR-1320/476)
-
-   - The following platforms are old and no longer available. Removed their
-     support code from the configure files:
-     alpha, convex, dec, fujivp, hpux, ia64, irix32, irix4, irix5, irix6, mac,
-     solarisx86, sun, t3e, unicos. (AKC 2013/12/26 HDFFR-1320)
-
-   - Removed -Xc (strict ansi standard) from the default CFLAGS of Solaris
-     since the latest Sun Compiler version 5.11 and 5.12 have a conflict with
-     the system header file. Since the current versions of C compiler should be
-     at least ANSI (aka C89) compliant, the removal of -Xc should be safe. This
-     also fixes a previous known problem of needing to use -xc99 to build HDF4.
-     (AKC 2013/12/20 HDFFR-1361)
-
-   - CMake - Changed name of TGZ_PATH to TGZPATH.
-           (ADB 2013/9/12)
-   - CMake - Removed extra flag POSIX_SOURCE as it caused failures on Apple Mac
-     builds. (ADB 2013/8/7)
+    - Windows installer incorrect display of PATH environment variable.
+    
+      In the Windows installer, the dialog box where the user can elect to
+      add the product's bin path to the %PATH% environment variable displayed
+      an incorrect path. This path was missing the C:\Program Files part
+      and used the POSIX file separator '/' before the bin (<path>/bin,
+      instead of <path>\bin).
+      
+      The dialog box text was changed to simply say that the product's bin
+      path would be added instead of explicitly displaying the path.
+      This is in line with most installers. The reason for not fixing the 
+      displayed path instead is that it is difficult to pass the correct
+      path from CPack to the NSIS installer for display.
+
+      Note that this was never a code issue - it was just a display
+      problem. The installer always did the right thing when updating the
+      environment variable.
+
+      (DER - 2014/11/14, HDFFV-9016)
 
    Library
    ========= 
-   - SDsetblocksize and VSsetblocksize would not change the block size if
-     the sds/vdata did not use linked-block before it was closed.  The
-     problem is now fixed.  (BMR 2013/1/15 - HDFFR-1357)
+    - Warning "array subscript is below array bounds"
 
-   - Patches from user are applied to the C test to correct an overflow variable
-     and to the Fortran source for some missing declarations.
-     (BMR/EP 2014/1/15 - HDFFR-1367)
+      Applied user's patch to remove the warning.
 
-   - Examples GR_write_chunks.c and GR_read_chunks.c were added. 
-     (BMR 2014/12/30 - HDFFR-1402)
+      (BMR 2014/06/02, HDFFR-1379)
 
 
    Utilities
    ========= 
-   - ncdump displayed garbage in place of fill-values when a variable had
-     unlimited dimension and had been written with less number of records
-     than the largest number of records in the file.  This is now fixed.
-     (BMR 2014/12/16 - HDFFR-1390)
+    - Detection of read failure in ncdump
+
+      Previously, ncdump did not detect failure from ncvarget because the
+      returned value from ncvarget was not checked, and the calling function
+      simply returned 0.
+
+      The error code ERR_READFAIL (-2) is added to ncdump only to indicate this
+      failure within ncdump, which will display this message:
+
+      "Reading failed for variable <Variable name>, the data is possibly corrupted."
+
+      (BMR 2015/01/21, HDFFR-1468)
+
+    - Improvement of the ncgen's usage statement.
+
+      Previously, ncgen's usage looked like this:
+      ncgen: -: Usage: ncgen [-V] [ -b ] [ -c ] [ -f ] [ -o outfile]  [ file... ]
+
+      More details are added to the usage to improve clarity.  Now, it is more
+      clear, and consistent with ncdump, like this:
+      Usage: ncgen [-V] [ -b ] [ -c ] [ -f ] [ -o outfile] [ file ... ]
+        [-V]             Display version of the HDF4 library and exit
+        [-b]             For binary netCDF output, '.nc' extension
+        [-c]             For C output
+        [-f]             For Fortran output
+        [-o <outfile>]   Explicitly specify output file name
+
+      (BMR 2015/01/19, HDFFR-1459)
+
+    - Output of hrepack containing an unnecessary vgroup of class RIG0.0
+
+      When the input file did not have any GR elements, hrepack still opened and
+      closed the output file using the GR API, which caused the RIG0.0 vgroup to
+      be written to the output file.
+
+      Hrepack now skips accessing the output file using GR API, when the input
+      file doesn't have any images and any GR attributes.
+
+      (BMR 2015/01/18, HDFFR-1428)
+
+    - Compliance with Fedora standard regarding printf/fprintf statements
+
+      Users sent patches for the problem where the format string is missing from
+      the printf/fprintf statements.  This is in compliance with Fedora standard.
+      For more information, see
+		https://fedoraproject.org/wiki/Format-Security-FAQ.
+
+      In the context where this problem occurred, the benefit of using puts/fputs
+      over printf/fprintf is insignificant.  Thus, the fix was adding "%s" to
+      those printf/fprintf statements that don't have the format string instead
+      of switching to puts/fputs.
+
+      (BMR 2014/12/16, HDFFR-1423 and HDFFR-1475)
+
+    - Failure of hdp on some hdfeos generated files
+
+      Attribute vdatas created by hdfeos API have the field named "AttrValues".
+      The utility functions Vattrhdfsize and VSattrhdfsize, in hdp.c, used
+      ATTR_FIELD_NAME ("VALUES") to verify that a vdata is storing an attribute,
+      causing failure on some hdfeos generated files.  In addition, when this
+      failure occurred, the calling function tried to free allocated resources
+      prematurely.
+
+      The check against ATTR_FIELD_NAME and the premature resource deallocation
+      are removed.
+
+      (BMR 2014/12/08, HDFFR-1471)
+
+    - nclong versus long in tests
+
+      Applied the user's patch to remove a test failure.
+
+      (BMR 2014/10/21, HDFFR-1378)
 
 
 Documentation
 =============
-   - None
+    - Updated Reference Manual and User's Guide
+
+      The documents were updated to contain information of the changes to
+      the tools.  In addition, various improvements were applied.
+
+      (BMR 2015/2/04)
+
 
 
 Platforms tested
@@ -127,99 +172,104 @@ Platforms tested
 
 This version has been tested in the following platforms:
 
-   Linux 2.6.32-358.18.1         gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-3)
-   .el6.ppc64 #1                 GNU Fortran (GCC) 4.4.7 20120313 (Red Hat 4.4.7-3)
-   SMP ppc64 GNU/Linux           IBM XL Fortran for Linux, V13.1 (64-bit mode)
+   Linux 2.6.32-358.18.1         gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-11)
+   .el6.ppc64 #1                 GNU Fortran (GCC) 4.4.7 20120313 (Red Hat 4.4.7-11)
+      SMP ppc64 GNU/Linux        IBM XL Fortran for Linux, V15.1 (64-bit mode)
    (ostrich)
 
-   Linux 2.6.18-308.13.1.el5 #1  gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-52)
+   Linux 2.6.18-308.13.1.el5 #1  gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-55)
       SMP i686 i386              GNU Fortran (GCC) 4.1.2 20080704
-   (jam)                             (Red Hat 4.1.2-52)
-                                 pgcc and pgf90 13.7-0 32-bit target 
+   (jam)                             (Red Hat 4.1.2-55)
+                                 pgcc and pgf90 14.10-0 32-bit target 
                                  on x86 Linux -tp penryn
-                                 Intel(R) C Compiler, Version 13.1.3 20130607
-                                 Intel(R) Fortran Compiler, Version 13.1.3
+                                 Intel(R) C Compiler, Version 15.0.1 20141022
+                                 Intel(R) Fortran Compiler, Version 15.0.1
 
-   Linux 2.6.18-308.24.1.el5 #1  gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-54)
+   Linux 2.6.18-398.el5 #1       gcc (GCC) 4.1.2 20080704 (Red Hat 4.1.2-55)
       SMP x86_64 GNU/Linux       GNU Fortran (GCC) 4.1.2 20080704 
-   (koala)                           (Red Hat 4.1.2-54)
-                                 icc (ICC) 13.1.3 20130607
-                                 ifort (IFORT) 13.1.3 20130607
-                                 pgcc and pgf90 13.7-0 64-bit target 
-                                 on x86-64 Linux -tp nehalem
+   (koala)                           (Red Hat 4.1.2-55)
+                                 icc (ICC) 15.0.1 20141022
+                                 ifort (IFORT) 15.0.1 20141022
 
-   Linux 2.6.32-431.el6.x86_64   gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-4)
+   Linux 2.6.32-504.1.3.el6      gcc (GCC) 4.4.7 20120313 (Red Hat 4.4.7-11)
       #1 SMP x86_64 GNU/Linux    GNU Fortran (GCC) 4.4.7 20120313 
-   (platypus)                        (Red Hat 4.4.7-4)
-                                 icc (ICC) 13.1.3 20130607
-                                 ifort (IFORT) 13.1.3 20130607
-   
+   (platypus)                        (Red Hat 4.4.7-11)
+                                 icc (ICC) 15.0.1 20141022
+                                 ifort (IFORT) 15.0.1 20141022
+                                 pgcc and pgf90 14.10-0 64-bit target 
+                                 on x86-64 Linux -tp nehalem
+
+   Linux 3.10.0-123.8.1.el7      gcc (GCC) 4.8.2 20140120 (Red Hat 4.8.2-16)
+      #1 SMP x86_64 GNU/Linux    GNU Fortran (GCC) 4.8.2 20140120 
+   (aws ec2 CentOS 7 image)          (Red Hat 4.8.2-16)
+
    SunOS 5.11 32- and 64-bit     Sun C 5.12 SunOS_sparc 2011/11/16 
    (emu)                              (see "Known problem" section)
                                  Sun Fortran 95 8.6 SunOS_sparc 2011/11/16
 
-   Windows 7                     Visual Studio 2008 w/ Intel Fortran 11.1 (cmake)
-                                 Visual Studio 2010 w/ Intel Fortran 12 (cmake)
-                                 Visual Studio 2012 w/ Intel Fortran 13 (cmake)
-                                 Cygwin(CYGWIN_NT-6.1 1.7.25(0.270/5/3) gcc(4.7.3) compiler and gfortran)
-                                 (cmake and autotools)
-
-   Windows 7 x64                 Visual Studio 2008 w/ Intel Fortran 11.1 (cmake)
-                                 Visual Studio 2010 w/ Intel Fortran 12 (cmake)
-                                 Visual Studio 2012 w/ Intel Fortran 13 (cmake)
+    Windows 7                     Visual Studio 2008  (cmake)
+                                  Visual Studio 2010 w/ Intel Fortran 14 (cmake)
+                                  Visual Studio 2012 w/ Intel Fortran 14 (cmake)
+                                  Visual Studio 2013 w/ Intel Fortran 14 (cmake)
+                                  Cygwin(CYGWIN_NT-6.1 1.7.32(0.274/5/3) gcc(4.8.3) compiler and gfortran)
+                                  (cmake and autotools)
 
-   Windows 8                     Visual Studio 2012 w/ Intel Fortran 13 (cmake)
+    Windows 7 x64                 Visual Studio 2008  (cmake)
+                                  Visual Studio 2010 w/ Intel Fortran 14 (cmake)
+                                  Visual Studio 2012 w/ Intel Fortran 14 (cmake)
+                                  Visual Studio 2013 w/ Intel Fortran 14 (cmake)
+                                  
+    Windows 8.1                   Visual Studio 2012 w/ Intel Fortran 14 (cmake)
+                                  Visual Studio 2013 w/ Intel Fortran 14 (cmake)
 
-   Windows 8 x64                 Visual Studio 2012 w/ Intel Fortran 13 (cmake)
+    Windows 8.1 x64               Visual Studio 2012 w/ Intel Fortran 14 (cmake)
+                                  Visual Studio 2013 w/ Intel Fortran 14 (cmake)
 
-   Mac OS X Intel 10.6.8         Apple clang version 1.7 from Xcode 3.2.6
-   Darwin 10.8.0                 gfortran GNU Fortran (GCC) 4.6.2
-   (fred)                        icc and ifort Version 12.1.6 20120928
-                             
    Mac OS X 10.7.5		 Apple clang version 3.0 from Xcode 4.6.1
-   Darwin 11.4.2                 gfortran GNU Fortran (GCC) 4.6.2
+   Darwin 11.4.2                 gfortran GNU Fortran (GCC) 4.8.2
    (duck)                        icc and ifort Version 13.0.3 20130606
 
-   Mac OS X 10.8.5               Apple clang version 4.2 from Xcode 4.6.1
-   Darwin 12.2.0                 gfortran GNU Fortran (GCC) 4.6.2
-   (wren)                        icc and ifort Version 13.0.3 20130606
+   Mac OS X 10.8.5               Apple clang version 5.1 from Xcode 5.1
+   Darwin 12.5.0                 gfortran GNU Fortran (GCC) 4.8.2
+   (swallow,kite)                icc and ifort Version 14.0.4 20140805
 
-   Mac OS X 10.8.5               Apple clang version 5.0 from Xcode 5.0.2
-   Darwin 12.2.0                 gfortran GNU Fortran (GCC) 4.6.2
-   (swallow,kite)                icc and ifort Version 14.0.1 20131010
+   Mac OS X 10.9.5               Apple clang version 6.0 from Xcode 6.0.1
+   Darwin 13.4.0                 gfortran GNU Fortran (GCC) 4.8.2 
+   (wren,quail)                  icc and ifort Version 15.0.1 20141022
 
-   Mac OS X 10.9.1               Apple LLVM version 5.0 (clang-500.2.79)
-   Darwin 13.0.0                 (based on LLVM 3.3svn)
-                                 gfortran GNU Fortran (GCC) 4.6.2 
-         
+    Debian7.5.0 3.2.0-4-amd64 #1 SMP Debian 3.2.51-1 x86_64 GNU/Linux
+                                  gcc (Debian 4.7.2-5) 4.7.2
+                                  GNU Fortran (Debian 4.7.2-5) 4.7.2
+                                  (cmake and autotools)
 
-   Debian7.2.0 3.2.0-4-amd64 #1 SMP Debian 3.2.51-1 x86_64 GNU/Linux
-                                 gcc (Debian 4.7.2-5) 4.7.2
-                                 GNU Fortran (Debian 4.7.2-5) 4.7.2
-                                 (cmake and autotools)
+    Fedora20 3.15.3-200.fc20.x86_64 #1 SMP x86_64 x86_64 x86_64 GNU/Linux
+                                  gcc (GCC) 4.8.3 20140624 (Red Hat 4.8.3-1)
+                                  GNU Fortran (GCC) 4.8.3 20140624 (Red Hat 4.8.3-1)
+                                  (cmake and autotools)
 
-   Fedora20 3.11.10-301.fc20.x86_64 #1 SMP x86_64 x86_64 x86_64 GNU/Linux
-                                 gcc (GCC) 4.8.2 20131212 (Red Hat 4.8.2-7)
-                                 GNU Fortran (GCC) 4.8.2 20130603 (Red Hat 4.8.2-7)
-                                 (cmake and autotools)
+    SUSE 13.1 3.11.10-17-desktop #1 SMP PREEMPT x86_64 x86_64 x86_64 GNU/Linux
+                                  gcc (SUSE Linux) 4.8.1
+                                  GNU Fortran (SUSE Linux) 4.8.1
+                                  (cmake and autotools)
 
-   SUSE 13.1 3.11.6-4-desktop #1 SMP PREEMPT x86_64 x86_64 x86_64 GNU/Linux
-                                 gcc (SUSE Linux) 4.8.1
-                                 GNU Fortran (SUSE Linux) 4.8.1
-                                 (cmake and autotools)
-
-   Ubuntu 13.10 3.11.0-13-generic #20-Ubuntu SMP x86_64 GNU/Linux
-                                 gcc (Ubuntu/Linaro 4.8.1-10ubuntu8) 4.8.1
-                                 GNU Fortran (Ubuntu/Linaro 4.8.1-10ubuntu8) 4.8.1
-                                 (cmake and autotools)
+    Ubuntu 14.04 3.13.0-35-generic #62-Ubuntu SMP x86_64 GNU/Linux
+                                  gcc (Ubuntu/Linaro 4.9.1-0ubuntu1) 4.9.1
+                                  GNU Fortran (Ubuntu/Linaro 4.9.1-0ubuntu1) 4.9.1
+                                  (cmake and autotools)
 
 
 Known problems
 ==============
+o  Several Fortran examples print "^@" when displaying strings (for example,
+   names of the attributes). This happens because Fortran application 
+   doesn't know the length of the strings passed from the C library.  
+   EIP - 2015-01-11, HDFFR-1477
+
 o  CMake builds in Windows uses the same pre-generated ncgen*.[ch] files from
    the yacc/lex input files. The generated file, ncgenyy.c, uses the <unistd.h>
    header file that Windows does not support.  This must be blocked out in
-   order for Windows to use it. (AKC 2014-02-03 HDFFR-1424).
+   order for Windows to use it. 
+   AKC 2014-02-03, HDFFR-1424
 
 o  CMake "make install" fails installing the tools:
     Use CPack to create an install package.
@@ -231,8 +281,8 @@ o  CMake does not install these man pages:
 
 o  For Mac OS X 10.7 Lion and on 10.8 Mountain Lion, several tests fail with
    GCC, Intel and Clang compilers.  Currently, this situation is detected and
-   -O0 level optimization is used.  We will work on the issue for the next
-   release. (HDFFR-1318,1358) EIP - 2013/02/05
+   -O0 level optimization is used.  
+   (HDFFR-1318,1358) EIP - 2013/02/05
 
 o  On IBM PowerPC 64, hdftest fails when gcc 4.4.6 is used with -O3 optimization 
    level. 
diff --git a/release_notes/USING_CMake_Examples.txt b/release_notes/USING_CMake_Examples.txt
index 1d9afc8..2167c1f 100644
--- a/release_notes/USING_CMake_Examples.txt
+++ b/release_notes/USING_CMake_Examples.txt
@@ -2,41 +2,38 @@
 * Build and Test HDF4 Examples with CMake                              *
 ************************************************************************
 
-This short set of instructions is for users who want to quickly 
-test the installation of HDF4 by using the CMake tools to build
-and test the HDF4 examples. These instructions will show
-the default usage and then present common changes for non-default
-installations.
-
-For more information, see the USING_HDF4_CMake.txt file.
-
-More information about using CMake can be found at the KitWare 
-site at www.cmake.org.
-
-CMake uses the command line, and these instructions use the script
-method of the ctest command.
-
+Notes: This short instruction is written for users who want to quickly 
+       test the installation of HDF4 by using the CMake tools to build
+       and test the HDF4 Examples. The following instructions will show
+       the default usage and then present common changes for non-default
+       installations.
+       For more information, see the USING_HDF4_CMake.txt file.
+       
+       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                                                           
 ========================================================================
 
-   1. We suggest you obtain the latest CMake for Windows from the Kitware
+   1. We suggest you obtain the latest CMake for windows from the Kitware
       web site. The HDF 4.2.x product requires a minimum CMake version 
-      of 2.8.10.
+      of 2.8.12.
                                                                          
-   2. You have installed the HDF4 Library built with CMake by executing 
+   2. You have installed the HDF4 library built with CMake by executing 
       the HDF Install Utility (the *.exe file in the binary package for 
-      Windows or the *.sh file on Linux). If you are using a Windows platform, 
+      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 the "Common Changes to the 
-      HDF4_Examples.cmake File" section below for the line to change the 
-      location.
+      at www.hdfgroup.org. See Section "III. Common changes to the 
+      HDF4_Examples.cmake file", for the line to change the location.
                                                                          
-   3. On Windows, you have installed the 7Zip package. See the "Common 
-      Changes to the HDF4_Examples.cmake File" section below for the line 
-      to change the command.
+   3. On Windows, you have installed the 7Zip package. See Section "III. 
+      Common changes to the HDF4_Examples.cmake file", for the line to 
+      change the command.
 
 
 
@@ -44,53 +41,41 @@ I. Preconditions
 II. Building HDF4 Examples with CMake
 ========================================================================
 
-Confirm that these files are in the HDF4 install directory:
-
+Files in the HDF4 install directory:
        HDF4Examples-0.1.1-Source.zip (or HDF4Examples-0.1.1-Source.tar.gz)
        HDF4_Examples.cmake
        
-Run the default installation process:
-
+Default installation process:
        Create a directory to run the examples, i.e. \test_hdf4.
-       
-       Copy HDF4Examples-0.1.1-Source.zip(.tar.gz) to this directory, do NOT 
-       unzip.
-       
+       Copy HDF4Examples-0.1.1-Source.zip(.tar.gz) to this directory, do NOT unzip.
        Copy HDF4_Examples.cmake to this directory.
-       
-       Edit line 8 of the HDF4_Examples.cmake file, and change the INSTALLDIR 
-       to the HDF4 install location.
+       Edit line 8 of the HDF4_Examples.cmake file and change the INSTALLDIR 
+           to the HDF4 install location.
        
        Execute from this directory:
-       
           ctest -S HDF4_Examples.cmake,HDF4Examples-0.1.1-Source -C Release -O test.log
 
-       The script will uncompress the examples file 
-       HDF4Examples-0.1.1-Source.zip (.tar.gz), and create a build directory 
-       inside the HDF4Examples-0.1.1-Source directory. It will then configure, 
-       build, and execute the examples. All of 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.
-
+The script will uncompress the examples file HDF4Examples-0.1.1-Source.zip(.tar.gz),
+   and create a build directory inside the HDF4Examples-0.1.1-Source directory.
+   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.
 
 
 ========================================================================
-III. Common Changes to the HDF4_Examples.cmake File
+III. Common changes to the HDF4_Examples.cmake file
 ========================================================================
 
 Line 8: change the INSTALLDIR to a different HDF4 install location.
 
 Line 14: uncomment to allow Mac machines to build shared examples.
 
-Line 15: comment to build and test Fortran examples.
-
-Line 16: uncomment to build and test Fortran examples with the F2003 
-option.
-
-Line 68: change the CTEST_7Z_COMMAND to a different unzip program.
+Line 15: uncomment to build and test Fortran examples.
 
+Line 16: comment to use an existing source directory.
 
+Line 70: change the CTEST_7Z_COMMAND to a different unzip program.
 
diff --git a/release_notes/USING_HDF4_CMake.txt b/release_notes/USING_HDF4_CMake.txt
index dfa200a..082eac5 100644
--- a/release_notes/USING_HDF4_CMake.txt
+++ b/release_notes/USING_HDF4_CMake.txt
@@ -2,31 +2,32 @@
 * Build and Install HDF4 Applications with CMake                       *
 ************************************************************************
 
-This short set of instructions is for users who want to quickly build HDF4 
-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.
+Notes: This short instruction is written for users who want to quickly 
+       build HDF4 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 site at 
-www.cmake.org.
+       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 available 
-for the configuration step. The steps are similar for all of the operating 
-systems supported by CMake.
+       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 HDF4 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.
+       NOTES:
+         1. Using CMake for building and using HDF4 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 HDF4 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. 
+         2. CMake for HDF4 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 CMake.txt for more information.
+         3. See the appendix at the bottom of this file for an example 
+            of using a ctest script for building and testing. See 
+            CMake.txt for more information.
 
 
 
@@ -34,11 +35,11 @@ Notes:
 I. Preconditions                                                           
 ========================================================================
 
-   1. We suggest you obtain the latest CMake for Windows from the Kitware
+   1. We suggest you obtain the latest CMake for windows from the Kitware
       web site. The HDF 4.2.x product requires a minimum CMake version 
-      of 2.8.10.
+      of 2.8.12.
                                                                          
-   2. You have installed the HDF4 Library built with CMake by executing 
+   2. You have installed the HDF4 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 
@@ -46,14 +47,13 @@ I. Preconditions
 
    3. Set the environment variable HDF4_DIR to the installed location of 
       the config files for HDF4. On Windows: 
-      
             HDF4_DIR=C:/Program Files/HDF_Group/HDF/4.2.x/cmake/hdf4
       
       (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).
+   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 
       below.
@@ -68,28 +68,19 @@ Go through these steps to build HDF4 applications with CMake.
 
    1. Run CMake
    2. Configure the cache settings
-   3. Build HDF4 applications
-   4. Test HDF4 applications
+   3. Build HDF4 Applications
+   4. Test HDF4 Applications.
 
 These steps are described in more detail below.
 
-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. 
-
-
 
 
    1. Run CMake
 
-      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. 
+      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 
@@ -104,22 +95,15 @@ installation and needs.
         cmake -G "<generator>"  [-D<options>]  <sourcepath>
         
         Where <generator> is    
-            * Borland Makefiles
-            * MSYS Makefiles
             * MinGW Makefiles
             * NMake Makefiles
             * Unix Makefiles
+            * Visual Studio 12
+            * Visual Studio 12 Win64
             * Visual Studio 11
             * Visual Studio 11 Win64
             * Visual Studio 10
             * Visual Studio 10 Win64
-            * Visual Studio 6
-            * Visual Studio 7
-            * Visual Studio 7 .NET 2003
-            * Visual Studio 8 2005
-            * Visual Studio 8 2005 Win64
-            * Visual Studio 9 2008
-            * Visual Studio 9 2008 Win64
 
         <options> is:
             * BUILD_TESTING:BOOL=ON
@@ -127,35 +111,32 @@ installation and needs.
 
    2. Configure the cache settings
 
-      2.1  Visual CMake users should 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 HDF4 
-           project. After the first configure, you can adjust the cache 
-           settings and/or specify locations of other programs.
+      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 HDF4 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. 
+           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 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.
+           On linux, if you are using the Unix Makefiles generator, the Makefiles will
+           be created in the build folder.
 
-      2.2  A command-line example on Windows can be run from the 
-           c:\MyHDFstuff\hdf4\build directory:
+      2.2  Alternative command line example on Windows in c:\MyHDFstuff\hdf4\build directory:
       
-           cmake -G "Visual Studio 10" -DBUILD_TESTING:BOOL=ON -DUSE_SHARED_LIBS:BOOL=ON ..
+           cmake -G "Visual Studio 11" -DBUILD_TESTING:BOOL=ON -DUSE_SHARED_LIBS:BOOL=ON ..
 
    3. Build HDF4 applications
    
-      On Windows, you can build HDF4 applications using either the Visual 
-      Studio Environment or the command line. The command line is normally 
-      used on Linux, Unix, and Mac.
+      On Windows, you can build HDF4 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:
@@ -170,7 +151,7 @@ installation and needs.
            file in your build directory. Be sure to select either Debug or 
            Release and build the solution.
              
-   4. Test HDF4 applications
+   4. Test HDF4 Applications
 
       To test the build, navigate to your build directory and execute:
       
@@ -180,34 +161,42 @@ installation and needs.
             recommend choosing either Debug or Release to match the build
             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 
+      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. 
+
 
 
 ========================================================================
 III. Minimum C Project Files for CMake
 ========================================================================
 
-Create a CMakeLists.txt file at the source root. Include the following 
-text in the file:
+Create a CMakeLists.txt file at the source root. Include the 
+following text in the file:
 
 ##########################################################
-cmake_minimum_required (VERSION 2.8.10)
+cmake_minimum_required (VERSION 2.8.12)
 PROJECT (HDF4MyApp C CXX)
 
-FIND_PACKAGE (HDF4 NAMES hdf4)
-# FIND_PACKAGE (HDF4) # Find non-cmake built HDF4
+find_package (HDF4 NAMES hdf4)
+# find_package (HDF4) # Find non-cmake built HDF4
 INCLUDE_DIRECTORIES (${HDF4_INCLUDE_DIR})
-SET (LINK_LIBS ${LINK_LIBS} ${HDF4_LIBRARIES})
+set (LINK_LIBS ${LINK_LIBS} ${HDF4_LIBRARIES})
 
-SET (example hdf_example)
+set (example hdf_example)
 
-ADD_EXECUTABLE (${example} ${PROJECT_SOURCE_DIR}/${example}.c)
+add_executable (${example} ${PROJECT_SOURCE_DIR}/${example}.c)
 TARGET_C_PROPERTIES (${example} " " " ")
-TARGET_LINK_LIBRARIES (${example} ${LINK_LIBS})
+target_link_libraries (${example} ${LINK_LIBS})
 
 ENABLE_TESTING ()
-INCLUDE (CTest)
+include (CTest)
 
-ADD_TEST (NAME test_example COMMAND ${example})
+add_test (NAME test_example COMMAND ${example})
 ##########################################################
 
 
@@ -223,10 +212,11 @@ is entered on the command line and the build folder is created as a sub-folder.
 Windows should adjust the forward slash to double backslashes, except for
 the HDF_DIR environment variable.
 
-Note: these files are available at the HDF web site:
+NOTE: these files are available at the HDF web site:
+    http://www.hdfgroup.org/release4/cmakebuild.html
 
-    http://www.hdfgroup.org/HDF4/release/cmakebuild.html
     CTestScript.cmake
+    
     HDF4ExamplesWindowsbinaryCMake.cmake
 
 
@@ -242,7 +232,7 @@ ctest
 # where hdf4Examples is the source folder relative to the location of these scripts
 ############################################################################
 
-cmake_minimum_required(VERSION 2.8.10 FATAL_ERROR)
+cmake_minimum_required(VERSION 2.8.12 FATAL_ERROR)
 
 set(CTEST_DASHBOARD_ROOT ${CTEST_SCRIPT_DIRECTORY})
 set(CTEST_SOURCE_NAME ${CTEST_SCRIPT_ARG})
@@ -255,7 +245,7 @@ set(MODEL "Experimental")
 # build generator name, see cmake generator list
 set(CTEST_CMAKE_GENERATOR "Unix Makefiles")
 
-# machine description, can be removed on Linux
+# machine description, can be removed on linux
 set(CTEST_SITE "machine.domain")
 set(SITE_OS_NAME "os name")
 set(SITE_OS_VERSION "os version")
@@ -266,7 +256,7 @@ set(SITE_COMPILER_VERSION "compiler version")
 # needed for source updates, change as required
 set(REPOSITORY_URL "http://svn.hdfgroup.uiuc.edu/hdf4-examples/trunk")
 
-set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DCMAKE_INSTALL_PREFIX:PATH=/usr/local/hdfExamples-4.2.x")
+set(ADD_BUILD_OPTIONS "${ADD_BUILD_OPTIONS} -DCMAKE_INSTALL_PREFIX:PATH=/usr/local/hdf4Examples-4.2")
 
 # location of the installed hdf4 (cmake configuration folder)
 set(ENV{HDF4_DIR} "/usr/share/cmake/hdf4")
diff --git a/release_notes/USING_HDF4_VS.txt b/release_notes/USING_HDF4_VS.txt
index 0628a84..829648a 100644
--- a/release_notes/USING_HDF4_VS.txt
+++ b/release_notes/USING_HDF4_VS.txt
@@ -13,14 +13,14 @@ The following two sections are helpful if you do not use CMake to build
 your applications.
                                                                         
 ==========================================================================
-Using Visual Studio 2010 with HDF4 Libraries Built with Visual Studio 2010
+Using Visual Studio 2010 with HDF4 Libraries built with Visual Studio 2010
 ==========================================================================
 
-   1. Set up the path to the external libraries and headers.
+   1. Set up path for external libraries and headers
 
-      The path settings will need to be in the project property sheets per 
-      project. Go to "Project" and select "Properties", find "Configuration 
-      Properties", and then "VC++ Directories".
+      The path settings will need to be in project property sheets per project. 
+      Go to "Project" and select "Properties", find "Configuration Properties", 
+      and then "VC++ Directories".
           
       1.1 If you are building on 64-bit Windows, find the "Platform" dropdown
           and select "x64".
@@ -38,10 +38,10 @@ Using Visual Studio 2010 with HDF4 Libraries Built with Visual Studio 2010
 
                                                                          
 ==========================================================================
-Using Visual Studio 2008 with HDF4 Libraries Built with Visual Studio 2008
+Using Visual Studio 2008 with HDF4 Libraries built with Visual Studio 2008
 ==========================================================================
 
-   2. Set up the path to the external libraries and headers
+   2. Set up path for external libraries and headers
 
       Invoke Microsoft Visual Studio and go to "Tools" and select "Options", 
       find "Projects", and then "VC++ Directories".
@@ -50,15 +50,15 @@ Using Visual Studio 2008 with HDF4 Libraries Built with Visual Studio 2008
           and select "x64".
 
       2.2 Find the box "Show directories for", choose "Include files", add the 
-          header path (i.e., c:\Program Files\HDF_Group\HDF4\1.8.x\include)
+          header path (i.e. c:\Program Files\HDF_Group\HDF4\1.8.x\include)
           to the included directories.
 
       2.3 Find the box "Show directories for", choose "Library files", add the
-          library path (i.e., c:\Program Files\HDF_Group\HDF4\1.8.x\lib)
+          library path (i.e. c:\Program Files\HDF_Group\HDF4\1.8.x\lib)
           to the library directories.
           
-      2.4 For Fortran libraries, you will also need to setup the path for 
-          the Intel Fortran compiler.
+      2.4 If using Fortran libraries, you will also need to setup the path
+          for the Intel Fortran compiler.
           
       2.5 Select Project->Properties->Linker->Input and beginning with the
           "Additional Dependencies" line, enter the library names. The
@@ -75,11 +75,11 @@ Using Visual Studio 2008 with HDF4 Libraries Built with Visual Studio 2008
     
     Many other common questions and hints are located online and being updated
     in the HDF4 FAQ.  For Windows-specific questions, please see:
-    
-        http://www.hdfgroup.org/HDF4/windows/faq.html
-        
+
+	http://www.hdfgroup.org/windows/faq.html
+
     For all other general questions, you can look in the general FAQ:
-    
+
         http://hdfgroup.org/HDF4-FAQ.html
     
 ************************************************************************

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-grass/hdf4.git



More information about the Pkg-grass-devel mailing list