hdf5/config/examples.am
Larry Knox f32690b53c [svn-r24997] Added compiler versions for mpich to settings file and configure summary.
For make installcheck, compile and run installed examples using the installed scripts.  They were being compiled but not run.
Add Fortran2003 examples to the run-ex-fortran script when fortran2003 is enabled.
Set flag to -O3 in production mode for Intel compilers other than those with specified other settings.
Gentoo patches:
    Remove unnecessary setting of LD_LIBRARY_PATH from configure.
    Prevent potential array subscript out of bounds error in perform/pio_engine.c and sio_engine.c.

Tested with h5committest on jam, koala, ostrich and platypus, on emu and kite, and parallel tests on jam, koala and platypus with mpich built with gnu 4.8.2 and with intel compilers.
2014-04-08 23:55:49 -05:00

123 lines
5.4 KiB
Plaintext

## config/examples.am
## (Use double hashes for copyright notice so that automake treats it as
## comments and does not pass it to Makefile.in)
## Copyright by The HDF Group.
## Copyright by the Board of Trustees of the University of Illinois.
## All rights reserved.
##
## This file is part of HDF5. The full HDF5 copyright notice, including
## terms governing use, modification, and redistribution, is contained in
## the files COPYING and Copyright.html. COPYING can be found at the root
## of the source code distribution tree; Copyright.html can be found at the
## root level of an installed copy of the electronic HDF5 document set and
## is linked from the top-level documents page. It can also be found at
## http://hdfgroup.org/HDF5/doc/Copyright.html. If you do not have
## access to either file, you may request a copy from help@hdfgroup.org.
## Textually included near the end of HDF5 Makefiles in example directories.
## Contains boilerplate for building, installing, and cleaning example
## programs.
# We can't tell automake about example programs, because they need to be
# built using h5cc (or h5fc, etc.) instead of the standard compilers.
# This creates some extra work for us.
## The Makefile.am that includes this boilerplate needs to define the
## following:
##
## TEST_PROG and TEST_PROG_PARA
## We assume that all test programs in this directory are examples.
##
## INSTALL_FILES
## The source files that the examples use which should be installed.
## INSTALL_SCRIPT_FILES
## INSTALL_TOP_SCRIPT_FILES
## INSTALL_TOP_FILES
##
## EXAMPLEDIR
## The directory into which examples should be installed.
##
## Build rules for $(EXTRA_PROG).
## Dependencies for example programs.
## Automake will supply neither of these.
##
# Assume that all tests in this directory are examples, and tell
# conclude.am when to build them.
EXTRA_PROG = $(EXAMPLE_PROG) $(EXAMPLE_PROG_PARA)
# We need to tell automake what to clean
MOSTLYCLEANFILES=*.raw *.meta *.o
CHECK_CLEANFILES+=*.h5
CLEANFILES=$(EXAMPLE_PROG) $(EXAMPLE_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.
install-data-local:
@$(MAKE) $(AM_MAKEFLAGS) install-examples
uninstall-local:
@$(MAKE) $(AM_MAKEFLAGS) uninstall-examples
install-examples: $(EXAMPLEDIR) $(INSTALL_FILES)
@for f in X $(INSTALL_FILES); do \
if test $$f != X; then \
(set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLEDIR)/. || exit 1); \
chmod a-x $(EXAMPLEDIR)/$$f; \
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_FILES); do \
if test $$f != X; then \
(set -x; $(INSTALL) $(srcdir)/$$f $(EXAMPLETOPDIR)/. || exit 1); \
chmod a-x $(EXAMPLETOPDIR)/$$f;\
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); \
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_FILES)" -a -d $(EXAMPLETOPDIR); then \
set -x; cd $(EXAMPLETOPDIR) && $(RM) $(INSTALL_TOP_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:
@if test "$(STATIC_SHARED)" = "static, shared"; then \
H5CCFLAGS="-shlib" $(MAKE) $(AM_MAKEFLAGS) check; \
$(MAKE) $(AM_MAKEFLAGS) clean; \
H5CCFLAGS="" $(MAKE) $(AM_MAKEFLAGS) check; \
elif test "$(STATIC_SHARED)" = "shared"; then \
H5CCFLAGS="-shlib" $(MAKE) $(AM_MAKEFLAGS) check; \
else \
$(MAKE) $(AM_MAKEFLAGS) check; \
fi
@if test "$(INSTALL_FILES)" -a $(TEST_EXAMPLES_SCRIPT) -a -d $(EXAMPLEDIR); then \
echo "============================"; \
echo "Testing $(TEST_EXAMPLES_SCRIPT)"; \
echo "============================"; \
(cd $(EXAMPLEDIR); \
/bin/sh ./$(TEST_EXAMPLES_SCRIPT);) \
fi