From ee55dd777bf12376ec345b5528ab6a9d868a8b47 Mon Sep 17 00:00:00 2001 From: Dana Robinson <43805+derobins@users.noreply.github.com> Date: Tue, 23 Aug 2022 12:25:07 -0700 Subject: Fortran module directory improvements (#2060) * Removes the module directory from the Automake flags as this generated a large number of "missing include directory" warnings and is unecessary * Adds the module path to libhdf5.settings --- config/cmake/libhdf5.settings.cmake.in | 1 + fortran/src/Makefile.am | 2 +- hl/fortran/src/Makefile.am | 2 +- src/libhdf5.settings.in | 1 + 4 files changed, 4 insertions(+), 2 deletions(-) diff --git a/config/cmake/libhdf5.settings.cmake.in b/config/cmake/libhdf5.settings.cmake.in index 76f8293..48016d8 100644 --- a/config/cmake/libhdf5.settings.cmake.in +++ b/config/cmake/libhdf5.settings.cmake.in @@ -50,6 +50,7 @@ Languages: @BUILD_FORTRAN_CONDITIONAL_TRUE@ AM Fortran Flags: @AM_FCFLAGS@ @BUILD_FORTRAN_CONDITIONAL_TRUE@ Shared Fortran Library: @H5_ENABLE_SHARED_LIB@ @BUILD_FORTRAN_CONDITIONAL_TRUE@ Static Fortran Library: @H5_ENABLE_STATIC_LIB@ +@BUILD_FORTRAN_CONDITIONAL_TRUE@ Module Directory: @CMAKE_Fortran_MODULE_DIRECTORY@ C++: @HDF5_BUILD_CPP_LIB@ @BUILD_CXX_CONDITIONAL_TRUE@ C++ Compiler: @CMAKE_CXX_COMPILER@ @CMAKE_CXX_COMPILER_VERSION@ diff --git a/fortran/src/Makefile.am b/fortran/src/Makefile.am index 94fcb5a..85e51b7 100644 --- a/fortran/src/Makefile.am +++ b/fortran/src/Makefile.am @@ -22,7 +22,7 @@ include $(top_srcdir)/config/lt_vers.am # Include src directory in both Fortran and C flags (C compiler is used # for linking). AM_CPPFLAGS+=-I$(top_srcdir)/src -AM_FCFLAGS+=-I$(top_srcdir)/src -I$(top_srcdir)/fortran/src $(F9XMODFLAG)$(fmoddir) +AM_FCFLAGS+=-I$(top_srcdir)/src -I$(top_srcdir)/fortran/src AM_FCLIBS=$(LIBHDF5) diff --git a/hl/fortran/src/Makefile.am b/hl/fortran/src/Makefile.am index ca4ea64..dfd7730 100644 --- a/hl/fortran/src/Makefile.am +++ b/hl/fortran/src/Makefile.am @@ -22,7 +22,7 @@ include $(top_srcdir)/config/lt_vers.am AM_CPPFLAGS+=-I$(top_srcdir)/src -I$(top_srcdir)/hl/src -I$(top_builddir)/hl/src \ -I$(top_srcdir)/fortran/src -I$(top_builddir)/fortran/src -AM_FCFLAGS+=-I$(top_builddir)/fortran/src $(F9XMODFLAG)$(top_builddir)/fortran/src $(F9XMODFLAG)$(fmoddir) +AM_FCFLAGS+=-I$(top_builddir)/fortran/src $(F9XMODFLAG)$(top_builddir)/fortran/src # Our main target, the high-level fortran library lib_LTLIBRARIES=libhdf5hl_fortran.la diff --git a/src/libhdf5.settings.in b/src/libhdf5.settings.in index 01b753a..9f5a58a 100644 --- a/src/libhdf5.settings.in +++ b/src/libhdf5.settings.in @@ -52,6 +52,7 @@ Languages: @BUILD_FORTRAN_CONDITIONAL_TRUE@ AM Fortran Flags: @AM_FCFLAGS@ @BUILD_FORTRAN_CONDITIONAL_TRUE@ Shared Fortran Library: @H5_FORTRAN_SHARED@ @BUILD_FORTRAN_CONDITIONAL_TRUE@ Static Fortran Library: @enable_static@ +@BUILD_FORTRAN_CONDITIONAL_TRUE@ Module Directory: @fmoddir@ C++: @HDF_CXX@ @BUILD_CXX_CONDITIONAL_TRUE@ C++ Compiler: @CXX_VERSION@ -- cgit v0.12