From 956f28fc2c875c40965764c6e254e7da034b20e5 Mon Sep 17 00:00:00 2001 From: Ed Hartnett Date: Tue, 26 Mar 2019 09:42:30 -0600 Subject: [PATCH] now move pio_tutil to tests/general dir during configure --- configure.ac | 1 + tests/general/Makefile.am | 20 +++++++++++++------- 2 files changed, 14 insertions(+), 7 deletions(-) diff --git a/configure.ac b/configure.ac index e1c13cc61e3..194f211bfb7 100644 --- a/configure.ac +++ b/configure.ac @@ -145,6 +145,7 @@ AC_CONFIG_FILES(tests/general/pio_iosystem_tests.F90:tests/general/pio_iosystem_ AC_CONFIG_FILES(tests/general/pio_rearr.F90:tests/general/pio_rearr.F90.in2) AC_CONFIG_FILES(tests/general/pio_rearr_opts2.F90:tests/general/pio_rearr_opts2.F90.in2) AC_CONFIG_FILES(tests/general/pio_rearr_opts.F90:tests/general/pio_rearr_opts.F90.in2) +AC_CONFIG_FILES(tests/general/pio_tutil.F90:tests/general/util/pio_tutil.F90) # Create the config.h file. AC_CONFIG_HEADERS([config.h]) diff --git a/tests/general/Makefile.am b/tests/general/Makefile.am index 90f63a5d0c7..8555f6ef560 100644 --- a/tests/general/Makefile.am +++ b/tests/general/Makefile.am @@ -9,22 +9,28 @@ # Put together AM_CPPFLAGS and AM_LDFLAGS. include $(top_srcdir)/set_flags.am -LDADD = util/libpio_tutil.la \ +LDADD = libpio_tutil.la \ ${top_builddir}/src/flib/libpiof.la \ ${top_builddir}/src/clib/libpio.la -AM_CPPFLAGS += -I${top_builddir}/tests/general/util - # There is a test utility mod file in this subdir which must be built. -SRCDIRS = util . +#SRCDIRS = util -# Build this uninstalled convenience library. -noinst_LTLIBRARIES = libpio_rearr_opts.la +# Build these uninstalled convenience libraries. +noinst_LTLIBRARIES = libpio_tutil.la libpio_rearr_opts.la # The convenience libraries depends on their source. +libpio_tutil_la_SOURCES = pio_tutil.F90 # configure copies this from util dir. libpio_rearr_opts_la_SOURCES = pio_rearr_opts.F90 + +# Each mod file depends on the .o file. +pio_tutil.mod: pio_tutil.$(OBJEXT) pio_rearr_opts_tgv.mod: pio_rearr_opts.$(OBJEXT) -BUILT_SOURCES = pio_rearr_opts_tgv.mod + +# Some mods are dependant on other mods in this dir. +pio_rearr_opts.$(OBJEXT): pio_tutil.mod + +BUILT_SOURCES = pio_tutil.mod pio_rearr_opts_tgv.mod # Build the test for make check. check_PROGRAMS = pio_init_finalize pio_file_simple_tests \