************************************************************************
* Build and Test HDF-JAVA Examples with CMake                          *
************************************************************************

This short set of instructions is for users who want to quickly test 
the installation of HDFView with hdf-java by using the CMake tools to 
build and test the HDF-JAVA examples. These instructions will show
the default usage and then present common changes for non-default
installations.

For more information, see the USING_HDFJAVA_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.



========================================================================
I. Preconditions                                                           
========================================================================

   1. We suggest you obtain the latest CMake for Windows from the Kitware
      web site. The HDF-JAVA 2.10.1 product requires a minimum CMake version 
      of 2.8.10.
                                                                         
   2. You have installed the HDF-JAVA 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, 
      you can obtain a pre-built Windows binary from The HDF Group's website 
      at www.hdfgroup.org. See the "Common Changes to the 
      HDF-JAVA_Examples.cmake File" section below for the line to change the 
      location.
                                                                         
   3. On Windows, you have installed the 7Zip package. See the "Common 
      Changes to the HDF-JAVA_Examples.cmake File" section below for the line 
      to change the command.



========================================================================
II. Building HDF-JAVA Examples with CMake
========================================================================

Confirm that these files are in the HDFview with hdf-java install location's 
share sub-directory:

       HDFJavaExamples-0.1.1-Source.zip (or HDFJavaExamples-0.1.1-Source.tar.gz)
       HDFJAVA_Examples.cmake
   Note:
       Windows default is C:/Program Files/HDF_Group/HDFView/2.10.1
       Mac OS X default is /Applications/HDFView.app/Contents/SharedSupport
       Linux default <install root>/HDF_Group/HDFView/2.10.1/share
       
Run the default installation process:

       Create a directory to run the examples, i.e. \test_hdfjava.
       
       Copy HDFJavaExamples-0.1.1-Source.zip(.tar.gz) to this directory, do NOT 
       unzip.
       
       Copy HDFJAVA_Examples.cmake to this directory.
       
       Edit line 8 of the HDFJAVA_Examples.cmake file, and change the INSTALLDIR 
       to the HDF-JAVA install location.
       
       Execute from this directory:
       
          ctest -S HDFJAVA_Examples.cmake,HDFJavaExamples-0.1.1-Source -C Release -O test.log

       The script will uncompress the examples file 
       HDFJavaExamples-0.1.1-Source.zip (.tar.gz), and create a build directory 
       inside the HDFJavaExamples-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.



========================================================================
III. Common Changes to the HDFJAVA_Examples.cmake File
========================================================================

Line 8: change the INSTALLDIR to a different HDF-JAVA install location.

Line 13: comment to use an existing source directory.

Line 43: change the CTEST_7Z_COMMAND to a different unzip program on Windows.



