From 95738d1a4c56fba15f980d80a282e219c988584f Mon Sep 17 00:00:00 2001 From: Kyle Mandli Date: Mon, 14 Oct 2013 13:22:27 -0500 Subject: [PATCH] Remove extraneous include directives Remove the duplicate paths from the MODULE_PATH variable that were causing extraneous include directives on every compile line. This was accomplished by using the sort command so there is a chance that something might get mucked up in the order of the includes but that should not matter for Fortran unless one is using replacement modules with the same name. May add a better solution to this later. --- src/Makefile.common | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Makefile.common b/src/Makefile.common index 2e81cf21..7bb92100 100644 --- a/src/Makefile.common +++ b/src/Makefile.common @@ -50,7 +50,8 @@ MODULES ?= # Make list of .o files required from the sources above: OBJECTS = $(subst .F,.o, $(subst .F90,.o, $(subst .f,.o, $(subst .f90,.o, $(SOURCES))))) MODULE_FILES = $(subst .F,.mod, $(subst .F90,.mod, $(subst .f,.mod, $(subst .f90,.mod, $(MODULES))))) -MODULE_PATHS = $(dir $(MODULE_FILES)) +# FYI: Sort weeds out duplicate paths +MODULE_PATHS = $(sort $(dir $(MODULE_FILES))) MODULE_OBJECTS = $(subst .F,.o, $(subst .F90,.o, $(subst .f,.o, $(subst .f90,.o, $(MODULES))))) #----------------------------------------------------------------------------