summaryrefslogtreecommitdiffstats
path: root/fortran/examples
diff options
context:
space:
mode:
authorScot Breitenfeld <brtnfld@hdfgroup.org>2015-08-20 16:01:26 (GMT)
committerScot Breitenfeld <brtnfld@hdfgroup.org>2015-08-20 16:01:26 (GMT)
commit1436a07905193713568304dd00b26ca18e982e6f (patch)
tree59f082018deec22b9e1b70cbacc719ef48ef6d22 /fortran/examples
parent8db36cc7664ea6b618d7c78cbc70d8736f4b9b5f (diff)
downloadhdf5-1436a07905193713568304dd00b26ca18e982e6f.zip
hdf5-1436a07905193713568304dd00b26ca18e982e6f.tar.gz
hdf5-1436a07905193713568304dd00b26ca18e982e6f.tar.bz2
[svn-r27537] Added new FCCPPFLAGS to avoid passing CPPFLAGS to the fortran pre-processor compiler (This mainly causes issues with the xlf compilers)
Tested: h5committest
Diffstat (limited to 'fortran/examples')
-rw-r--r--fortran/examples/Makefile.am2
-rw-r--r--fortran/examples/Makefile.in19
2 files changed, 17 insertions, 4 deletions
diff --git a/fortran/examples/Makefile.am b/fortran/examples/Makefile.am
index cdd9317..5a3b09e 100644
--- a/fortran/examples/Makefile.am
+++ b/fortran/examples/Makefile.am
@@ -107,4 +107,4 @@ compound_fortran2003: compound_fortran2003.f90
compound_complex_fortran2003: compound_complex_fortran2003.f90
include $(top_srcdir)/config/examples.am
-include $(top_srcdir)/config/conclude.am
+include $(top_srcdir)/config/conclude_fc.am
diff --git a/fortran/examples/Makefile.in b/fortran/examples/Makefile.in
index cfde59c..0ee1461 100644
--- a/fortran/examples/Makefile.in
+++ b/fortran/examples/Makefile.in
@@ -34,6 +34,10 @@
# 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.
+
+# Makefile.am include fragment with Fortran helper rules and macros.
+
+# AM_FCCPPFLAGS, FCCPPFLAGS are currently not used.
VPATH = @srcdir@
am__is_gnu_make = test -n '$(MAKEFILE_LIST)' && test -n '$(MAKELEVEL)'
am__make_running_with_option = \
@@ -100,6 +104,7 @@ build_triplet = @build@
host_triplet = @host@
DIST_COMMON = $(top_srcdir)/config/commence.am \
$(top_srcdir)/config/examples.am \
+ $(top_srcdir)/config/conclude_fc.am \
$(top_srcdir)/config/conclude.am $(srcdir)/Makefile.in \
$(srcdir)/Makefile.am $(top_srcdir)/bin/mkinstalldirs \
$(srcdir)/run-fortran-ex.sh.in $(srcdir)/testh5fc.sh.in \
@@ -662,6 +667,8 @@ EXTRA_PROG = $(EXAMPLE_PROG) $(EXAMPLE_PROG_PARA)
# We need to tell automake what to clean
MOSTLYCLEANFILES = *.raw *.meta *.o
CLEANFILES = $(EXAMPLE_PROG) $(EXAMPLE_PROG_PARA)
+PPFCCOMPILE = $(FC) $(FCDEFS) $(DEFAULT_INCLUDES) $(FCINCLUDES) $(AM_FCCPPFLAGS) $(FCCPPFLAGS) $(AM_FCFLAGS) $(FCFLAGS)
+LTPPFCCOMPILE = $(LIBTOOL) --tag=FC $(AM_LIBTOOLFLAGS) $(LIBTOOLFLAGS) --mode=compile $(PPFCCOMPILE)
# 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.,
@@ -685,8 +692,8 @@ TEST_SCRIPT_PARA_CHKSH = $(TEST_SCRIPT_PARA:=.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)
+.SUFFIXES: .F90 .f90 .log .o .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_fc.am $(top_srcdir)/config/conclude.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
@@ -707,7 +714,7 @@ Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
esac;
-$(top_srcdir)/config/commence.am $(top_srcdir)/config/examples.am $(top_srcdir)/config/conclude.am:
+$(top_srcdir)/config/commence.am $(top_srcdir)/config/examples.am $(top_srcdir)/config/conclude_fc.am $(top_srcdir)/config/conclude.am:
$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
@@ -1155,6 +1162,12 @@ installcheck-local:
/bin/sh ./$(TEST_EXAMPLES_SCRIPT);) \
fi
+# Treat all .f90 and .F90 files as preprocessed Fortran.
+.f90.o:
+ $(PPFCCOMPILE) -c -o $@ $(FCFLAGS) $<
+.F90.o:
+ $(PPFCCOMPILE) -c -o $@ $(FCFLAGS) $<
+
# lib/progs/tests targets recurse into subdirectories. build-* targets
# build files in this directory.
build-lib: $(LIB)