diff --git a/set_flags.am b/set_flags.am new file mode 100644 index 00000000000..f914680637f --- /dev/null +++ b/set_flags.am @@ -0,0 +1,12 @@ +# This is part of the PIO package. +# +# Assemble the CPPFLAGS and for PIO Fortran tests. +# + +# Set the CPPFLAGS. +AM_CPPFLAGS = -I$(top_srcdir)/src/flib +AM_CPPFLAGS += "-D_NETCDF -D_NETCDF4 -D_PETCDF" + +# Link to our assembled libraries, C and Fortran. +AM_LDFLAGS = ${top_builddir}/src/clib/libpio.la +LDADD = ${top_builddir}/src/clib/libpiof.la diff --git a/tests/cunit/test_perf2.c b/tests/cunit/test_perf2.c index 36668776108..66f2b259a1b 100644 --- a/tests/cunit/test_perf2.c +++ b/tests/cunit/test_perf2.c @@ -219,9 +219,8 @@ int test_darray(int iosysid, int ioid, int num_flavors, int *flavor, int my_rank startt = (1000000 * starttime.tv_sec) + starttime.tv_usec; endt = (1000000 * endtime.tv_sec) + endtime.tv_usec; delta = (endt - startt)/NUM_TIMESTEPS; - /* if (!my_rank) */ - /* printf("%d\t%d\t%d\t%d\t%lld\n", rearranger, fmt, pio_type, test_multi, */ - /* delta); */ + if (!my_rank) + printf("%d\t%lld\n", fmt, delta); /* Reopen the file. */ if ((ret = PIOc_openfile(iosysid, &ncid2, &flavor[fmt], filename, PIO_NOWRITE))) diff --git a/tests/unit/Makefile.am b/tests/unit/Makefile.am index 6e06006acb5..868cf96d18b 100644 --- a/tests/unit/Makefile.am +++ b/tests/unit/Makefile.am @@ -3,11 +3,8 @@ # Ed Hartnett 3/20/19 -# Link to our assembled library. -AM_LDFLAGS = ${top_builddir}/src/clib/libpio.la -AM_CPPFLAGS = -I$(top_srcdir)/src/flib -AM_CPPFLAGS += "-D_NETCDF -D_NETCDF4 -D_PETCDF" -LDADD = ${top_builddir}/src/clib/libpiof.la +# Put together AM_CPPFLAGS and AM_LDFLAGS. +include $(top_srcdir)/set_flags.am # Build the test for make check. check_PROGRAMS = pio_unit_test_driver