From 96c13847a638a0a028afb2f1b31a513bf70110e4 Mon Sep 17 00:00:00 2001 From: Larry Knox Date: Fri, 14 May 2010 17:05:48 -0500 Subject: [svn-r18817] Added scripts to compile and run installed examples. The scripts are installed with the examples, and there is one script to run the scripts for all hl examples and another to run the scripts for all the examples. Tested: amani, jam, linew (h5committest). --- MANIFEST | 8 +++ Makefile.am | 2 +- Makefile.in | 2 +- c++/examples/Makefile.am | 3 +- c++/examples/Makefile.in | 32 +++++++-- c++/examples/run-c++-ex.sh.in | 85 +++++++++++++++++++++++ config/examples.am | 24 ++++++- configure | 8 ++- configure.in | 8 ++- examples/Makefile.am | 5 ++ examples/Makefile.in | 32 +++++++-- examples/run-all-ex.sh | 40 +++++++++++ examples/run-c-ex.sh.in | 108 +++++++++++++++++++++++++++++ fortran/examples/Makefile.am | 1 + fortran/examples/Makefile.in | 30 ++++++-- fortran/examples/run-fortran-ex.sh.in | 98 ++++++++++++++++++++++++++ hl/Makefile.am | 4 +- hl/Makefile.in | 4 +- hl/c++/examples/Makefile.am | 3 +- hl/c++/examples/Makefile.in | 31 +++++++-- hl/c++/examples/run-hlc++-ex.sh.in | 80 +++++++++++++++++++++ hl/examples/Makefile.am | 11 ++- hl/examples/Makefile.in | 39 +++++++++-- hl/examples/run-hl-ex.sh | 36 ++++++++++ hl/examples/run-hlc-ex.sh.in | 102 +++++++++++++++++++++++++++ hl/fortran/examples/Makefile.am | 5 +- hl/fortran/examples/Makefile.in | 32 +++++++-- hl/fortran/examples/run-hlfortran-ex.sh.in | 84 ++++++++++++++++++++++ 28 files changed, 876 insertions(+), 41 deletions(-) create mode 100755 c++/examples/run-c++-ex.sh.in create mode 100755 examples/run-all-ex.sh create mode 100755 examples/run-c-ex.sh.in create mode 100755 fortran/examples/run-fortran-ex.sh.in create mode 100755 hl/c++/examples/run-hlc++-ex.sh.in create mode 100755 hl/examples/run-hl-ex.sh create mode 100755 hl/examples/run-hlc-ex.sh.in create mode 100755 hl/fortran/examples/run-hlfortran-ex.sh.in diff --git a/MANIFEST b/MANIFEST index c31ee8c..ebe94b9 100644 --- a/MANIFEST +++ b/MANIFEST @@ -159,6 +159,7 @@ ./fortran/examples/ph5example.f90 ./fortran/examples/refobjexample.f90 ./fortran/examples/refregexample.f90 +./fortran/examples/run-fortran-ex.sh.in ./fortran/examples/rwdsetexample.f90 ./fortran/examples/selectele.f90 ./fortran/examples/testh5fc.sh.in @@ -271,6 +272,7 @@ ./c++/examples/writedata.cpp ./c++/examples/Makefile.am ./c++/examples/Makefile.in +./c++/examples/run-c++-ex.sh.in ./c++/src/H5AbstractDs.cpp ./c++/src/H5AbstractDs.h @@ -1659,6 +1661,8 @@ ./hl/examples/pal_rgb.h ./hl/examples/ptExampleFL.c ./hl/examples/ptExampleVL.c +./hl/examples/run-hl-ex.sh +./hl/examples/run-hlc-ex.sh.in ./hl/src/COPYING ./hl/src/Makefile.am ./hl/src/Makefile.in @@ -1739,6 +1743,7 @@ ./hl/fortran/examples/Makefile.am ./hl/fortran/examples/Makefile.in ./hl/fortran/examples/exlite.f90 +./hl/fortran/examples/run-hlfortran-ex.sh.in ./hl/fortran/src/H5IMcc.c ./hl/fortran/src/H5IMcc.h ./hl/fortran/src/H5IMfc.c @@ -1764,6 +1769,7 @@ ./hl/c++/examples/Makefile.in ./hl/c++/examples/ptExampleFL.cpp ./hl/c++/examples/ptExampleVL.cpp +./hl/c++/examples/run-hlc++-ex.sh.in ./hl/c++/src/H5PacketTable.h ./hl/c++/src/H5PacketTable.cpp ./hl/c++/src/Makefile.am @@ -1844,6 +1850,8 @@ ./c++/src/CMakeLists.txt ./c++/test/CMakeLists.txt ./examples/CMakeLists.txt +./examples/run-all-ex.sh +./examples/run-c-ex.sh.in ./fortran/CMakeLists.txt ./fortran/examples/CMakeLists.txt ./fortran/src/CMakeLists.txt diff --git a/Makefile.am b/Makefile.am index 4717810..179fb17 100755 --- a/Makefile.am +++ b/Makefile.am @@ -138,7 +138,7 @@ uninstall-all: # Install examples in this directory and recursively install-examples uninstall-examples: - @@SETX@; for d in examples $(HDF5_INTERFACES); do \ + @@SETX@; for d in examples $(HDF5_INTERFACES) $(HL); do \ (cd $$d && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1; \ done diff --git a/Makefile.in b/Makefile.in index 9de00d4..db0c92f 100644 --- a/Makefile.in +++ b/Makefile.in @@ -962,7 +962,7 @@ uninstall-all: # Install examples in this directory and recursively install-examples uninstall-examples: - @@SETX@; for d in examples $(HDF5_INTERFACES); do \ + @@SETX@; for d in examples $(HDF5_INTERFACES) $(HL); do \ (cd $$d && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1; \ done diff --git a/c++/examples/Makefile.am b/c++/examples/Makefile.am index 28af8d5..8a6a1d6 100644 --- a/c++/examples/Makefile.am +++ b/c++/examples/Makefile.am @@ -27,8 +27,9 @@ TEST_PROG=create readdata writedata compound extend_ds chunks h5group TEST_SCRIPT=testh5c++.sh # These are the example files to be installed -INSTALL_FILES=create.cpp readdata.cpp writedata.cpp compound.cpp \ +INSTALL_FILES=create.cpp readdata.cpp writedata.cpp compound.cpp \ extend_ds.cpp chunks.cpp h5group.cpp +INSTALL_SCRIPT_FILES = run-c++-ex.sh # Some of the examples depend on files created by running other examples readdata.chkexe_: create.chkexe_ diff --git a/c++/examples/Makefile.in b/c++/examples/Makefile.in index db470b0..7c1af42 100644 --- a/c++/examples/Makefile.in +++ b/c++/examples/Makefile.in @@ -55,7 +55,8 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ - $(srcdir)/testh5c++.sh.in $(top_srcdir)/config/commence.am \ + $(srcdir)/run-c++-ex.sh.in $(srcdir)/testh5c++.sh.in \ + $(top_srcdir)/config/commence.am \ $(top_srcdir)/config/conclude.am \ $(top_srcdir)/config/examples.am TESTS = @@ -66,7 +67,7 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs CONFIG_HEADER = $(top_builddir)/src/H5config.h -CONFIG_CLEAN_FILES = testh5c++.sh +CONFIG_CLEAN_FILES = run-c++-ex.sh testh5c++.sh CONFIG_CLEAN_VPATH_FILES = SOURCES = DIST_SOURCES = @@ -338,9 +339,10 @@ TEST_PROG = create readdata writedata compound extend_ds chunks h5group TEST_SCRIPT = testh5c++.sh # These are the example files to be installed -INSTALL_FILES = create.cpp readdata.cpp writedata.cpp compound.cpp \ +INSTALL_FILES = create.cpp readdata.cpp writedata.cpp compound.cpp \ extend_ds.cpp chunks.cpp h5group.cpp +INSTALL_SCRIPT_FILES = run-c++-ex.sh # Tell conclude.am that these are C++ tests. CXX_API = yes @@ -405,6 +407,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): +run-c++-ex.sh: $(top_builddir)/config.status $(srcdir)/run-c++-ex.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ testh5c++.sh: $(top_builddir)/config.status $(srcdir)/testh5c++.sh.in cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ @@ -599,6 +603,8 @@ h5group: $(srcdir)/h5group.cpp # How to create EXAMPLEDIR if it doesn't already exist $(EXAMPLEDIR): -$(top_srcdir)/bin/mkdirs $@ +$(EXAMPLETOPDIR): + -$(top_srcdir)/bin/mkdirs $@ # Install and uninstall rules. We install the source files, not the # example programs themselves. @@ -613,10 +619,26 @@ install-examples: $(EXAMPLEDIR) $(INSTALL_FILES) (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLEDIR)/. || exit 1);\ fi; \ done + @for f in X $(INSTALL_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $$f $(EXAMPLEDIR)/. || exit 1);\ + fi; \ + done + @for f in X $(INSTALL_TOP_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLETOPDIR)/. || exit 1); \ + fi; \ + done uninstall-examples: - @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ - set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + fi + @if test -n "$(INSTALL_SCRIPT_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_SCRIPT_FILES); \ + fi + @if test -n "$(INSTALL_TOP_SCRIPT_FILES)" -a -d $(EXAMPLETOPDIR); then \ + set -x; cd $(EXAMPLETOPDIR) && $(RM) $(INSTALL_TOP_SCRIPT_FILES); \ fi installcheck-local: diff --git a/c++/examples/run-c++-ex.sh.in b/c++/examples/run-c++-ex.sh.in new file mode 100755 index 0000000..79a4ccf --- /dev/null +++ b/c++/examples/run-c++-ex.sh.in @@ -0,0 +1,85 @@ +#! /bin/sh +# +# Copyright by The HDF Group. +# All rights reserved. +# +# This file is part of HDF5. The full HDF5 copyright notice, including +# terms governing use, modification, and redistribution, is contained in +# the files COPYING and Copyright.html. COPYING can be found at the root +# of the source code distribution tree; Copyright.html can be found at the +# root level of an installed copy of the electronic HDF5 document set and +# is linked from the top-level documents page. It can also be found at +# http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have +# access to either file, you may request a copy from help@hdfgroup.org. + +# +# This file: run-c++-ex.sh +# Written by: Larry Knox +# Date: May 11, 2010 +# +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # +# # +# This script will compile and run the c++ examples from source files # +# installed in .../share/hdf5_examples/c++ using h5c++. The # +# order for running programs with RunTest in the MAIN section below is taken # +# from the Makefile. The order is important since some of the test programs # +# use data files created by earlier test programs. Any future additions should # +# be placed accordingly. # +# # +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # + +# Initializations +EXIT_SUCCESS=0 +EXIT_FAILURE=1 + +# Where the tool is installed. +prefix="${prefix:-${DESTDIR}/@prefix@}" +AR="@AR@" +RANLIB="@RANLIB@" +H5TOOL="h5c++" # The tool name +H5TOOL_BIN="${prefix}/bin/${H5TOOL}" # The path of the tool binary + +#### Run test #### +RunTest() +{ + Test=$1".cpp" + + echo + echo "################# $1 #################" + ${H5TOOL_BIN} $Test + if [ $? -ne 0 ] + then + echo "messed up compiling $Test" + exit 1 + fi + ./a.out +} + + + +################## MAIN ################## + +# Run tests +if [ $? -eq 0 ] +then + if (RunTest create &&\ + RunTest readdata &&\ + RunTest writedata &&\ + RunTest compound &&\ + RunTest extend_ds &&\ + RunTest chunks &&\ + RunTest h5group); then + EXIT_VALUE=${EXIT_SUCCESS} + else + EXIT_VALUE=${EXIT_FAILURE} + fi +fi + +# Cleanup +rm a.out +rm *.o +rm *.h5 +echo + +exit $EXIT_VALUE + diff --git a/config/examples.am b/config/examples.am index 0d51251..e48141e 100644 --- a/config/examples.am +++ b/config/examples.am @@ -30,6 +30,8 @@ ## ## INSTALL_FILES ## The source files that the examples use which should be installed. +## INSTALL_SCRIPT_FILES +## INSTALL_TOP_SCRIPT_FILES ## ## EXAMPLEDIR ## The directory into which examples should be installed. @@ -52,6 +54,8 @@ CLEANFILES=$(TEST_PROG) $(TEST_PROG_PARA) # How to create EXAMPLEDIR if it doesn't already exist $(EXAMPLEDIR): -$(top_srcdir)/bin/mkdirs $@ +$(EXAMPLETOPDIR): + -$(top_srcdir)/bin/mkdirs $@ # Install and uninstall rules. We install the source files, not the # example programs themselves. @@ -66,10 +70,26 @@ install-examples: $(EXAMPLEDIR) $(INSTALL_FILES) (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLEDIR)/. || exit 1);\ fi; \ done + @for f in X $(INSTALL_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $$f $(EXAMPLEDIR)/. || exit 1);\ + fi; \ + done + @for f in X $(INSTALL_TOP_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLETOPDIR)/. || exit 1); \ + fi; \ + done uninstall-examples: - @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ - set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + fi + @if test -n "$(INSTALL_SCRIPT_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_SCRIPT_FILES); \ + fi + @if test -n "$(INSTALL_TOP_SCRIPT_FILES)" -a -d $(EXAMPLETOPDIR); then \ + set -x; cd $(EXAMPLETOPDIR) && $(RM) $(INSTALL_TOP_SCRIPT_FILES); \ fi installcheck-local: diff --git a/configure b/configure index f4464c4..81853fe 100755 --- a/configure +++ b/configure @@ -28683,7 +28683,7 @@ if test -n "$TESTPARALLEL"; then fi fi -ac_config_files="$ac_config_files src/libhdf5.settings Makefile src/Makefile test/Makefile test/testcheck_version.sh test/testerror.sh test/H5srcdir_str.h test/testlibinfo.sh testpar/Makefile testpar/testph5.sh perform/Makefile tools/Makefile tools/h5dump/Makefile tools/h5dump/testh5dump.sh tools/h5dump/testh5dumpxml.sh tools/h5ls/testh5ls.sh tools/h5import/Makefile tools/h5diff/Makefile tools/h5jam/Makefile tools/h5jam/testh5jam.sh tools/h5repack/Makefile tools/h5repack/h5repack.sh tools/h5ls/Makefile tools/h5copy/Makefile tools/lib/Makefile tools/misc/Makefile tools/misc/h5cc tools/misc/testh5repart.sh tools/h5stat/testh5stat.sh tools/h5stat/Makefile examples/Makefile examples/testh5cc.sh c++/Makefile c++/src/Makefile c++/src/h5c++ c++/test/Makefile c++/test/H5srcdir_str.h c++/examples/Makefile c++/examples/testh5c++.sh fortran/Makefile fortran/src/h5fc fortran/src/Makefile fortran/test/Makefile fortran/testpar/Makefile fortran/examples/Makefile fortran/examples/testh5fc.sh hl/Makefile hl/src/Makefile hl/test/Makefile hl/test/H5srcdir_str.h hl/tools/Makefile hl/tools/gif2h5/Makefile hl/examples/Makefile hl/c++/Makefile hl/c++/src/Makefile hl/c++/test/Makefile hl/c++/examples/Makefile hl/fortran/Makefile hl/fortran/src/Makefile hl/fortran/test/Makefile hl/fortran/examples/Makefile" +ac_config_files="$ac_config_files src/libhdf5.settings Makefile src/Makefile test/Makefile test/testcheck_version.sh test/testerror.sh test/H5srcdir_str.h test/testlibinfo.sh testpar/Makefile testpar/testph5.sh perform/Makefile tools/Makefile tools/h5dump/Makefile tools/h5dump/testh5dump.sh tools/h5dump/testh5dumpxml.sh tools/h5ls/testh5ls.sh tools/h5import/Makefile tools/h5diff/Makefile tools/h5jam/Makefile tools/h5jam/testh5jam.sh tools/h5repack/Makefile tools/h5repack/h5repack.sh tools/h5ls/Makefile tools/h5copy/Makefile tools/lib/Makefile tools/misc/Makefile tools/misc/h5cc tools/misc/testh5repart.sh tools/h5stat/testh5stat.sh tools/h5stat/Makefile examples/Makefile examples/run-c-ex.sh examples/testh5cc.sh c++/Makefile c++/src/Makefile c++/src/h5c++ c++/test/Makefile c++/test/H5srcdir_str.h c++/examples/Makefile c++/examples/run-c++-ex.sh c++/examples/testh5c++.sh fortran/Makefile fortran/src/h5fc fortran/src/Makefile fortran/test/Makefile fortran/testpar/Makefile fortran/examples/Makefile fortran/examples/run-fortran-ex.sh fortran/examples/testh5fc.sh hl/Makefile hl/src/Makefile hl/test/Makefile hl/test/H5srcdir_str.h hl/tools/Makefile hl/tools/gif2h5/Makefile hl/examples/Makefile hl/examples/run-hlc-ex.sh hl/c++/Makefile hl/c++/src/Makefile hl/c++/test/Makefile hl/c++/examples/Makefile hl/c++/examples/run-hlc++-ex.sh hl/fortran/Makefile hl/fortran/src/Makefile hl/fortran/test/Makefile hl/fortran/examples/Makefile hl/fortran/examples/run-hlfortran-ex.sh" cat >confcache <<\_ACEOF @@ -29924,6 +29924,7 @@ do "tools/h5stat/testh5stat.sh") CONFIG_FILES="$CONFIG_FILES tools/h5stat/testh5stat.sh" ;; "tools/h5stat/Makefile") CONFIG_FILES="$CONFIG_FILES tools/h5stat/Makefile" ;; "examples/Makefile") CONFIG_FILES="$CONFIG_FILES examples/Makefile" ;; + "examples/run-c-ex.sh") CONFIG_FILES="$CONFIG_FILES examples/run-c-ex.sh" ;; "examples/testh5cc.sh") CONFIG_FILES="$CONFIG_FILES examples/testh5cc.sh" ;; "c++/Makefile") CONFIG_FILES="$CONFIG_FILES c++/Makefile" ;; "c++/src/Makefile") CONFIG_FILES="$CONFIG_FILES c++/src/Makefile" ;; @@ -29931,6 +29932,7 @@ do "c++/test/Makefile") CONFIG_FILES="$CONFIG_FILES c++/test/Makefile" ;; "c++/test/H5srcdir_str.h") CONFIG_FILES="$CONFIG_FILES c++/test/H5srcdir_str.h" ;; "c++/examples/Makefile") CONFIG_FILES="$CONFIG_FILES c++/examples/Makefile" ;; + "c++/examples/run-c++-ex.sh") CONFIG_FILES="$CONFIG_FILES c++/examples/run-c++-ex.sh" ;; "c++/examples/testh5c++.sh") CONFIG_FILES="$CONFIG_FILES c++/examples/testh5c++.sh" ;; "fortran/Makefile") CONFIG_FILES="$CONFIG_FILES fortran/Makefile" ;; "fortran/src/h5fc") CONFIG_FILES="$CONFIG_FILES fortran/src/h5fc" ;; @@ -29938,6 +29940,7 @@ do "fortran/test/Makefile") CONFIG_FILES="$CONFIG_FILES fortran/test/Makefile" ;; "fortran/testpar/Makefile") CONFIG_FILES="$CONFIG_FILES fortran/testpar/Makefile" ;; "fortran/examples/Makefile") CONFIG_FILES="$CONFIG_FILES fortran/examples/Makefile" ;; + "fortran/examples/run-fortran-ex.sh") CONFIG_FILES="$CONFIG_FILES fortran/examples/run-fortran-ex.sh" ;; "fortran/examples/testh5fc.sh") CONFIG_FILES="$CONFIG_FILES fortran/examples/testh5fc.sh" ;; "hl/Makefile") CONFIG_FILES="$CONFIG_FILES hl/Makefile" ;; "hl/src/Makefile") CONFIG_FILES="$CONFIG_FILES hl/src/Makefile" ;; @@ -29946,14 +29949,17 @@ do "hl/tools/Makefile") CONFIG_FILES="$CONFIG_FILES hl/tools/Makefile" ;; "hl/tools/gif2h5/Makefile") CONFIG_FILES="$CONFIG_FILES hl/tools/gif2h5/Makefile" ;; "hl/examples/Makefile") CONFIG_FILES="$CONFIG_FILES hl/examples/Makefile" ;; + "hl/examples/run-hlc-ex.sh") CONFIG_FILES="$CONFIG_FILES hl/examples/run-hlc-ex.sh" ;; "hl/c++/Makefile") CONFIG_FILES="$CONFIG_FILES hl/c++/Makefile" ;; "hl/c++/src/Makefile") CONFIG_FILES="$CONFIG_FILES hl/c++/src/Makefile" ;; "hl/c++/test/Makefile") CONFIG_FILES="$CONFIG_FILES hl/c++/test/Makefile" ;; "hl/c++/examples/Makefile") CONFIG_FILES="$CONFIG_FILES hl/c++/examples/Makefile" ;; + "hl/c++/examples/run-hlc++-ex.sh") CONFIG_FILES="$CONFIG_FILES hl/c++/examples/run-hlc++-ex.sh" ;; "hl/fortran/Makefile") CONFIG_FILES="$CONFIG_FILES hl/fortran/Makefile" ;; "hl/fortran/src/Makefile") CONFIG_FILES="$CONFIG_FILES hl/fortran/src/Makefile" ;; "hl/fortran/test/Makefile") CONFIG_FILES="$CONFIG_FILES hl/fortran/test/Makefile" ;; "hl/fortran/examples/Makefile") CONFIG_FILES="$CONFIG_FILES hl/fortran/examples/Makefile" ;; + "hl/fortran/examples/run-hlfortran-ex.sh") CONFIG_FILES="$CONFIG_FILES hl/fortran/examples/run-hlfortran-ex.sh" ;; *) as_fn_error "invalid argument: \`$ac_config_target'" "$LINENO" 5;; esac diff --git a/configure.in b/configure.in index 425d64b..b4ca940 100644 --- a/configure.in +++ b/configure.in @@ -4204,6 +4204,7 @@ AC_CONFIG_FILES([src/libhdf5.settings tools/h5stat/testh5stat.sh tools/h5stat/Makefile examples/Makefile + examples/run-c-ex.sh examples/testh5cc.sh c++/Makefile c++/src/Makefile @@ -4211,6 +4212,7 @@ AC_CONFIG_FILES([src/libhdf5.settings c++/test/Makefile c++/test/H5srcdir_str.h c++/examples/Makefile + c++/examples/run-c++-ex.sh c++/examples/testh5c++.sh fortran/Makefile fortran/src/h5fc @@ -4218,6 +4220,7 @@ AC_CONFIG_FILES([src/libhdf5.settings fortran/test/Makefile fortran/testpar/Makefile fortran/examples/Makefile + fortran/examples/run-fortran-ex.sh fortran/examples/testh5fc.sh hl/Makefile hl/src/Makefile @@ -4226,14 +4229,17 @@ AC_CONFIG_FILES([src/libhdf5.settings hl/tools/Makefile hl/tools/gif2h5/Makefile hl/examples/Makefile + hl/examples/run-hlc-ex.sh hl/c++/Makefile hl/c++/src/Makefile hl/c++/test/Makefile hl/c++/examples/Makefile + hl/c++/examples/run-hlc++-ex.sh hl/fortran/Makefile hl/fortran/src/Makefile hl/fortran/test/Makefile - hl/fortran/examples/Makefile]) + hl/fortran/examples/Makefile + hl/fortran/examples/run-hlfortran-ex.sh]) AC_OUTPUT no_create=$saved_no_create diff --git a/examples/Makefile.am b/examples/Makefile.am index 9143baa..92830df 100644 --- a/examples/Makefile.am +++ b/examples/Makefile.am @@ -41,6 +41,10 @@ INSTALL_FILES = h5_write.c h5_read.c h5_extend_write.c h5_chunk_read.c \ h5_reference.c h5_drivers.c h5_extlink.c h5_elink_unix2win.c \ h5_ref2reg.c h5_shared_mesg.c ph5example.c +INSTALL_SCRIPT_FILES = run-c-ex.sh + +INSTALL_TOP_SCRIPT_FILES = run-all-ex.sh + # How to build examples, using installed version of h5cc if BUILD_PARALLEL_CONDITIONAL $(EXTRA_PROG): $(H5CC_PP) @@ -66,6 +70,7 @@ CHECK_CLEANFILES+=$(EXTLINK_DIRS) # Example directory EXAMPLEDIR=${DESTDIR}/$(exec_prefix)/share/hdf5_examples/c +EXAMPLETOPDIR=${DESTDIR}/$(exec_prefix)/share/hdf5_examples # List dependencies for each program. Normally, automake would take # care of this for us, but if we tell automake about the programs it diff --git a/examples/Makefile.in b/examples/Makefile.in index 8e556e9..fee596a 100644 --- a/examples/Makefile.in +++ b/examples/Makefile.in @@ -55,7 +55,8 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ - $(srcdir)/testh5cc.sh.in $(top_srcdir)/config/commence.am \ + $(srcdir)/run-c-ex.sh.in $(srcdir)/testh5cc.sh.in \ + $(top_srcdir)/config/commence.am \ $(top_srcdir)/config/conclude.am \ $(top_srcdir)/config/examples.am TESTS = @@ -66,7 +67,7 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs CONFIG_HEADER = $(top_builddir)/src/H5config.h -CONFIG_CLEAN_FILES = testh5cc.sh +CONFIG_CLEAN_FILES = run-c-ex.sh testh5cc.sh CONFIG_CLEAN_VPATH_FILES = SOURCES = DIST_SOURCES = @@ -350,6 +351,8 @@ INSTALL_FILES = h5_write.c h5_read.c h5_extend_write.c h5_chunk_read.c \ h5_reference.c h5_drivers.c h5_extlink.c h5_elink_unix2win.c \ h5_ref2reg.c h5_shared_mesg.c ph5example.c +INSTALL_SCRIPT_FILES = run-c-ex.sh +INSTALL_TOP_SCRIPT_FILES = run-all-ex.sh # The external link examples demonstrate how to use paths; they need # directories to be created to do this. @@ -357,6 +360,7 @@ EXTLINK_DIRS = red blue u2w # Example directory EXAMPLEDIR = ${DESTDIR}/$(exec_prefix)/share/hdf5_examples/c +EXAMPLETOPDIR = ${DESTDIR}/$(exec_prefix)/share/hdf5_examples # Assume that all tests in this directory are examples, and tell # conclude.am when to build them. @@ -415,6 +419,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): +run-c-ex.sh: $(top_builddir)/config.status $(srcdir)/run-c-ex.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ testh5cc.sh: $(top_builddir)/config.status $(srcdir)/testh5cc.sh.in cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ @@ -629,6 +635,8 @@ h5_shared_mesg: $(srcdir)/h5_shared_mesg.c # How to create EXAMPLEDIR if it doesn't already exist $(EXAMPLEDIR): -$(top_srcdir)/bin/mkdirs $@ +$(EXAMPLETOPDIR): + -$(top_srcdir)/bin/mkdirs $@ # Install and uninstall rules. We install the source files, not the # example programs themselves. @@ -643,10 +651,26 @@ install-examples: $(EXAMPLEDIR) $(INSTALL_FILES) (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLEDIR)/. || exit 1);\ fi; \ done + @for f in X $(INSTALL_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $$f $(EXAMPLEDIR)/. || exit 1);\ + fi; \ + done + @for f in X $(INSTALL_TOP_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLETOPDIR)/. || exit 1); \ + fi; \ + done uninstall-examples: - @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ - set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + fi + @if test -n "$(INSTALL_SCRIPT_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_SCRIPT_FILES); \ + fi + @if test -n "$(INSTALL_TOP_SCRIPT_FILES)" -a -d $(EXAMPLETOPDIR); then \ + set -x; cd $(EXAMPLETOPDIR) && $(RM) $(INSTALL_TOP_SCRIPT_FILES); \ fi installcheck-local: diff --git a/examples/run-all-ex.sh b/examples/run-all-ex.sh new file mode 100755 index 0000000..e96b86f --- /dev/null +++ b/examples/run-all-ex.sh @@ -0,0 +1,40 @@ +#! /bin/sh +# +# Copyright by The HDF Group. +# All rights reserved. +# +# This file is part of HDF5. The full HDF5 copyright notice, including +# terms governing use, modification, and redistribution, is contained in +# the files COPYING and Copyright.html. COPYING can be found at the root +# of the source code distribution tree; Copyright.html can be found at the +# root level of an installed copy of the electronic HDF5 document set and +# is linked from the top-level documents page. It can also be found at +# http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have +# access to either file, you may request a copy from help@hdfgroup.org. + +# +# This file: run-hl-ex.sh +# Written by: Larry Knox +# Date: May 11, 2010 +# +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # +# # +# This script will run the scripts to compile and run the installed hdf5 # +# examples. # +# # +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # + +if (echo "Run c examples" && \ + (cd c; sh ./run-c-ex.sh) && \ + echo "Run fortran examples" && \ + (cd fortran; sh ./run-fortran-ex.sh) && \ + echo "Run c++ examples" && \ + (cd c++; sh ./run-c++-ex.sh) && \ + echo "Run hl examples." && \ + (cd hl; sh ./run-hl-ex.sh)); then + echo "Done" + exit 0 +else + exit 1 +fi + diff --git a/examples/run-c-ex.sh.in b/examples/run-c-ex.sh.in new file mode 100755 index 0000000..09ff2fc --- /dev/null +++ b/examples/run-c-ex.sh.in @@ -0,0 +1,108 @@ +#! /bin/sh +# +# Copyright by The HDF Group. +# All rights reserved. +# +# This file is part of HDF5. The full HDF5 copyright notice, including +# terms governing use, modification, and redistribution, is contained in +# the files COPYING and Copyright.html. COPYING can be found at the root +# of the source code distribution tree; Copyright.html can be found at the +# root level of an installed copy of the electronic HDF5 document set and +# is linked from the top-level documents page. It can also be found at +# http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have +# access to either file, you may request a copy from help@hdfgroup.org. + +# +# This file: run-c-ex.sh +# Written by: Larry Knox +# Date: May 11, 2010 +# +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # +# # +# This script will compile and run the c examples from source files installed # +# in .../share/hdf5_examples/c using h5cc or h5pc. The order for running # +# programs with RunTest in the MAIN section below is taken from the Makefile. # +# The order is important since some of the test programs use data files created # +# by earlier test programs. Any future additions should be placed accordingly. # +# # +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # + +# Initializations +EXIT_SUCCESS=0 +EXIT_FAILURE=1 + +# Where the tool is installed. +prefix="${prefix:-${DESTDIR}/@prefix@}" +PARALLEL=@PARALLEL@ # Am I in parallel mode? +AR="@AR@" +RANLIB="@RANLIB@" +if [ "$PARALLEL" = no ]; then + H5TOOL="h5cc" # The tool name +else + H5TOOL="h5pcc" # The tool name +fi +H5TOOL_BIN="${prefix}/bin/${H5TOOL}" # The path of the tool binary + +#### Run test #### +RunTest() +{ + Test=$1".c" + + echo + echo "################# $1 #################" + ${H5TOOL_BIN} $Test + if [ $? -ne 0 ] + then + echo "messed up compiling $Test" + exit 1 + fi + ./a.out +} + + + +################## MAIN ################## + +if ! test -d red; then + mkdir red +fi +if ! test -d blue; then + mkdir blue +fi +if ! test -d u2w; then + mkdir u2w +fi + +# Run tests +if [ $? -eq 0 ] +then + if (RunTest h5_write &&\ + RunTest h5_read &&\ + RunTest h5_extend_write &&\ + RunTest h5_chunk_read &&\ + RunTest h5_compound &&\ + RunTest h5_group &&\ + RunTest h5_select &&\ + RunTest h5_attribute &&\ + RunTest h5_mount &&\ + RunTest h5_reference &&\ + RunTest h5_drivers &&\ + RunTest h5_ref2reg &&\ + RunTest h5_extlink &&\ + RunTest h5_elink_unix2win &&\ + RunTest h5_shared_mesg); then + EXIT_VALUE=${EXIT_SUCCESS} + else + EXIT_VALUE=${EXIT_FAILURE} + fi +fi + +# Cleanup +rm a.out +rm *.o +rm *.h5 +rm -rf red blue u2w +echo + +exit $EXIT_VALUE + diff --git a/fortran/examples/Makefile.am b/fortran/examples/Makefile.am index 5d03d2a..f27f7ff 100644 --- a/fortran/examples/Makefile.am +++ b/fortran/examples/Makefile.am @@ -41,6 +41,7 @@ INSTALL_FILES=dsetexample.f90 fileexample.f90 rwdsetexample.f90 \ attrexample.f90 groupexample.f90 grpsexample.f90 grpdsetexample.f90 \ hyperslab.f90 selectele.f90 grpit.f90 refobjexample.f90 \ refregexample.f90 mountexample.f90 compound.f90 ph5example.f90 +INSTALL_SCRIPT_FILES = run-fortran-ex.sh # Mark this directory as part of the Fortran API FORTRAN_API=yes diff --git a/fortran/examples/Makefile.in b/fortran/examples/Makefile.in index 05ebe21..e890904 100644 --- a/fortran/examples/Makefile.in +++ b/fortran/examples/Makefile.in @@ -55,7 +55,8 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ - $(srcdir)/testh5fc.sh.in $(top_srcdir)/config/commence.am \ + $(srcdir)/run-fortran-ex.sh.in $(srcdir)/testh5fc.sh.in \ + $(top_srcdir)/config/commence.am \ $(top_srcdir)/config/conclude.am \ $(top_srcdir)/config/examples.am TESTS = @@ -66,7 +67,7 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs CONFIG_HEADER = $(top_builddir)/src/H5config.h -CONFIG_CLEAN_FILES = testh5fc.sh +CONFIG_CLEAN_FILES = run-fortran-ex.sh testh5fc.sh CONFIG_CLEAN_VPATH_FILES = SOURCES = DIST_SOURCES = @@ -352,6 +353,7 @@ INSTALL_FILES = dsetexample.f90 fileexample.f90 rwdsetexample.f90 \ hyperslab.f90 selectele.f90 grpit.f90 refobjexample.f90 \ refregexample.f90 mountexample.f90 compound.f90 ph5example.f90 +INSTALL_SCRIPT_FILES = run-fortran-ex.sh # Mark this directory as part of the Fortran API FORTRAN_API = yes @@ -416,6 +418,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): +run-fortran-ex.sh: $(top_builddir)/config.status $(srcdir)/run-fortran-ex.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ testh5fc.sh: $(top_builddir)/config.status $(srcdir)/testh5fc.sh.in cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ @@ -627,6 +631,8 @@ ph5example: ph5example.f90 # How to create EXAMPLEDIR if it doesn't already exist $(EXAMPLEDIR): -$(top_srcdir)/bin/mkdirs $@ +$(EXAMPLETOPDIR): + -$(top_srcdir)/bin/mkdirs $@ # Install and uninstall rules. We install the source files, not the # example programs themselves. @@ -641,10 +647,26 @@ install-examples: $(EXAMPLEDIR) $(INSTALL_FILES) (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLEDIR)/. || exit 1);\ fi; \ done + @for f in X $(INSTALL_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $$f $(EXAMPLEDIR)/. || exit 1);\ + fi; \ + done + @for f in X $(INSTALL_TOP_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLETOPDIR)/. || exit 1); \ + fi; \ + done uninstall-examples: - @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ - set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + fi + @if test -n "$(INSTALL_SCRIPT_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_SCRIPT_FILES); \ + fi + @if test -n "$(INSTALL_TOP_SCRIPT_FILES)" -a -d $(EXAMPLETOPDIR); then \ + set -x; cd $(EXAMPLETOPDIR) && $(RM) $(INSTALL_TOP_SCRIPT_FILES); \ fi installcheck-local: diff --git a/fortran/examples/run-fortran-ex.sh.in b/fortran/examples/run-fortran-ex.sh.in new file mode 100755 index 0000000..1564537 --- /dev/null +++ b/fortran/examples/run-fortran-ex.sh.in @@ -0,0 +1,98 @@ +#! /bin/sh +# +# Copyright by The HDF Group. +# All rights reserved. +# +# This file is part of HDF5. The full HDF5 copyright notice, including +# terms governing use, modification, and redistribution, is contained in +# the files COPYING and Copyright.html. COPYING can be found at the root +# of the source code distribution tree; Copyright.html can be found at the +# root level of an installed copy of the electronic HDF5 document set and +# is linked from the top-level documents page. It can also be found at +# http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have +# access to either file, you may request a copy from help@hdfgroup.org. + +# +# This file: run-hlfortran-ex.sh +# Written by: Larry Knox +# Date: May 11, 2010 +# +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # +# # +# This script will compile and run the fortran examples from source files # +# installed in .../share/hdf5_examples/fortran using h5fc or h5pfc. The # +# order for running programs with RunTest in the MAIN section below is taken # +# from the Makefile. The order is important since some of the test programs # +# use data files created by earlier test programs. Any future additions should # +# be placed accordingly. # +# # +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # + +# Initializations +EXIT_SUCCESS=0 +EXIT_FAILURE=1 + +# Where the tool is installed. +prefix="${prefix:-${DESTDIR}/@prefix@}" +PARALLEL=@PARALLEL@ # Am I in parallel mode? +AR="@AR@" +RANLIB="@RANLIB@" +if [ "$PARALLEL" = no ]; then + H5TOOL="h5fc" # The tool name +else + H5TOOL="h5pfc" # The tool name +fi +H5TOOL_BIN="${prefix}/bin/${H5TOOL}" # The path of the tool binary + + +#### Run test #### +RunTest() +{ + Test=$1".f90" + + echo + echo "################# $1 #################" + ${H5TOOL_BIN} $Test + if [ $? -ne 0 ] + then + echo "messed up compiling $Test" + exit 1 + fi + ./a.out +} + + + +################## MAIN ################## + +# Run tests +if [ $? -eq 0 ] +then + if (RunTest dsetexample &&\ + RunTest fileexample &&\ + RunTest rwdsetexample &&\ + RunTest attrexample &&\ + RunTest groupexample &&\ + RunTest grpsexample &&\ + RunTest grpdsetexample &&\ + RunTest hyperslab &&\ + RunTest selectele &&\ + RunTest grpit &&\ + RunTest refobjexample &&\ + RunTest refregexample &&\ + RunTest mountexample &&\ + RunTest compound); then + EXIT_VALUE=${EXIT_SUCCESS} + else + EXIT_VALUE=${EXIT_FAILURE} + fi +fi + +# Cleanup +rm a.out +rm *.o +rm *.h5 +echo + +exit $EXIT_VALUE + diff --git a/hl/Makefile.am b/hl/Makefile.am index d707557..3271575 100644 --- a/hl/Makefile.am +++ b/hl/Makefile.am @@ -43,7 +43,9 @@ DIST_SUBDIRS=src test tools c++ fortran examples # Install examples install-examples uninstall-examples: - @(cd examples && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1; + @@SETX@; for d in examples $(HDF5_INTERFACES); do \ + (cd $$d && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1; \ + done installcheck-local: @(cd examples && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1; diff --git a/hl/Makefile.in b/hl/Makefile.in index 91c9db0..376c138 100755 --- a/hl/Makefile.in +++ b/hl/Makefile.in @@ -752,7 +752,9 @@ help: # Install examples install-examples uninstall-examples: - @(cd examples && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1; + @@SETX@; for d in examples $(HDF5_INTERFACES); do \ + (cd $$d && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1; \ + done installcheck-local: @(cd examples && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1; diff --git a/hl/c++/examples/Makefile.am b/hl/c++/examples/Makefile.am index 5bc17d0..da1580a 100644 --- a/hl/c++/examples/Makefile.am +++ b/hl/c++/examples/Makefile.am @@ -27,12 +27,13 @@ TEST_PROG=ptExampleFL ptExampleVL # These are the example files to be installed INSTALL_FILES=ptExampleFL.cpp ptExampleVL.cpp +INSTALL_SCRIPT_FILES = run-hlc++-ex.sh # Tell conclude.am that these are C++ tests. CXX_API=yes # Where to install examples -EXAMPLEDIR=$(exec_prefix)/examples/hl/c++ +EXAMPLEDIR=${DESTDIR}/$(exec_prefix)/share/hdf5_examples/hl/c++ # How to build programs using h5c++ $(EXTRA_PROG): $(H5CPP) diff --git a/hl/c++/examples/Makefile.in b/hl/c++/examples/Makefile.in index 1efcb60..491e4d8 100644 --- a/hl/c++/examples/Makefile.in +++ b/hl/c++/examples/Makefile.in @@ -55,7 +55,7 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ - $(top_srcdir)/config/commence.am \ + $(srcdir)/run-hlc++-ex.sh.in $(top_srcdir)/config/commence.am \ $(top_srcdir)/config/conclude.am \ $(top_srcdir)/config/examples.am TESTS = @@ -66,7 +66,7 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs CONFIG_HEADER = $(top_builddir)/src/H5config.h -CONFIG_CLEAN_FILES = +CONFIG_CLEAN_FILES = run-hlc++-ex.sh CONFIG_CLEAN_VPATH_FILES = SOURCES = DIST_SOURCES = @@ -338,12 +338,13 @@ TEST_PROG = ptExampleFL ptExampleVL # These are the example files to be installed INSTALL_FILES = ptExampleFL.cpp ptExampleVL.cpp +INSTALL_SCRIPT_FILES = run-hlc++-ex.sh # Tell conclude.am that these are C++ tests. CXX_API = yes # Where to install examples -EXAMPLEDIR = $(exec_prefix)/examples/hl/c++ +EXAMPLEDIR = ${DESTDIR}/$(exec_prefix)/share/hdf5_examples/hl/c++ # Assume that all tests in this directory are examples, and tell # conclude.am when to build them. @@ -402,6 +403,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): +run-hlc++-ex.sh: $(top_builddir)/config.status $(srcdir)/run-hlc++-ex.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ mostlyclean-libtool: -rm -f *.lo @@ -585,6 +588,8 @@ ptExampleVL: ptExampleVL.cpp # How to create EXAMPLEDIR if it doesn't already exist $(EXAMPLEDIR): -$(top_srcdir)/bin/mkdirs $@ +$(EXAMPLETOPDIR): + -$(top_srcdir)/bin/mkdirs $@ # Install and uninstall rules. We install the source files, not the # example programs themselves. @@ -599,10 +604,26 @@ install-examples: $(EXAMPLEDIR) $(INSTALL_FILES) (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLEDIR)/. || exit 1);\ fi; \ done + @for f in X $(INSTALL_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $$f $(EXAMPLEDIR)/. || exit 1);\ + fi; \ + done + @for f in X $(INSTALL_TOP_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLETOPDIR)/. || exit 1); \ + fi; \ + done uninstall-examples: - @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ - set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + fi + @if test -n "$(INSTALL_SCRIPT_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_SCRIPT_FILES); \ + fi + @if test -n "$(INSTALL_TOP_SCRIPT_FILES)" -a -d $(EXAMPLETOPDIR); then \ + set -x; cd $(EXAMPLETOPDIR) && $(RM) $(INSTALL_TOP_SCRIPT_FILES); \ fi installcheck-local: diff --git a/hl/c++/examples/run-hlc++-ex.sh.in b/hl/c++/examples/run-hlc++-ex.sh.in new file mode 100755 index 0000000..4e6b1fb --- /dev/null +++ b/hl/c++/examples/run-hlc++-ex.sh.in @@ -0,0 +1,80 @@ +#! /bin/sh +# +# Copyright by The HDF Group. +# All rights reserved. +# +# This file is part of HDF5. The full HDF5 copyright notice, including +# terms governing use, modification, and redistribution, is contained in +# the files COPYING and Copyright.html. COPYING can be found at the root +# of the source code distribution tree; Copyright.html can be found at the +# root level of an installed copy of the electronic HDF5 document set and +# is linked from the top-level documents page. It can also be found at +# http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have +# access to either file, you may request a copy from help@hdfgroup.org. + +# +# This file: run-hlc++-ex.sh +# Written by: Larry Knox +# Date: May 11, 2010 +# +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # +# # +# This script will compile and run the c++ examples from source files # +# installed in .../share/hdf5_examples/hl/c++ using h5c++. The # +# order for running programs with RunTest in the MAIN section below is taken # +# from the Makefile. The order is important since some of the test programs # +# use data files created by earlier test programs. Any future additions should # +# be placed accordingly. # +# # +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # + +# Initializations +EXIT_SUCCESS=0 +EXIT_FAILURE=1 + +# Where the tool is installed. +prefix="${prefix:-${DESTDIR}/@prefix@}" +AR="@AR@" +RANLIB="@RANLIB@" +H5TOOL="h5c++" # The tool name +H5TOOL_BIN="${prefix}/bin/${H5TOOL}" # The path of the tool binary + +#### Run test #### +RunTest() +{ + Test=$1".cpp" + + echo + echo "################# $1 #################" + ${H5TOOL_BIN} $Test + if [ $? -ne 0 ] + then + echo "messed up compiling $Test" + exit 1 + fi + ./a.out +} + + + +################## MAIN ################## + +# Run tests +if [ $? -eq 0 ] +then + if (RunTest ptExampleFL &&\ + RunTest ptExampleVL); then + EXIT_VALUE=${EXIT_SUCCESS} + else + EXIT_VALUE=${EXIT_FAILURE} + fi +fi + +# Cleanup +rm a.out +rm *.o +rm *.h5 +echo + +exit $EXIT_VALUE + diff --git a/hl/examples/Makefile.am b/hl/examples/Makefile.am index 4a9bdbe..64a29d4 100644 --- a/hl/examples/Makefile.am +++ b/hl/examples/Makefile.am @@ -27,6 +27,7 @@ endif # Example directory EXAMPLEDIR=${DESTDIR}/$(exec_prefix)/share/hdf5_examples/hl/c +EXAMPLETOPDIR=${DESTDIR}/$(exec_prefix)/share/hdf5_examples/hl # Example programs. # Don't tell automake about them, because if it knew they were programs, @@ -41,7 +42,15 @@ TEST_PROG = ex_lite1 ex_lite2 ex_lite3 ptExampleFL ptExampleVL \ # Install files # List all file that should be installed in examples directory -INSTALL_FILES = ptExampleFL.c ptExampleVL.c +INSTALL_FILES = ex_lite1.c ex_lite2.c ex_lite3.c ptExampleFL.c ptExampleVL.c \ + ex_image1.c ex_image2.c \ + ex_table_01.c ex_table_02.c ex_table_03.c ex_table_04.c \ + ex_table_05.c ex_table_06.c ex_table_07.c ex_table_08.c \ + ex_table_09.c ex_table_10.c ex_table_11.c ex_table_12.c \ + ex_ds1.c image24pixel.txt image8.txt pal_rgb.h + +INSTALL_SCRIPT_FILES = run-hlc-ex.sh +INSTALL_TOP_SCRIPT_FILES = run-hl-ex.sh # Additional dependencies for each program are listed below. if BUILD_PARALLEL_CONDITIONAL diff --git a/hl/examples/Makefile.in b/hl/examples/Makefile.in index 722e8ef..7e36991 100644 --- a/hl/examples/Makefile.in +++ b/hl/examples/Makefile.in @@ -55,7 +55,7 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ - $(top_srcdir)/config/commence.am \ + $(srcdir)/run-hlc-ex.sh.in $(top_srcdir)/config/commence.am \ $(top_srcdir)/config/conclude.am \ $(top_srcdir)/config/examples.am TESTS = @@ -66,7 +66,7 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs CONFIG_HEADER = $(top_builddir)/src/H5config.h -CONFIG_CLEAN_FILES = +CONFIG_CLEAN_FILES = run-hlc-ex.sh CONFIG_CLEAN_VPATH_FILES = SOURCES = DIST_SOURCES = @@ -335,6 +335,7 @@ CHECK_CLEANFILES = *.chkexe *.chklog *.clog *.h5 # Example directory EXAMPLEDIR = ${DESTDIR}/$(exec_prefix)/share/hdf5_examples/hl/c +EXAMPLETOPDIR = ${DESTDIR}/$(exec_prefix)/share/hdf5_examples/hl # Example programs. # Don't tell automake about them, because if it knew they were programs, @@ -350,7 +351,15 @@ TEST_PROG = ex_lite1 ex_lite2 ex_lite3 ptExampleFL ptExampleVL \ # Install files # List all file that should be installed in examples directory -INSTALL_FILES = ptExampleFL.c ptExampleVL.c +INSTALL_FILES = ex_lite1.c ex_lite2.c ex_lite3.c ptExampleFL.c ptExampleVL.c \ + ex_image1.c ex_image2.c \ + ex_table_01.c ex_table_02.c ex_table_03.c ex_table_04.c \ + ex_table_05.c ex_table_06.c ex_table_07.c ex_table_08.c \ + ex_table_09.c ex_table_10.c ex_table_11.c ex_table_12.c \ + ex_ds1.c image24pixel.txt image8.txt pal_rgb.h + +INSTALL_SCRIPT_FILES = run-hlc-ex.sh +INSTALL_TOP_SCRIPT_FILES = run-hl-ex.sh # Assume that all tests in this directory are examples, and tell # conclude.am when to build them. @@ -409,6 +418,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): +run-hlc-ex.sh: $(top_builddir)/config.status $(srcdir)/run-hlc-ex.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ mostlyclean-libtool: -rm -f *.lo @@ -618,6 +629,8 @@ ex_table12: $(srcdir)/ex_table12.c # How to create EXAMPLEDIR if it doesn't already exist $(EXAMPLEDIR): -$(top_srcdir)/bin/mkdirs $@ +$(EXAMPLETOPDIR): + -$(top_srcdir)/bin/mkdirs $@ # Install and uninstall rules. We install the source files, not the # example programs themselves. @@ -632,10 +645,26 @@ install-examples: $(EXAMPLEDIR) $(INSTALL_FILES) (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLEDIR)/. || exit 1);\ fi; \ done + @for f in X $(INSTALL_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $$f $(EXAMPLEDIR)/. || exit 1);\ + fi; \ + done + @for f in X $(INSTALL_TOP_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLETOPDIR)/. || exit 1); \ + fi; \ + done uninstall-examples: - @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ - set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + fi + @if test -n "$(INSTALL_SCRIPT_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_SCRIPT_FILES); \ + fi + @if test -n "$(INSTALL_TOP_SCRIPT_FILES)" -a -d $(EXAMPLETOPDIR); then \ + set -x; cd $(EXAMPLETOPDIR) && $(RM) $(INSTALL_TOP_SCRIPT_FILES); \ fi installcheck-local: diff --git a/hl/examples/run-hl-ex.sh b/hl/examples/run-hl-ex.sh new file mode 100755 index 0000000..0478f76 --- /dev/null +++ b/hl/examples/run-hl-ex.sh @@ -0,0 +1,36 @@ +#! /bin/sh +# +# Copyright by The HDF Group. +# All rights reserved. +# +# This file is part of HDF5. The full HDF5 copyright notice, including +# terms governing use, modification, and redistribution, is contained in +# the files COPYING and Copyright.html. COPYING can be found at the root +# of the source code distribution tree; Copyright.html can be found at the +# root level of an installed copy of the electronic HDF5 document set and +# is linked from the top-level documents page. It can also be found at +# http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have +# access to either file, you may request a copy from help@hdfgroup.org. + +# +# This file: run-hl-ex.sh +# Written by: Larry Knox +# Date: May 11, 2010 +# +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # +# # +# This script will run the scripts to compile and run the hdf5 hl examples. # +# # +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # + +if (echo "Run hl c examples" && \ + (cd c; sh ./run-hlc-ex.sh) && \ + echo "Run hl fortran examples" && \ + (cd fortran; sh ./run-hlfortran-ex.sh) && \ + echo "Run hl c++ examples" && \ + (cd c++; sh ./run-hlc++-ex.sh)); then + echo "Finished running hl examples" + exit 0 +else + exit 1 +fi diff --git a/hl/examples/run-hlc-ex.sh.in b/hl/examples/run-hlc-ex.sh.in new file mode 100755 index 0000000..d66d9e0 --- /dev/null +++ b/hl/examples/run-hlc-ex.sh.in @@ -0,0 +1,102 @@ +#! /bin/sh +# +# Copyright by The HDF Group. +# All rights reserved. +# +# This file is part of HDF5. The full HDF5 copyright notice, including +# terms governing use, modification, and redistribution, is contained in +# the files COPYING and Copyright.html. COPYING can be found at the root +# of the source code distribution tree; Copyright.html can be found at the +# root level of an installed copy of the electronic HDF5 document set and +# is linked from the top-level documents page. It can also be found at +# http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have +# access to either file, you may request a copy from help@hdfgroup.org. + +# +# This file: run-hlc-ex.sh +# Written by: Larry Knox +# Date: May 11, 2010 +# +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # +# # +# This script will compile and run the c examples from source files installed # +# in .../share/hdf5_examples/hl/c using h5cc or h5pc. The order for running # +# programs with RunTest in the MAIN section below is taken from the Makefile. # +# The order is important since some of the test programs use data files created # +# by earlier test programs. Any future additions should be placed accordingly. # +# # +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # + +# Initializations +EXIT_SUCCESS=0 +EXIT_FAILURE=1 + +# Where the tool is installed. +prefix="${prefix:-${DESTDIR}/@prefix@}" +PARALLEL=@PARALLEL@ # Am I in parallel mode? +AR="@AR@" +RANLIB="@RANLIB@" +if [ "$PARALLEL" = no ]; then + H5TOOL="h5cc" # The tool name +else + H5TOOL="h5pcc" # The tool name +fi +H5TOOL_BIN="${prefix}/bin/${H5TOOL}" # The path of the tool binary + +#### Run test #### +RunTest() +{ + Test=$1".c" + + echo + echo "################# $1 #################" + ${H5TOOL_BIN} $Test + if [ $? -ne 0 ] + then + echo "messed up compiling $Test" + exit 1 + fi + ./a.out +} + + + +################## MAIN ################## + +# Run tests +if [ $? -eq 0 ] +then + if (RunTest ex_lite1 &&\ + RunTest ex_lite2 &&\ + RunTest ex_lite3 &&\ + RunTest ptExampleFL &&\ + RunTest ptExampleVL &&\ + RunTest ex_image1 &&\ + RunTest ex_image2 &&\ + RunTest ex_table_01 &&\ + RunTest ex_table_02 &&\ + RunTest ex_table_03 &&\ + RunTest ex_table_04 &&\ + RunTest ex_table_05 && + RunTest ex_table_06 &&\ + RunTest ex_table_07 &&\ + RunTest ex_table_08 &&\ + RunTest ex_table_09 &&\ + RunTest ex_table_10 &&\ + RunTest ex_table_11 &&\ + RunTest ex_table_12 &&\ + RunTest ex_ds1); then + EXIT_VALUE=${EXIT_SUCCESS} + else + EXIT_VALUE=${EXIT_FAILURE} + fi +fi + +# Cleanup +rm a.out +rm *.o +rm *.h5 +echo + +exit $EXIT_VALUE + diff --git a/hl/fortran/examples/Makefile.am b/hl/fortran/examples/Makefile.am index 1385b18..ba8788c 100644 --- a/hl/fortran/examples/Makefile.am +++ b/hl/fortran/examples/Makefile.am @@ -34,7 +34,8 @@ endif TEST_PROG=exlite # List files to be installed here -INSTALL_FILES= +INSTALL_FILES= exlite.f90 +INSTALL_SCRIPT_FILES = run-hlfortran-ex.sh # Mark this directory as part of the Fortran API FORTRAN_API=yes @@ -49,7 +50,7 @@ $(EXTRA_PROG): $(H5FC) endif # Tell automake how to install examples -EXAMPLEDIR=$(exec_prefix)/examples/hl/fortran +EXAMPLEDIR=${DESTDIR}/$(exec_prefix)/share/hdf5_examples/hl/fortran # List dependencies for each example. Normally, automake would take # care of this for us, but if we tell automake about the programs it diff --git a/hl/fortran/examples/Makefile.in b/hl/fortran/examples/Makefile.in index f5aece9..49fbfdb 100644 --- a/hl/fortran/examples/Makefile.in +++ b/hl/fortran/examples/Makefile.in @@ -55,6 +55,7 @@ POST_UNINSTALL = : build_triplet = @build@ host_triplet = @host@ DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \ + $(srcdir)/run-hlfortran-ex.sh.in \ $(top_srcdir)/config/commence.am \ $(top_srcdir)/config/conclude.am \ $(top_srcdir)/config/examples.am @@ -66,7 +67,7 @@ am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \ $(ACLOCAL_M4) mkinstalldirs = $(SHELL) $(top_srcdir)/bin/mkinstalldirs CONFIG_HEADER = $(top_builddir)/src/H5config.h -CONFIG_CLEAN_FILES = +CONFIG_CLEAN_FILES = run-hlfortran-ex.sh CONFIG_CLEAN_VPATH_FILES = SOURCES = DIST_SOURCES = @@ -343,13 +344,14 @@ CHECK_CLEANFILES = *.chkexe *.chklog *.clog *.h5 TEST_PROG = exlite # List files to be installed here -INSTALL_FILES = +INSTALL_FILES = exlite.f90 +INSTALL_SCRIPT_FILES = run-hlfortran-ex.sh # Mark this directory as part of the Fortran API FORTRAN_API = yes # Tell automake how to install examples -EXAMPLEDIR = $(exec_prefix)/examples/hl/fortran +EXAMPLEDIR = ${DESTDIR}/$(exec_prefix)/share/hdf5_examples/hl/fortran # Assume that all tests in this directory are examples, and tell # conclude.am when to build them. @@ -408,6 +410,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): +run-hlfortran-ex.sh: $(top_builddir)/config.status $(srcdir)/run-hlfortran-ex.sh.in + cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ mostlyclean-libtool: -rm -f *.lo @@ -586,6 +590,8 @@ help: # How to create EXAMPLEDIR if it doesn't already exist $(EXAMPLEDIR): -$(top_srcdir)/bin/mkdirs $@ +$(EXAMPLETOPDIR): + -$(top_srcdir)/bin/mkdirs $@ # Install and uninstall rules. We install the source files, not the # example programs themselves. @@ -600,10 +606,26 @@ install-examples: $(EXAMPLEDIR) $(INSTALL_FILES) (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLEDIR)/. || exit 1);\ fi; \ done + @for f in X $(INSTALL_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $$f $(EXAMPLEDIR)/. || exit 1);\ + fi; \ + done + @for f in X $(INSTALL_TOP_SCRIPT_FILES); do \ + if test $$f != X; then \ + (set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLETOPDIR)/. || exit 1); \ + fi; \ + done uninstall-examples: - @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ - set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + @if test -n "$(INSTALL_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_FILES); \ + fi + @if test -n "$(INSTALL_SCRIPT_FILES)" -a -d $(EXAMPLEDIR); then \ + set -x; cd $(EXAMPLEDIR) && $(RM) $(INSTALL_SCRIPT_FILES); \ + fi + @if test -n "$(INSTALL_TOP_SCRIPT_FILES)" -a -d $(EXAMPLETOPDIR); then \ + set -x; cd $(EXAMPLETOPDIR) && $(RM) $(INSTALL_TOP_SCRIPT_FILES); \ fi installcheck-local: diff --git a/hl/fortran/examples/run-hlfortran-ex.sh.in b/hl/fortran/examples/run-hlfortran-ex.sh.in new file mode 100755 index 0000000..644a9b7 --- /dev/null +++ b/hl/fortran/examples/run-hlfortran-ex.sh.in @@ -0,0 +1,84 @@ +#! /bin/sh +# +# Copyright by The HDF Group. +# All rights reserved. +# +# This file is part of HDF5. The full HDF5 copyright notice, including +# terms governing use, modification, and redistribution, is contained in +# the files COPYING and Copyright.html. COPYING can be found at the root +# of the source code distribution tree; Copyright.html can be found at the +# root level of an installed copy of the electronic HDF5 document set and +# is linked from the top-level documents page. It can also be found at +# http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have +# access to either file, you may request a copy from help@hdfgroup.org. + +# +# This file: run-hlfortran-ex.sh +# Written by: Larry Knox +# Date: May 11, 2010 +# +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # +# # +# This script will compile and run the fortran examples from source files # +# installed in .../share/hdf5_examples/hl/fortran using h5fc or h5pfc. The # +# order for running programs with RunTest in the MAIN section below is taken # +# from the Makefile. The order is important since some of the test programs # +# use data files created by earlier test programs. Any future additions should # +# be placed accordingly. # +# # +# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # + +# Initializations +EXIT_SUCCESS=0 +EXIT_FAILURE=1 + +# Where the tool is installed. +prefix="${prefix:-${DESTDIR}/@prefix@}" +PARALLEL=@PARALLEL@ # Am I in parallel mode? +AR="@AR@" +RANLIB="@RANLIB@" +if [ "$PARALLEL" = no ]; then + H5TOOL="h5fc" # The tool name +else + H5TOOL="h5pfc" # The tool name +fi +H5TOOL_BIN="${prefix}/bin/${H5TOOL}" # The path of the tool binary + +#### Run test #### +RunTest() +{ + Test=$1".f90" + + echo + echo "################# $1 #################" + ${H5TOOL_BIN} $Test + if [ $? -ne 0 ] + then + echo "messed up compiling $Test" + exit 1 + fi + ./a.out +} + + + +################## MAIN ################## + +# Run tests +if [ $? -eq 0 ] +then + if (RunTest exlite); then + EXIT_VALUE=${EXIT_SUCCESS} + else + EXIT_VALUE=${EXIT_FAILURE} + fi +fi + +# Cleanup +rm a.out +rm *.o +rm *.h5 +echo + +exit $EXIT_VALUE + -- cgit v0.12